Skip to content

Latest commit

 

History

History
61 lines (43 loc) · 2.34 KB

README.md

File metadata and controls

61 lines (43 loc) · 2.34 KB

AWS Secrets Manager Actions

npm version GitHub Actions Test GitHub Actions Publish GitHub license

This GitHub Action helps you use your Environment values from AWS Secrets Manager.

Usage

steps:
 - name: Store ENV from AWS SecretManager
   uses: say8425/[email protected]
   with:
     AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
     AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
     AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
     SECRET_NAME: ${{ secrets.SECRET_NAME }}

AWS IAM

You need AWS IAM user that has proper policy to access AWS Secrets Manager. And this IAM user keys at AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY and region AWS_DEFAULT_REGION. But we greatly recommend to store the keys at GitHub Secrets and use it.

Policy

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "VisualEditor0",
            "Effect": "Allow",
            "Action": "secretsmanager:GetSecretValue",
            "Resource": "*"
        }
    ]
}

If you need policy example, then feel free to use above policy. And you can get more information at AWS User Guide.

Secret Name

Add you want to get secret name from secrets list.

Environments

Then you can use your all secrects from AWS Secrets Manager through Environment values.

Contributing

AWS Secrets Manager Actions did not have any test yet. And code needs to be refactored. So your Contributions are welcome! Feel free to check issues page.

License

This project is MIT licensed.