description |
---|
Setup and usage guide on how to continuously sync your secrets with AWS Secrets Manager. |
- AWS Console Access
- AWS IAM access
- Ability to create IAM roles and Policies
- Ability to access IAM users
-
Create new AWS policy
- Navigate to the Create New Policy section in the AWS IAM console.
- Switch to the JSON tab.
- Enter the following policy.
{ "Version": "2012-10-17", "Statement": [ { "Sid": "AllowSecretsManagerAccess", "Effect": "Allow", "Action": [ "secretsmanager:GetSecretValue", "secretsmanager:DescribeSecret", "secretsmanager:PutSecretValue", "secretsmanager:CreateSecret", "secretsmanager:DeleteSecret", "secretsmanager:TagResource", "secretsmanager:UpdateSecret" ], "Resource": "*" } ] }
- Optionally provide tags.
- Name your policy as "envsecrets" and hit create.
-
Create an AWS Role
- Navigate to the create role section of the AWS IAM console
- Select AWS account for the Trusted entity type
- Select Another AWS account under An AWS account
- Enter 284838358097 for the Account ID. This is envsecrets's account ID.
- Under Options check Require external ID
- Enter your organisation ID for the External ID. You can obtain your organisation ID by visiting the organisation settings in your envsecrets dashboard.
- Leave require MFA unchecked
- Attach the "envsecrets" policy you created above.
- Name your role as "envsecrets" and complete the role setup.
- Copy the new role's ARN.
-
Configuration
- Go to integrations catalog in your envsecrets dashboard and choose "AWS Secrets Manager."
- On the setup/connection page, enter your AWS region and ARN of the "envsecrets" role you created above and save.
- Go to the integrations dashboard in your envsecrets organisation and under "AWS Secrets Manager" choose "Manage."
- Click on "Sync Secrets" button.
- In the page that opens, select your envsecrets project, environment and enter the name with which you wish you save your secret in AWS Secrets Manager.
- Complete and save the form.
- Right after saving the configuration and activating an integration on a specific environment in envsecrets, your secrets will automatically get synced for the first time to your AWS Secrets Manager. It is advisable you open your ASM dashboard and check the values in your new secret.
- From here on, every time you create a new version of your secrets in your environment, the new values will automatically get pushed to your ASM secret.
{% hint style="warning" %} Every new version of your secret in envsecrets will create a new version of the existing secret in AWS Secrets Manager. {% endhint %}