You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cloud Shell machines are temporary and require an Azure Files share to be mounted as `clouddrive` to persist your files.
63
+
Cloud Shell machines are temporary and require a new or existing Azure Files share to be mounted as `clouddrive` to persist your files.
64
64
65
65
On first launch Cloud Shell prompts to create a resource group, storage account, and Azure Files share on your behalf. This is a one-time step and will be automatically attached for all sessions. A single file share can be mapped and will be used by both Bash and PowerShell in Cloud Shell (Preview).
66
66
67
-
#### Create new storage
68
-

69
-
70
-
A locally-redundant storage (LRS) account and Azure Files share can be created on your behalf. The Azure Files share will be used for both Bash and PowerShell environments if you choose to use both. Regular storage costs apply.
71
-
72
-
Three resources will be created on your behalf:
73
-
1. Resource Group named: `cloud-shell-storage-<region>`
> Bash in Cloud Shell also creates a default 5-GB disk image to persist `$Home`. All files in your $Home directory such as SSH keys are persisted in your user disk image stored in your mounted Azure file share. Apply best practices when saving files in your $Home directory and mounted Azure file share.
79
-
80
-
#### Use existing resources
81
-

82
-
83
-
An advanced option is provided to associate existing resources to Cloud Shell.
84
-
At the storage setup prompt, click "Show advanced settings" to show additional options.
85
-
86
-
> [!Note]
87
-
> Dropdowns are filtered for your pre-assigned Cloud Shell region and LRS/GRS/ZRS storage accounts.
88
-
89
-
[Learn about Cloud Shell storage, updating Azure file shares, and uploading/downloading files.](persisting-shell-storage.md)
67
+
Read more to learn how to mount a [new storage account/file share](media/overview/basic-storage.png) or [select an existing one](media/overview/advanced-storage.png).
90
68
91
69
## Concepts
92
70
* Cloud Shell runs on a temporary host provided on a per-session, per-user basis
@@ -38,9 +38,7 @@ With Bash in Cloud Shell, you can run a command called `clouddrive`, which enabl
38
38
#### Prerequisites for manual mounting
39
39
You can update the file share that's associated with Cloud Shell by using the `clouddrive mount` command.
40
40
41
-
If you mount an existing file share, the storage accounts must be:
42
-
* Locally redundant storage or geo-redundant storage to support file shares.
43
-
* Located in your assigned region. When you are onboarding, the region you are assigned to is listed in the resource group name `cloud-shell-storage-<region>`.
41
+
If you mount an existing file share, the storage accounts must be located in your select Cloud Shell region. Retrieve the location by running `env` from Bash and checking the `ACC_LOCATION`.
Cloud Shell utilizes Azure File storage to persist files across sessions.
3
-
4
-
## Set up a clouddrive file share
5
-
On initial start, Cloud Shell prompts you to associate a new or existing file share to persist files across sessions.
2
+
Cloud Shell utilizes Azure File storage to persist files across sessions. On initial start, Cloud Shell prompts you to associate a new or existing file share to persist files across sessions.
6
3
7
4
> [!NOTE]
8
5
> Bash and PowerShell share the same file share. Only one file share can be associated with automatic mounting in Cloud Shell.
9
6
10
-
###Create new storage
7
+
## Create new storage
11
8
12
9
When you use basic settings and select only a subscription, Cloud Shell creates three resources on your behalf in the supported region that's nearest to you:
13
10
* Resource group: `cloud-shell-storage-<region>`
@@ -21,26 +18,18 @@ The file share mounts as `clouddrive` in your `$Home` directory. This is a one-t
21
18
> [!NOTE]
22
19
> For security, each user should provision their own storage account. For role-based access control (RBAC), users must have contributor access or above at the storage account level.
23
20
24
-
In Bash, the file share also contains a 5-GB image that is created for you which automatically persists data in your `$Home` directory.
25
-
26
-
### Use existing resources
21
+
The file share also contains a 5-GB image that is created for you which automatically persists data in your `$Home` directory. This applies for both Bash and PowerShell.
27
22
28
-
By using the advanced option, you can associate existing resources. When the storage setup prompt appears, select **Show advanced settings** to view additional options. The drop-down menus are filtered for your assigned Cloud Shell region and the locally redundant storage and geo-redundant storage accounts.
23
+
## Use existing resources
29
24
30
-
File shares receive a 5-GB image created for you to persist your `$Home` directory.
25
+
By using the advanced option, you can associate existing resources. When the storage setup prompt appears, select **Show advanced settings** to view additional options. The populated storage options filter for locally redundant storage (LRS), geo-redundant storage (GRS), and zone-redundant storage (ZRS) accounts. Go [here to learn more](https://docs.microsoft.com/azure/storage/common/storage-redundancy#choosing-a-replication-option) about replication options for Azure Storage accounts.
31
26
32
27

33
28
34
-
### Restrict resource creation with an Azure resource policy
35
-
Storage accounts that you create in Cloud Shell are tagged with `ms-resource-usage:azure-cloud-shell`. If you want to disallow users from creating storage accounts in Cloud Shell, create an [Azure resource policy for tags](../articles/azure-policy/json-samples.md) that are triggered by this specific tag.
36
-
37
-
## Supported storage regions
38
-
Associated Azure storage accounts must reside in the same region as the Cloud Shell machine that you're mounting them to.
29
+
When selecting a Cloud Shell region you must select to mount a backing storage account in that region as well.
39
30
40
-
To find your assigned region you may:
41
-
* View the note on the "Advanced storage settings" dialog
42
-
* Refer to the name of the storage account created for you (ex: `cloud-shell-storage-westus`)
43
-
* Run `env` and locate the variable `ACC_LOCATION`
31
+
### Supported storage regions
32
+
Associated Azure storage accounts must reside in the same region as the Cloud Shell machine that you're mounting them to. To find your current region you may run `env` in Bash and locate the variable `ACC_LOCATION`. File shares receive a 5-GB image created for you to persist your `$Home` directory.
44
33
45
34
Cloud Shell machines exist in the following regions:
46
35
|Area|Region|
@@ -49,3 +38,5 @@ Cloud Shell machines exist in the following regions:
49
38
|Europe|North Europe, West Europe|
50
39
|Asia Pacific|India Central, Southeast Asia|
51
40
41
+
## Restrict resource creation with an Azure resource policy
42
+
Storage accounts that you create in Cloud Shell are tagged with `ms-resource-usage:azure-cloud-shell`. If you want to disallow users from creating storage accounts in Cloud Shell, create an [Azure resource policy for tags](../articles/azure-policy/json-samples.md) that are triggered by this specific tag.
0 commit comments