From 0158f56beb0e3e3855705dd7e927578a8d5dcaaa Mon Sep 17 00:00:00 2001 From: Bryan Joshua Pedini Date: Sun, 25 Sep 2022 17:04:58 +0200 Subject: [PATCH] turned base to nginx deployment --- README.md | 3 +-- docker-compose.yml | 16 ++++++++++------ env.example | 15 ++++++++++----- 3 files changed, 21 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 3ffde1e..f806810 100644 --- a/README.md +++ b/README.md @@ -1,2 +1 @@ -# Base App Deployment -This is the base on which (almost) every deployment is sort-of-based on. +# Nginx Deployment diff --git a/docker-compose.yml b/docker-compose.yml index cf8e041..88e4797 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,6 +1,7 @@ --- services: - app: + nginx: + image: nginx:${NGINX_VERSION} restart: unless-stopped labels: ### Section Træfik @@ -22,11 +23,14 @@ services: # specify a service so a custom port can be used - traefik.http.services.${TRAEFIK_SERVICE}.loadbalancer.server.port=${TRAEFIK_SERVICE_PORT} ### Section Diun - - diun.enable=${DIUN_ENABLE} - - diun.watch_repo=${DIUN_WATCHREPO} - - diun.sort_tags=${DIUN_SORTALGO} - - diun.include_tags=${DIUN_INCLUDE} - - diun.exclude_tags=${DIUN_EXCLUDE} + - diun.enable=${DIUN_NGINX_ENABLE} + - diun.watch_repo=${DIUN_NGINX_WATCHREPO} + - diun.sort_tags=${DIUN_NGINX_SORTALGO} + - diun.include_tags=${DIUN_NGINX_INCLUDE} + - diun.exclude_tags=${DIUN_NGINX_EXCLUDE} + volumes: + - ${NGINX_CONFIG}:/etc/nginx/nginx.conf + - ${NGINX_SITECONFIG}:/etc/nginx/conf.d/default.conf networks: - traefik diff --git a/env.example b/env.example index 263f7aa..ce01f5f 100644 --- a/env.example +++ b/env.example @@ -11,8 +11,13 @@ TRAEFIK_HTTP_MIDDLEWARES=http-to-https TRAEFIK_HTTPS_MIDDLEWARES=hsts # Diun -DIUN_ENABLE=true -DIUN_WATCHREPO=true -DIUN_SORTALGO=semver -DIUN_INCLUDE= -DIUN_EXCLUDE= +DIUN_NGINX_ENABLE=true +DIUN_NGINX_WATCHREPO=true +DIUN_NGINX_SORTALGO=semver +DIUN_NGINX_INCLUDE=[0-9]\.[0-9]\.[0-9]-alpine +DIUN_NGINX_EXCLUDE= + +# Nginx +NGINX_VERSION=1.22.0-alpine +NGINX_CONFIG=./data/nginx.conf +NGINX_SITECONFIG=./data/site.conf