Updates development.sh

This commit is contained in:
Sam ONeill 2022-02-08 14:27:26 +13:00
parent 79a209c469
commit 5dc422619b
5 changed files with 13 additions and 14 deletions

View file

@ -1,4 +1,4 @@
FROM php:7.2.5-fpm-alpine3.7 as build FROM php:7.2.11-fpm-alpine3.7 as build
RUN apk update \ RUN apk update \
&& apk add --no-cache libpng-dev zeromq-dev git \ && apk add --no-cache libpng-dev zeromq-dev git \
@ -25,12 +25,6 @@ COPY static/nginx/site.conf /etc/nginx/templateSite.conf
# Configure PHP-FPM # Configure PHP-FPM
COPY static/php/fpm-pool.conf /etc/php7/php-fpm.d/zzz_custom.conf COPY static/php/fpm-pool.conf /etc/php7/php-fpm.d/zzz_custom.conf
# DEBUG
RUN apk add php7-xdebug --repository http://dl-3.alpinelinux.org/alpine/edge/testing/
COPY static/php/xdebug.ini /etc/php7/conf.d/xdebug.ini
COPY static/php/error_reporting.ini /etc/php7/conf.d/error_reporting.ini
RUN echo "zend_extension=/usr/lib/php7/modules/xdebug.so" >> /etc/php7/php.ini
COPY static/php/php.ini /etc/zzz_custom.ini COPY static/php/php.ini /etc/zzz_custom.ini
# configure cron # configure cron
COPY static/crontab.txt /var/crontab.txt COPY static/crontab.txt /var/crontab.txt
@ -41,7 +35,6 @@ COPY static/entrypoint.sh /
WORKDIR /var/www/html WORKDIR /var/www/html
COPY --chown=nobody --from=build /app pathfinder COPY --chown=nobody --from=build /app pathfinder
RUN chmod 0766 pathfinder/logs pathfinder/tmp/ && rm index.php && touch /etc/nginx/.setup_pass && chmod +x /entrypoint.sh RUN chmod 0766 pathfinder/logs pathfinder/tmp/ && rm index.php && touch /etc/nginx/.setup_pass && chmod +x /entrypoint.sh
COPY static/pathfinder/routes.ini /var/www/html/pathfinder/app/ COPY static/pathfinder/routes.ini /var/www/html/pathfinder/app/
COPY static/pathfinder/environment.ini /var/www/html/pathfinder/app/templateEnvironment.ini COPY static/pathfinder/environment.ini /var/www/html/pathfinder/app/templateEnvironment.ini

View file

@ -1,4 +1,4 @@
FROM php:7.2.5-fpm-alpine3.7 as build FROM php:7.2.11-fpm-alpine3.7 as build
RUN apk update \ RUN apk update \
&& apk add --no-cache libpng-dev zeromq-dev git \ && apk add --no-cache libpng-dev zeromq-dev git \
@ -41,7 +41,6 @@ COPY static/entrypoint.sh /
WORKDIR /var/www/html WORKDIR /var/www/html
COPY --chown=nobody --from=build /app pathfinder COPY --chown=nobody --from=build /app pathfinder
RUN chmod 0766 pathfinder/logs pathfinder/tmp/ && rm index.php && touch /etc/nginx/.setup_pass && chmod +x /entrypoint.sh RUN chmod 0766 pathfinder/logs pathfinder/tmp/ && rm index.php && touch /etc/nginx/.setup_pass && chmod +x /entrypoint.sh
COPY static/pathfinder/routes.ini /var/www/html/pathfinder/app/ COPY static/pathfinder/routes.ini /var/www/html/pathfinder/app/
COPY static/pathfinder/environment.ini /var/www/html/pathfinder/app/templateEnvironment.ini COPY static/pathfinder/environment.ini /var/www/html/pathfinder/app/templateEnvironment.ini

View file

@ -55,6 +55,7 @@ services:
- "traefik.http.routers.pf.entrypoints=web" - "traefik.http.routers.pf.entrypoints=web"
- "traefik.http.routers.pf-secure.rule=Host(`${DOMAIN}`)" - "traefik.http.routers.pf-secure.rule=Host(`${DOMAIN}`)"
- "traefik.http.routers.pf-secure.entrypoints=websecure" - "traefik.http.routers.pf-secure.entrypoints=websecure"
- "traefik.http.routers.pf-secure.tls.certresolver=letsencrypt"
- "traefik.http.routers.pf-secure.tls=true" - "traefik.http.routers.pf-secure.tls=true"
- "traefik.http.middlewares.redirecthttps.redirectscheme.scheme=https" - "traefik.http.middlewares.redirecthttps.redirectscheme.scheme=https"
- "traefik.http.routers.pf.middlewares=redirecthttps" - "traefik.http.routers.pf.middlewares=redirecthttps"
@ -83,12 +84,19 @@ services:
- "--providers.docker.exposedbydefault=false" - "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80" - "--entrypoints.web.address=:80"
- "--entrypoints.websecure.address=:443" - "--entrypoints.websecure.address=:443"
- "--certificatesresolvers.letsencrypt.acme.httpchallenge=true"
- "--certificatesresolvers.letsencrypt.acme.httpchallenge.entrypoint=web"
- "--certificatesresolvers.letsencrypt.acme.storage=/letsencrypt/acme.json"
# Remove below line when ready for production
- "--certificatesresolvers.letsencrypt.acme.caserver=https://acme-staging-v02.api.letsencrypt.org/directory"
- "--certificatesresolvers.letsencrypt.acme.email=MYEMAIL@someemailprobablygmail.com"
ports: ports:
- "80:80" - "80:80"
- "443:443" - "443:443"
- "8080:8080" - "8080:8080"
volumes: volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro" - "/var/run/docker.sock:/var/run/docker.sock:ro"
- "${PROJECT_ROOT}/letsencrypt:/letsencrypt"
networks: networks:
- web - web
restart: always restart: always

View file

@ -4,16 +4,16 @@
; project environment (DEVELOP || PRODUCTION). ; project environment (DEVELOP || PRODUCTION).
; This effects: DB connection, Mail-Server, SSO, ESI configurations in this file ; This effects: DB connection, Mail-Server, SSO, ESI configurations in this file
; configuration below ; configuration below
SERVER = DEVELOPMENT SERVER = PRODUCTION
[ENVIRONMENT.DEVELOPMENT] [ENVIRONMENT.PRODUCTION]
; path to index.php (Default: leave blank == "auto-detect") ; path to index.php (Default: leave blank == "auto-detect")
; -> e.g. set /pathfinder if your URL looks like https://www.[YOUR_DOMAIN]/pathfinder (subfolder) ; -> e.g. set /pathfinder if your URL looks like https://www.[YOUR_DOMAIN]/pathfinder (subfolder)
BASE = BASE =
; deployment URL (e.g. https://www.pathfinder-w.space) ; deployment URL (e.g. https://www.pathfinder-w.space)
URL = {{@SCHEME}}://$DOMAIN URL = {{@SCHEME}}://$DOMAIN
; level of debug/error stack trace ; level of debug/error stack trace
DEBUG = 3 DEBUG = 0
; Pathfinder database ; Pathfinder database
DB_PF_DNS = mysql:host=${CONTAINER_NAME}db;port=3306;dbname= DB_PF_DNS = mysql:host=${CONTAINER_NAME}db;port=3306;dbname=
DB_PF_NAME = pf DB_PF_NAME = pf

View file

@ -10,7 +10,6 @@ fastcgi.logging=0
request_terminate_timeout = 300 request_terminate_timeout = 300
session.save_handler = redis session.save_handler = redis
session.save_path = "tcp://${CONTAINER_NAME}-redis:6379" session.save_path = "tcp://${CONTAINER_NAME}-redis:6379"
zend_extension=/usr/lib/php7/modules/xdebug.so
[Date] [Date]
date.timezone="UTC" date.timezone="UTC"