Custom AWS compatible Secrets Manager for Local Development
1.2K
Goal of this project is to provide a toolbox that mimics basic behaviour of AWS services like SQS, SNS, Secrets Manager and more. This toolbox is intended to be used for local development and testing purposes only.
There is no guarantee that the behaviour of the tools in this toolbox is 100% identical to the behaviour of the AWS, especially the parts of authentication and authorization have been left out on purpose for simplicity reasons.
This application is a simple tool that mimics the AWS Secrets Manager API. It can be used to retrieve secrets from a local in-memory storage.
To build the binary locally, you need a running version of Golang version 1.24 or above as well as make. To start
the build process, simply run the following command inside your local shell:
make build-secrets-manager
If you want to run this tool, you have two ways to provide all necessary configuration data. If you want to run the tool by using a configuration file, you have to set an environment variable to the correct path of the configuration file:
export SECRETS_MANAGER_CONFIG_FILE=/path/to/config.yaml
Otherwise the tool will fallback to the default, environment-based solution.
Passing the configuration via a file is the most convenient way to provide all necessary data. Here you can find an easy example config that contains all valid data:
account: "000000000000"
region: "eu-central-1"
secrets:
- name: example-secret
versions:
- version1_value
- version2_value
Note: The secrets values are stored in a list from NEWEST to OLDEST.
Passing the configuration via environment variables is the second way to provide all necessary data. This is especially useful if you want to run your tools inside docker. Here you can find an easy example that contains all valid data:
export AWS_REGION=eu-central-1
export AWS_ACCOUNT_ID=000000000000
export "SECRETS=example-secret=value1,value2;example-secret-2=value1,value2"
To run the tool locally, you can simply use the following command:
build/secrets-manager
To run the tool in docker, you can easily use a docker-compose.yml file that will create and run the container:
services:
secrets-manager:
image: tliesche/secrets-manager:latest
hostname: secrets-manager
environment:
- AWS_REGION=eu-central-1
- AWS_ACCOUNT_ID=000000000000
- SECRETS_MANAGER_SECRETS=example-secret=value1,value2;example-secret-2=value1,value2
This project is licensed under the MIT License - see the LICENSE file for details.
You can see the changelog here : CHANGELOG.
This project is not affiliated with, endorsed by, or sponsored by Amazon Web Services (AWS). It is an independent project that provides mock implementations for AWS-like services for local development and testing. The names of AWS services (SQS, SNS, Secrets Manager) are used solely for reference purposes.
Content type
Image
Digest
sha256:ecc66f6a0…
Size
65.4 MB
Last updated
over 1 year ago
docker pull tliesche/secrets-manager