-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
187 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
deb http://archive.debian.org/debian stretch main |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/bash | ||
# USAGE: | ||
# build-up-php-5-6-apache.sh | ||
# | ||
# NOTE: | ||
# Rebuild the Docker image & compose up. | ||
|
||
# source the environment variables | ||
set -o allexport; source "${PWD}/.env"; set +o allexport | ||
|
||
# Use the EWC Protocol to build the image of the service & compose up | ||
ewc-docker-build-up.sh "php-5-6-apache" "${APACHE_PHP56_DOCKER_BUILD_DESC:-PHP ${PHP_VERSION} & Apache Web Server}" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
version: '3.7' | ||
|
||
# Services/Containers to orchestrate in this composition | ||
services: | ||
|
||
# Basic PHP 5.6 & Apache2 Image Container | ||
php-5-6-apache: | ||
container_name: php-5-6-apache | ||
tty: true | ||
restart: unless-stopped | ||
build: | ||
context: . | ||
target: ${APACHE_PHP56_DOCKER_BUILD_TARGET} | ||
dockerfile: ${DOCKER_BUILD_FILE} | ||
args: | ||
- NPM_VERSION=${NPM_VERSION} | ||
- APP_ENV=${APP_ENV} | ||
labels: | ||
ewc.name: "Web Server" | ||
ewc.description: "${APACHE_PHP56_DOCKER_BUILD_DESC}" | ||
ewc.php.version: "${PHP_VERSION}" | ||
image: ${APACHE_PHP56_DOCKER_IMAGE}:${APACHE_PHP56_DOCKER_IMAGE_TAG} | ||
environment: | ||
- NPM_VERSION=${NPM_VERSION} | ||
- APP_ENV=${APP_ENV} | ||
working_dir: /var/www | ||
ports: | ||
- ${APP_PORT}:80 | ||
- ${APP_SSL_PORT}:443 | ||
volumes: | ||
- ./public_html:/var/www/html | ||
- ./docker-files/php/56.local.ini:/usr/local/etc/php.ini | ||
networks: | ||
- web-app-network | ||
|
||
# Custom network for composed containers to communicate on | ||
networks: | ||
web-app-network: | ||
driver: bridge | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
FROM php:5.6-apache as php-5-6-build | ||
FROM php:5.6-apache as build-php-56-apache | ||
|
||
# Set some image labels | ||
LABEL evilwizardcreations.image.authors="[email protected]" \ | ||
|
@@ -10,6 +10,12 @@ ENV NPM_VERSION=$NPM_VERSION | |
# copy the specific Composer PHAR version from the Composer image into the PHP image | ||
COPY --from=composer:1.7.1 /usr/bin/composer /usr/bin/composer | ||
|
||
# The apt-get sources for this are so old it has been archived & needs chainging | ||
COPY ./build-assets/etc/apt/sources.list /etc/apt/sources.list | ||
|
||
# The pecl is so old it needs the local offline install now | ||
COPY ./build-assets/pecl/yaml-1.3.0.tgz /tmp/yaml-1.3.0.tgz | ||
|
||
# Download the nodejs setup & set that it's a docker env. | ||
ENV NODE_ENV docker | ||
# Node -v v8.12.0 | ||
|
@@ -38,5 +44,56 @@ RUN set -ex; \ | |
|
||
# Install some php extensions from the docker built source. | ||
RUN docker-php-ext-install gettext mysqli pdo_mysql zip | ||
RUN pecl install yaml-1.3.0 && \ | ||
RUN pecl channel-update pecl.php.net && \ | ||
pecl install --offline /tmp/yaml-1.3.0.tgz && \ | ||
docker-php-ext-enable yaml && \ | ||
rm /tmp/yaml-1.3.0.tgz | ||
|
||
# A test build to play with while getting it all working | ||
FROM php:5.6-apache as build-php-56-apache-test | ||
|
||
# Set some image labels | ||
LABEL evilwizardcreations.image.authors="[email protected]" \ | ||
evilwizardcreations.image.php.version="5.6" | ||
|
||
ARG NPM_VERSION=6.4.1 | ||
ENV NPM_VERSION=$NPM_VERSION | ||
|
||
# copy the specific Composer PHAR version from the Composer image into the PHP image | ||
COPY --from=composer:1.7.1 /usr/bin/composer /usr/bin/composer | ||
|
||
# The apt-get sources for this are so old it has been archived & needs chainging | ||
COPY ./build-assets/etc/apt/sources.list /etc/apt/sources.list | ||
|
||
# The pecl is so old it needs the local offline install now | ||
COPY ./build-assets/pecl/yaml-1.3.0.tgz /tmp/yaml-1.3.0.tgz | ||
|
||
# Download the nodejs setup & set that it's a docker env. | ||
ENV NODE_ENV docker | ||
# Node -v v8.12.0 | ||
#RUN curl --silent --location https://deb.nodesource.com/setup_8.x | bash | ||
|
||
# Enable some apache modules. | ||
RUN a2enmod rewrite; \ | ||
a2enmod headers; \ | ||
a2enmod ssl | ||
|
||
RUN set -ex; \ | ||
apt-get update; \ | ||
apt-get install -y --no-install-recommends \ | ||
libxml2-dev \ | ||
libzip-dev \ | ||
libyaml-dev \ | ||
zip \ | ||
unzip \ | ||
git \ | ||
nodejs \ | ||
default-mysql-client \ | ||
vim; \ | ||
apt-get clean | ||
|
||
# Install some php extensions from the docker built source. | ||
RUN docker-php-ext-install gettext mysqli pdo_mysql zip | ||
RUN pecl channel-update pecl.php.net && \ | ||
pecl install --offline /tmp/yaml-1.3.0.tgz && \ | ||
docker-php-ext-enable yaml |
Oops, something went wrong.