Skip to content

Rewrite of kms-encryption-toolbox's decrypt-and-start in Go

License

Notifications You must be signed in to change notification settings

ApplauseOSS/decrypt-and-start

Folders and files

NameName
Last commit message
Last commit date
Feb 10, 2025
Jul 1, 2019
Dec 5, 2022
Jul 31, 2019
Feb 22, 2022
Feb 10, 2021
Jun 26, 2019
Feb 10, 2025
Apr 13, 2022
Mar 10, 2025
Mar 10, 2025
Sep 10, 2024

Repository files navigation

decrypt-and-start

This project began as a shell script to invoke the kms-encryption decrypt on the variables in the environment, looking for anything with a prefix of "decrypt:", decrypting it using AWS KMS using the instance's profile, and exporting the decrypted value back to the environment before exec to the next command.

This is used as a Docker entrypoint for containers to be able to decrypt encrypted environment variables passed into it.

Usage

This project is a replacement for the ApplauseOSS/kms-encryption-toolbox supplied shell script, decrypt-and-start.

It can be run as:

$ decrypt-and-start some other program

It can also take an optional flag to control the number of parallel workers:

$ decrypt-and-start -p 20 -- some other program

Tool can also assume other role for kms access

$ decrypt-and-start --assume-role arn:aws:iam::XXXXXXXXX:role/YYYY some other program