Docker environment updates and improvements

This commit is contained in:
Chris Kankiewicz
2019-12-25 23:51:22 -07:00
parent 6a06089a0d
commit 2789fa88e0
2 changed files with 7 additions and 10 deletions

View File

@@ -5,20 +5,19 @@ RUN composer install --working-dir /app --ignore-platform-reqs \
--no-cache --no-dev --no-interaction
# Install and compile JavaScript assets
# FROM node:12.10 AS js-dependencies
# ARG FONT_AWESOME_TOKEN
# COPY --from=php-dependencies /app /app
# RUN cd /app && npm install && npm run production
FROM node:13.2 AS js-dependencies
COPY --from=php-dependencies /app /app
RUN cd /app && npm install && npm run production
# Build application image
FROM php:7.3-apache as application
LABEL maintainer="Chris Kankiewicz <ckankiewicz@freedomdebtrelief.com>"
FROM php:7.4-apache as application
LABEL maintainer="Chris Kankiewicz <Chris@ChrisKankiewicz.com>"
COPY --from=php-dependencies /app /var/www/html
COPY --from=js-dependencies /app /var/www/html
RUN a2enmod rewrite
# Build (local) development image
# Build development image
FROM application as development
COPY ./.docker/php/config/php.dev.ini /usr/local/etc/php/php.ini
COPY ./.docker/apache2/config/000-default.dev.conf /etc/apache2/sites-available/000-default.conf

View File

@@ -10,8 +10,6 @@ services:
VIRTUAL_HOST: directorylister.local
volumes:
- ./:/var/www/html
# - ./.docker/php/config/php.dev.ini:/usr/local/etc/php/php.ini
# - ./.docker/apache2/config/000-default.dev.conf:/etc/apache2/sites-available/000-default.conf
restart: unless-stopped
networks: