-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Labels
@aws-cdk/aws-secretsmanagerRelated to AWS Secrets ManagerRelated to AWS Secrets Managereffort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p1
Description
In the link below it's specified in the docs that we can create secrets from a JSON file containing the values of the secrets.
aws secretsmanager create-secret --name MyTestDatabaseSecret \
--description "My test database secret created with the CLI" \
--secret-string file://mycreds.json
Unfortunately, I don't find a way to do this with aws cdk. The create-secret method doesn't accept values of the secrets themselves and code like below will autogenerate a secret.
new secretsmanager.Secret(this, 'Secret', {
description: 'secret description,
secretName: 'secretName'
});
Secrets manager docs from CLI:
https://docs.aws.amazon.com/cli/latest/reference/secretsmanager/create-secret.html#examples
AWS CDK secrets manager docs:
https://docs.aws.amazon.com/cdk/api/latest/docs/@aws-cdk_aws-secretsmanager.Secret.html
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
@aws-cdk/aws-secretsmanagerRelated to AWS Secrets ManagerRelated to AWS Secrets Managereffort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p1