Sign inSign up

divido/nginx

By divido

Updated about 5 years ago

Image
0

10K+

divido/nginx repository overview

Nginx

These docker images are bases for Divido microservices. Many services can use one of these images directly, although if special packages are required then these can serve as bases

NOTE: Images tagged in the Versions table as deprecated will no longer receive updates. Please ensure you keep your images up to date.

Configuration

Configuration for this container is by environment variables, and are defined below:

Environment VariableDescription
DIVIDO_SERVICE_NAMEThese nginx containers log access logs the approved Divido format. When starting the container, the entrypoint will look for an environment variable called DIVIDO_SERVICE_NAME. The value of this will be used in the log line. If this value does not exist (or is empty), the service name will be <SERVICE_NAME_NOT_DEFINED>.
DIVIDO_NGINX_DOCUMENT_ROOTThe document root defaults to /opt/divido/app. If you have an alternative document root, then you can change this with the environment variable DIVIDO_NGINX_DOCUMENT_ROOT. Set this to be the absolute path in the container
DIVIDO_NGINX_CLIENT_MAX_BODY_SIZEThe default client_max_body_size is 1m. If you have other requirements for your service, then you can change this with the environment variable DIVIDO_NGINX_CLIENT_MAX_BODY_SIZE. Set this to be the amount and factor, e.g. 2m
DIVIDO_NGINX_BASIC_AUTHBasic auth protection for your entire site. This image does not support basic auth for individual paths. To add a user and enable basic auth, first create a password using htpassws command line utility. For example, creating a user foo with a password of bar:
htpasswd -nbB foo bar
foo:$2y$05$5IvPpgbn
Then, take the generated output and use this as environment variable: DIVIDO_NGINX_BASIC_AUTH=foo:$2y$05$5IvPpg. Multiple users can be added, separating entries with a comma (,).
Variants
variantexampledescription
null1.17-alpineNo proxy, for use with static websites
*-node1.17-alpine-nodeall traffic will direct to host:node on port 5000 (tcp)
*-php1.17-alpine-phpall traffic will direct to host:fpm on port 9000 (tcp)
Versions

Nginx employ a stable/mainline release matrix, and so Divido nginx images use the same configuration. Explanations of these build types can be found on the nginx blog. Note that this blog refers to Nginx 1.6 & 1.7, but the explanation of stable vs mainline is applicable. Relevant excerpt(s):

In NGINX nomenclature, “stable” means that no new features are added (the feature set is stable). Only major bug fixes are committed to that version. [...] stable does not mean more reliable or more bug‑free. In fact, the mainline is generally regarded as more reliable because we port all bug fixes to it, and not just critical fixes as for the stable branch. [...] We recommend that in general you deploy the NGINX mainline branch at all times. The main reason to use the stable branch is that you are concerned about possible impacts of new features, such as incompatibility with third‑party modules or the inadvertent introduction of bugs in new features.

With the above in mind, the images tagged with the major version only (e.g. 1-alpine will use to the latest mainline version of nginx (within the major scope).

tagnginx versionosupstreamnotes
1-alpine1.19alpinenonelatest (mainline)
1-alpine-php1.19alpinefpmlatest (mainline)
1-alpine-node1.19alpinenodelatest (mainline)
1.19-alpine1.19alpinenonelatest (mainline)
1.19-alpine-php1.19alpinefpmlatest (mainline)
1.19-alpine-node1.19alpinenodelatest (mainline)
1.18-alpine1.18alpinenonelatest (stable)
1.18-alpine-php1.18alpinefpmlatest (stable)
1.18-alpine-node1.18alpinenodelatest (stable)
1.17-alpine1.17alpinenone
1.17-alpine-php1.17alpinefpm
1.17-alpine-node1.17alpinenode
1.16-alpine1.16alpinenonedeprecated
1.16-alpine-php1.16alpinefpmdeprecated
1.16-alpine-node1.16alpinenodedeprecated

Tag summary

Content type

Image

Digest

Size

9.5 MB

Last updated

about 5 years ago

docker pull divido/nginx:1-alpine-node