Skip to content

Commit

Permalink
Nginx: changed to ondrej/nginx (#71)
Browse files Browse the repository at this point in the history
* Dockerfile: moving from nginx to ondrej PPA

Base OS moved from Ubuntu 18.04 —> 20.04

* Travis: updated for parallelism

Co-authored-by: Bryan Latten <latten@adobe.com>
  • Loading branch information
bryanlatten and Bryan Latten authored Apr 30, 2020
1 parent 0ee8249 commit f1f235a
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 9 deletions.
8 changes: 8 additions & 0 deletions .test.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
SERVER_LOG_MINIMAL=1
SERVER_APP_NAME=docker-nginx
S6_KILL_FINISH_MAXTIME=1
S6_KILL_GRACETIME=1
SERVER_WORKER_PROCESSES=1
SERVER_CLIENT_HEADER_BUFFER_SIZE=8k
SERVER_LARGE_CLIENT_HEADER_BUFFERS=8 16k
SERVER_CLIENT_BODY_BUFFER_SIZE=128k
15 changes: 8 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
sudo: required

env:
- DOCKERFILE=Dockerfile
- DOCKERFILE=Dockerfile-alpine
- DOCKERFILE=Dockerfile-centos

services:
- docker

script:
- docker-compose build ubuntu
- docker-compose build alpine
- docker-compose build centos
- docker-compose up -d
- docker build -t nginxtest -f ${DOCKERFILE} .
- docker run -p 8080:8080 -d nginxtest
- docker run -p 8081:8080 -d --env-file ./.test.env nginxtest
- sleep 5
- docker-compose ps
- curl localhost:8080 | grep "Welcome to nginx!"
- curl localhost:8081 | grep "Welcome to nginx!"
- curl localhost:8082 | grep "Welcome to nginx!"
- docker-compose kill
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM behance/docker-base:2.6-ubuntu-18.04
FROM behance/docker-base:2.6-ubuntu-20.04
MAINTAINER Bryan Latten <latten@adobe.com>

# Use in multi-phase builds, when an init process requests for the container to gracefully exit, so that it may be committed
Expand All @@ -21,7 +21,7 @@ RUN /bin/bash -e /security_updates.sh && \
apt-get install --no-install-recommends -yqq \
software-properties-common \
&& \
add-apt-repository ppa:nginx/development -y && \
add-apt-repository ppa:ondrej/nginx -y && \
apt-get update -yqq && \
apt-get install -yqq --no-install-recommends \
nginx-light \
Expand Down

0 comments on commit f1f235a

Please sign in to comment.