Oversimplified NGINX configuration generation
Shell
Latest commit 26cea48 Dec 3, 2016 @tianon tianon Ignore SSL-enabled listen directives for non-SSL-enabled server blocks
This is to fix the following error:
  [error] 6#6: *13 no "ssl_certificate" is defined in server listening on SSL port while SSL handshaking, client: x.x.x.x, server: 0.0.0.0:443
Permalink
Failed to load latest commit information.
example Ignore SSL-enabled listen directives for non-SSL-enabled server blocks Dec 3, 2016
.travis.yml
README.md
force-proto.include
generate.sh Ignore SSL-enabled listen directives for non-SSL-enabled server blocks Dec 3, 2016
proxy-pass.include Add initial generate.sh and includes Jan 30, 2015
set-proto.include
ssl.include

README.md

Copy example/config.sh to the directory of your choice. Modify as desired.

When you're ready, run with something like:

$ ./generate.sh /path/to/target/config.sh
$ docker run -d \
    --name nginx \
    -p 80:80 \
    --dns 172.17.42.1 \
    -v /path/to/target:/etc/nginx/conf.d:ro \
    -v /path/to/static/resources/referenced/in/config:/static:ro \
    --restart always \
    nginx
$ sleep 1 # to give it a moment to come up
$ docker logs nginx