All Products
Search
Document Center

Cloud Shell:Custom shortcut configurations

Last Updated:Jun 21, 2026

Cloud Shell provides a shortcut configuration feature. You can customize a command-line environment with specific commands and connections to your Alibaba Cloud resources. You can then open this custom environment in a new tab.

From the dropdown menu in the Cloud Shell tab bar, select Settings to open the Shortcut Configuration Settings page.

After saving a shortcut configuration, you can quickly launch it from the dropdown menu in the Cloud Shell tab bar. Clicking the configuration opens a new tab, starts a new command-line environment, and automatically applies the specified configuration.

Important

Shortcut configuration files are saved only in the $HOME/.cloudshell directory of the current instance. To persist your settings, you must mount storage space. Otherwise, you will lose your configurations when the instance is released.

Customize a startup command

You can define a custom startup command in a shortcut configuration. When you launch an environment with this configuration, the command runs automatically.

On the Shortcut Configuration Settings page, enter a Configuration name, set the Startup command type to Custom command, and enter the command you want to run (for example, top) in the Startup command content field. Then, click Save or Save and Open.

Click the shortcut configuration from the dropdown menu in the Cloud Shell tab bar. A new tab opens, starts a command-line environment, and automatically runs your custom command.

Quickly connect to Alibaba Cloud resources

You can quickly connect to your Alibaba Cloud resources from the Shortcut Configuration Settings page or the tab bar's dropdown menu. When the environment starts, it automatically connects and logs in to the specified resource instance.

From the dropdown menu at the top of the Shortcut Configuration Settings page, select Connect to resource instance. Set the startup command type to Quick Connect, and then click + Add in the connection configuration area to add the resource instances you want to connect to.

Cloud Shell currently supports the following Alibaba Cloud resources:

Resource type

Connection behavior

ECS

Upon startup, the environment automatically uses SSH to log in to your ECS instance.

Container Service for Kubernetes (ACK)

Upon startup, the environment automatically configures the kubeconfig file for the selected container service. You can then use kubectl to manage your containers directly.

The Quick Connect feature also supports connecting to resources in a VPC that do not have public endpoints. You can securely connect to and log in to your VPC resources from Cloud Shell. This feature is available in the following regions:

Region

City

Region ID

China (Hangzhou)

Hangzhou

cn-hangzhou

China (Shanghai)

Shanghai

cn-shanghai

China (Shenzhen)

Shenzhen

cn-shenzhen

China (Beijing)

Beijing

cn-beijing

Note

When you connect to a VPC resource, Cloud Shell automatically creates a primary elastic network interface to establish network connectivity and a service-linked role named AliyunServiceRoleForCloudShell to grant the necessary permissions. For more information about service-linked roles, see Service-Linked Roles