This repository contains a Dockerfile of Nginx for Docker's trusted build published to the public Docker Registry.
- Install Docker.
- Build the image with either
- docker build -t="jonathanmiller/docker-nginx" github.com/jonathanmiller/docker-nginx
- Manually with Git clone 1. git clone https://github.com/jonathanmiller/docker-nginx 2. cd docker-nginx 3. docker build .
Basic Execution
docker run -d -p 80:80 jonathanmiller/docker-nginx
With SSL
docker run -d -p 80:80 -p 443:443 jonathanmiller/docker-nginx
Attach Log and Server Configuration Volumes
docker run -d \
-p 80:80 \
-p 443:443 \
-v <log-dir>:/var/log/nginx \
-v <sites-enabled-dir>:/servers \
jonathanmiller/docker-nginx