Skip to content

Instantly share code, notes, and snippets.

@Perlence
Created February 11, 2016 12:58
Show Gist options
  • Select an option

  • Save Perlence/fc3e5432fe62b8e552f2 to your computer and use it in GitHub Desktop.

Select an option

Save Perlence/fc3e5432fe62b8e552f2 to your computer and use it in GitHub Desktop.
Using envsubst with Docker in entrypoint
#!/bin/bash
set -e
# Substitute environment variables in Prosody configs
for tpl in /etc/prosody/*.tpl; do
envsubst < $tpl > ${tpl%\.tpl}
done
exec su -s /bin/bash -c "$*" prosody
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment