https://github.com/brefphp/secrets-loader
Load secret values from SSM into environment variables
https://github.com/brefphp/secrets-loader
aws-lambda aws-ssm aws-ssm-parameter-store bref
Last synced: 3 months ago
JSON representation
Load secret values from SSM into environment variables
- Host: GitHub
- URL: https://github.com/brefphp/secrets-loader
- Owner: brefphp
- License: mit
- Created: 2023-02-21T16:05:58.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-02-07T18:57:06.000Z (5 months ago)
- Last Synced: 2025-04-09T22:12:32.036Z (3 months ago)
- Topics: aws-lambda, aws-ssm, aws-ssm-parameter-store, bref
- Language: PHP
- Homepage: https://bref.sh/docs/environment/variables.html#secrets
- Size: 7.81 KB
- Stars: 13
- Watchers: 1
- Forks: 9
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- Contributing: .github/CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
Automatically load secrets from SSM into environment variables when running with Bref.
It replaces (at runtime) the variables whose value starts with `bref-ssm:`. For example, you could set such a variable in `serverless.yml` like this:
```yaml
provider:
# ...
environment:
MY_PARAMETER: bref-ssm:/my-app/my-parameter
```In AWS Lambda, the `MY_PARAMETER` would be automatically replaced and would contain the value stored at `/my-app/my-parameter` in AWS SSM Parameters.
This feature is shipped as a separate package so that all its code and dependencies are not installed by default for all Bref users. Install this package if you want to use the feature.
## Installation
```
composer require bref/secrets-loader
```## Usage
Read the Bref documentation: https://bref.sh/docs/environment/variables.html#secrets