forked from docker-library/drupal
-
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.
Add FPM variants (styled after OwnCloud's script updates for this sam…
…e thing)
- Loading branch information
Showing
7 changed files
with
83 additions
and
19 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
File renamed without changes.
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,20 @@ | ||
# from https://www.drupal.org/requirements/php#drupalversions | ||
FROM php:5.6-fpm | ||
|
||
# install the PHP extensions we need | ||
RUN apt-get update && apt-get install -y libpng12-dev libjpeg-dev libpq-dev \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ | ||
&& docker-php-ext-install gd mbstring pdo pdo_mysql pdo_pgsql zip | ||
|
||
WORKDIR /var/www/html | ||
|
||
# https://www.drupal.org/node/3060/release | ||
ENV DRUPAL_VERSION 7.42 | ||
ENV DRUPAL_MD5 9a96f67474e209dd48750ba6fccc77db | ||
|
||
RUN curl -fSL "http://ftp.drupal.org/files/projects/drupal-${DRUPAL_VERSION}.tar.gz" -o drupal.tar.gz \ | ||
&& echo "${DRUPAL_MD5} *drupal.tar.gz" | md5sum -c - \ | ||
&& tar -xz --strip-components=1 -f drupal.tar.gz \ | ||
&& rm drupal.tar.gz \ | ||
&& chown -R www-data:www-data sites |
File renamed without changes.
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,31 @@ | ||
# from https://www.drupal.org/requirements/php#drupalversions | ||
FROM php:5.6-fpm | ||
|
||
# install the PHP extensions we need | ||
RUN apt-get update && apt-get install -y libpng12-dev libjpeg-dev libpq-dev \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ | ||
&& docker-php-ext-install gd mbstring opcache pdo pdo_mysql pdo_pgsql zip | ||
|
||
# set recommended PHP.ini settings | ||
# see https://secure.php.net/manual/en/opcache.installation.php | ||
RUN { \ | ||
echo 'opcache.memory_consumption=128'; \ | ||
echo 'opcache.interned_strings_buffer=8'; \ | ||
echo 'opcache.max_accelerated_files=4000'; \ | ||
echo 'opcache.revalidate_freq=60'; \ | ||
echo 'opcache.fast_shutdown=1'; \ | ||
echo 'opcache.enable_cli=1'; \ | ||
} > /usr/local/etc/php/conf.d/opcache-recommended.ini | ||
|
||
WORKDIR /var/www/html | ||
|
||
# https://www.drupal.org/node/3060/release | ||
ENV DRUPAL_VERSION 8.0.3 | ||
ENV DRUPAL_MD5 7d5f5278a870b8f4a29cda4fe915d619 | ||
|
||
RUN curl -fSL "http://ftp.drupal.org/files/projects/drupal-${DRUPAL_VERSION}.tar.gz" -o drupal.tar.gz \ | ||
&& echo "${DRUPAL_MD5} *drupal.tar.gz" | md5sum -c - \ | ||
&& tar -xz --strip-components=1 -f drupal.tar.gz \ | ||
&& rm drupal.tar.gz \ | ||
&& chown -R www-data:www-data sites |
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 |
---|---|---|
|
@@ -15,18 +15,27 @@ url='git://github.com/docker-library/drupal' | |
echo '# maintainer: InfoSiftr <[email protected]> (@infosiftr)' | ||
|
||
for version in "${versions[@]}"; do | ||
commit="$(cd "$version" && git log -1 --format='format:%H' -- Dockerfile $(awk 'toupper($1) == "COPY" { for (i = 2; i < NF; i++) { print $i } }' Dockerfile))" | ||
fullVersion="$(grep -m1 'ENV DRUPAL_VERSION' "$version/Dockerfile" | cut -d' ' -f3)" | ||
|
||
versionAliases=() | ||
while [ "$fullVersion" != "$version" -a "${fullVersion%[.-]*}" != "$fullVersion" ]; do | ||
versionAliases+=( $fullVersion ) | ||
fullVersion="${fullVersion%[.-]*}" | ||
done | ||
versionAliases+=( $version ${aliases[$version]} ) | ||
|
||
echo | ||
for va in "${versionAliases[@]}"; do | ||
echo "$va: ${url}@${commit} $version" | ||
for variant in apache fpm; do | ||
commit="$(cd "$version/$variant" && git log -1 --format='format:%H' -- Dockerfile $(awk 'toupper($1) == "COPY" { for (i = 2; i < NF; i++) { print $i } }' Dockerfile))" | ||
fullVersion="$(grep -m1 'ENV DRUPAL_VERSION ' "$version/$variant/Dockerfile" | cut -d' ' -f3)" | ||
|
||
versionAliases=() | ||
while [ "$fullVersion" != "$version" -a "${fullVersion%[.-]*}" != "$fullVersion" ]; do | ||
versionAliases+=( $fullVersion ) | ||
fullVersion="${fullVersion%[.-]*}" | ||
done | ||
versionAliases+=( $version ${aliases[$version]} ) | ||
|
||
echo | ||
for va in "${versionAliases[@]}"; do | ||
if [ "$va" = 'latest' ]; then | ||
echo "$variant: ${url}@${commit} $version/$variant" | ||
else | ||
echo "$va-$variant: ${url}@${commit} $version/$variant" | ||
fi | ||
if [ "$variant" = 'apache' ]; then | ||
echo "$va: ${url}@${commit} $version/$variant" | ||
fi | ||
done | ||
done | ||
done |
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