Skip to content

Instantly share code, notes, and snippets.

@u1i
Created September 2, 2017 07:18
Show Gist options
  • Save u1i/b7907f936956079088b97d3549af729c to your computer and use it in GitHub Desktop.
Save u1i/b7907f936956079088b97d3549af729c to your computer and use it in GitHub Desktop.
Simple nginx docker container with static content
mkdir www
echo "Hello World" > www/index.html
# create a file called Dockerfile
'
FROM nginx
COPY www /usr/share/nginx/html
'
docker build -t my-nginx .
$ docker run -d -p 80:80 my-nginx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment