Sign inSign up

fedorza/nginx-hence

By fedorza

Updated over 9 years ago

Nginx image based on hence/nginx

Image
0

530

fedorza/nginx-hence repository overview

Hence Ngnix

Note: This image is still in BETA, and is subject to change without notice.

This is our minimal customized Nginx image based on alpine:3.2.

It uses the s6-overlay as a process supervisor and for log rotation.

Features

Builds on the hence/base image to provide a minimally-sized, fully functional Nginx environment.

This image includes some configuration presets for various applications:

  • php: Preset to run a basic php app
  • nodejs: Preset to proxy to a running nodeJS app
  • angular: Preset to run an angularJS app
  • drupal7: Preset to run a Drupal 7 app

Use a preset by passing -e NGINX_CONFIG_PRESET=[name] to docker run.

In addition to that we provide different volumes to overwrite the behavior of Nginx. In order to customize the behavior of Nginx you can inject configurations into the volume /etc/nginx/custom.d, this directory gets loaded by the server configuration directly.

Default supervised processes:
  • s6-svscan (as PID 1)
  • nginx
  • nginx-logs (log fifo)
  • nginx-error-logs (log fifo)
  • nginx-app-logs (log fifo)
  • nginx-app-error-logs (log fifo)

Available nginx environment variables [defaults]

NGINX_CONFIG_PRESET []
NGINX_PHP_ALIAS [php]
NGINX_PROXY_PATH [rest/api]
NGINX_PROXY_HOST [localhost]
NGINX_PROXY_PORT [3000]
NGINX_SSL_ENABLE [0] (Set to 1 to enable SSL)
NGINX_SSL_CERT_FILE [] (Needs to be volume-mounted to /etc/ssl/certs/[filename])
NGINX_SSL_CERT_KEY_FILE [] (Needs to be volume-mounted to /etc/ssl/private/[filename])
NGINX_FASTCGI_READ_TIMEOUT [300]
NGINX_FASTCGI_IGNORE_CLIENT_ABORT [off]
NGINX_CLIENT_MAX_BODY_SIZE [128m]
NGINX_CLIENT_BODY_BUFFER_SIZE [128k]
NGINX_HTPASSWD_ENABLE [0] (Set to 1 to enable .htpasswd basic auth)
NGINX_HTPASSWD_USER [hence]
NGINX_HTPASSWD_PASSWORD [access]

Authors

License

MIT

Copyright (c) 2015 Therefore Interactive

Tag summary

Content type

Image

Digest

Size

17.8 MB

Last updated

over 9 years ago

docker pull fedorza/nginx-hence