
# cat /var/www/index.html

# Substitute the script with src by an equivalent inline script.
sed -i "s|<script src=\"/env.js\"></script>|<script src=\"${subs}\"></script>|" /var/www/index.html

# echo 'After substitution'
# cat /var/www/index.html

test -n "$PORT"

envsubst "\$PORT" < /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf