1. Packages
  2. AWS Classic
  3. How-to Guides
  4. Setup AWS Secrets manager

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.32.0 published on Friday, Apr 19, 2024 by Pulumi

Setup AWS Secrets manager

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.32.0 published on Friday, Apr 19, 2024 by Pulumi

    View Code Deploy

    A simple program that creates an AWS secret and a version under AWS Secrets Manager

    Deploying and running the program

    1. Create a new stack:

      $ pulumi stack init dev
      
    2. Set the AWS region:

      $ pulumi config set aws:region us-east-1
      
    3. Run pulumi up to preview and deploy changes:

      $ pulumi up
      Previewing update (dev)
      ...
      
      Updating (dev)
      
      View Live: https://app.pulumi.com/acmecorp/aws-go-secrets-manager/dev/updates/1
      
          Type                                 Name                        Status
      +   pulumi:pulumi:Stack                  aws-go-secrets-manager-dev  created
      +   ├─ aws:secretsmanager:Secret         secretcontainer             created
      +   └─ aws:secretsmanager:SecretVersion  secret                      created
      
      Outputs:
          secretContainer: "arn:aws:secretsmanager:us-east-1:xxxxxxxx:secret:secretcontainer-562188f-67Rt8n"
      
      Resources:
          + 3 created
      
      Duration: 11s
      

    Clean up

    1. Run pulumi destroy to tear down all resources.

    2. To delete the stack itself, run pulumi stack rm. Note that this command deletes all deployment history from the Pulumi console.

    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.32.0 published on Friday, Apr 19, 2024 by Pulumi