Skip to content
This repository has been archived by the owner on May 18, 2024. It is now read-only.

Add storage_account parameter to Azure Blob Storage backend #2016

Merged
merged 5 commits into from Oct 10, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 14 additions & 2 deletions themes/default/content/docs/intro/concepts/state.md
Expand Up @@ -80,7 +80,7 @@ For details on the various backend URL formats and options, please see the follo
- [Pulumi Self-Hosted Service](#logging-into-a-self-hosted-pulumi-service-backend)
- [Local Filesystem](#logging-into-the-local-filesystem-backend)
- [AWS S3 (or compatible server)](#logging-into-the-aws-s3-backend)
- [Azure Blob Storage](#logging-into-the-azure-blob-storage-backend)
- [Azure Blob Storage](#logging-into-the-azure-blob-storage-backend-using-the-env-vars)
ekini marked this conversation as resolved.
Show resolved Hide resolved
- [Google Cloud Storage](#logging-into-the-google-cloud-storage-backend)

If you forget to log in, you will be automatically prompted to do so before you do anything that requires stacks or state.
Expand Down Expand Up @@ -187,7 +187,7 @@ This backend also supports [alternative object storage servers with AWS S3 compa
$ pulumi login s3://<bucket-name>?endpoint=my.minio.local:8080&disableSSL=true&s3ForcePathStyle=true
```

##### Logging Into the Azure Blob Storage Backend
##### Logging Into the Azure Blob Storage Backend using the env vars
AaronFriel marked this conversation as resolved.
Show resolved Hide resolved

To use the [Azure Blob Storage](https://azure.microsoft.com/en-us/services/storage/blobs/) backend, pass the `azblob://<container-path>` as your `<backend-url>`:

Expand All @@ -197,6 +197,18 @@ $ pulumi login azblob://<container-path>

To tell Pulumi what Azure storage account to use, set the `AZURE_STORAGE_ACCOUNT` environment variable. Also, set either `AZURE_STORAGE_KEY` or `AZURE_STORAGE_SAS_TOKEN` to authorize access. For additional configuration options, see [Azure Setup]({{< relref "/registry/packages/azure/installation-configuration" >}}). If you're new to Azure Blob Storage, see [the Azure documentation](https://docs.microsoft.com/en-us/azure/storage/blobs/storage-quickstart-blobs-cli).

##### Logging Into the Azure Blob Storage Backend using az cli authentication (as of Pulumi 3.41.1)

Similarly, one can implicitly use az cli authentication by defining the storage account in the URL like so:

```sh
$ pulumi login azblob://<container-path>?storage_account=account_name
```
ekini marked this conversation as resolved.
Show resolved Hide resolved

{{% notes type="info"%}}
Make sure you have "Storage Blob Data Contributor" role assigned to you in IAM. Just having "Owner" is not enough, as that is a "management"-type of role.
ekini marked this conversation as resolved.
Show resolved Hide resolved
{{% /notes %}}

##### Logging Into the Google Cloud Storage Backend

To use the [Google Cloud Storage](https://cloud.google.com/storage/) backend pass the `gs://<bucket-path>` as your `<backend-url>`:
Expand Down