Skip to content

Instantly share code, notes, and snippets.

@acdha
Created September 7, 2018 14:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save acdha/c8010c86c795451fc7e2b8d06dd214ae to your computer and use it in GitHub Desktop.
Save acdha/c8010c86c795451fc7e2b8d06dd214ae to your computer and use it in GitHub Desktop.
Using jq to export bash-compatible exports for an AWS ECS task definition's environment stanza
aws ecs describe-task-definition --task-definition=sentry | jq -r '.taskDefinition.containerDefinitions[] | .environment[] | "export \(.name)=\(.value)"'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment