#!/bin/sh # Exit at first error set -e # Fill the varibles in default.template and put the result in default.conf envsubst "`env | awk -F = '{printf \" $$%s\", $$1}'`" < \ /etc/nginx/nginx.template > \ /etc/nginx/nginx.conf cat /etc/nginx/nginx.conf nginx -g 'daemon off;'