Skip to content

Commit b7912a5

Browse files
authored
Merge pull request #494 from nebari-dev/azure_backup
Update manual-backup.md for Azure
2 parents a5495bc + 3d6131d commit b7912a5

File tree

1 file changed

+31
-3
lines changed

1 file changed

+31
-3
lines changed

docs/docs/how-tos/manual-backup.md

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ apt install curl -y
8383
apt install unzip -y
8484
```
8585

86-
Because you are on AWS, the AWS command-line tool is also installed:
86+
For AWS, you need to install the CLI (see CLI instructions for Google, Azure, Digital Ocean below):
8787

8888
```shell
8989
curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
@@ -163,9 +163,9 @@ The file permissions for the default tar is same as the original files.
163163
>
164164
> From QHUb v0.4. all users will have the same `uid`.
165165

166-
### Google cloud provider
166+
### Google Cloud
167167

168-
To use the Google Cloud provider, install the [gsutil](https://cloud.google.com/storage/docs/gsutil_install) CLI instead of the AWS CLI. Otherwise, the instructions are the same as
168+
To do a backup on Google Cloud provider, install the [gsutil](https://cloud.google.com/storage/docs/gsutil_install) CLI instead of the AWS CLI. Otherwise, the instructions are the same as
169169
for AWS above, other than when working with S3. Here are the commands to access Google Spaces instead of S3 for copy/download of the backup:
170170

171171
```shell
@@ -176,6 +176,34 @@ cd /data
176176
gsutil cp gs://<your_bucket_name>/backups/2021-04-23.tar .
177177
```
178178

179+
### Azure
180+
181+
To do a backup on Azure, first install [Azure CLI](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=script#install-or-update-azure-cli) and [azcopy](https://learn.microsoft.com/en-us/azure/storage/common/storage-use-azcopy-v10?tabs=dnf#obtain-a-static-download-link). You must also have setup a storage container with blob storage. Otherwise, the instructions are the same as for AWS above, other than when working with S3. Here are the commands to access Azure blob storage instead of S3 for copy/download of the backup.
182+
183+
#### Do the backup
184+
185+
```bash
186+
az login # --use-device-code if web browser not available
187+
188+
cd /data
189+
# Tell AZCOPY to use same auth as CLI
190+
export AZCOPY_AUTO_LOGIN_TYPE=AZCLI
191+
# copy the tar backup file to blob storage
192+
azcopy copy 2021-04-23.tar "https://[account].blob.core.windows.net/[container]/nebari-backups/2021-04-23.tar"
193+
```
194+
195+
#### Do the restore
196+
197+
```bash
198+
az login # --use-device-code if web browser not available
199+
200+
cd /data
201+
# Tell AZCOPY to use same auth as CLI
202+
export AZCOPY_AUTO_LOGIN_TYPE=AZCLI
203+
# restore the backup file from blob storage
204+
azcopy copy "https://[account].blob.core.windows.net/[container]/nebari-backups/2021-04-23.tar" "./2021-04-23.tar"
205+
```
206+
179207
### Digital Ocean
180208

181209
Instructions will be similar to those for AWS above, but use Digital Ocean spaces instead of S3. This guide explains installation of the command-line tool:

0 commit comments

Comments
 (0)