cardano-docker/monitoring/nginx/entrypoint.sh

14 lines
331 B
Bash
Raw Normal View History

2021-02-13 15:19:38 +00:00
#!/bin/sh
# Init config
echo "Generating config"
cp /nginx.tmpl.conf /config/nginx.conf
sed -i "s/\[PROMETHEUS_HOST\]/${PROMETHEUS_HOST}/g" /config/nginx.conf
cat /config/nginx.conf
echo ""
# Generate password
htpasswd -b -c /config/htpasswd ${USER} ${PASSWORD}
echo "Starting nginx"
nginx -g "daemon off;" -c /config/nginx.conf