Add entrypoint that copies production configs

This commit is contained in:
Sebastián Ramírez 2017-06-24 18:15:52 -05:00
parent 1ff4676811
commit f142175917

12
docker-entrypoint.sh Normal file
View file

@ -0,0 +1,12 @@
#!/bin/bash
set -e
if [ ! -f "/app/config/production.toml" ] ; then
echo "No production.toml, copying from docker-production.toml.tmpl"
cp /app/config/docker-production.toml.tmpl /app/config/production.toml
fi
if [ ! -f "/app/workers/reports/config/production.toml" ] ; then
echo "No production.toml for reports, copying from docker-production.toml.tmpl"
cp /app/config/docker-production.toml.tmpl /app/workers/reports/config/production.toml
fi
exec "$@"