Skip to content

Instantly share code, notes, and snippets.

@ChrisSwanson
Created June 1, 2022 23:45
Show Gist options
  • Save ChrisSwanson/62cdc4b6eaab5cb3821124c89b91a954 to your computer and use it in GitHub Desktop.
Save ChrisSwanson/62cdc4b6eaab5cb3821124c89b91a954 to your computer and use it in GitHub Desktop.
.env to Docker ENV oneliner
#!/usr/bin/bash
cat .env | awk -F"\=" '{ print $1 }' | grep -v -e '^$' | while read line; do echo "ENV $line=\"\""; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment