This repository was archived by the owner on Feb 12, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[TASK] Move all PHP images to alpine (#10)
- Loading branch information
1 parent
a337d22
commit 710d5f2
Showing
8 changed files
with
66 additions
and
84 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,28 @@ | ||
FROM php:5.5-cli | ||
FROM php:5.5-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
RUN apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/main \ | ||
libssl1.1 \ | ||
zstd-dev \ | ||
zstd-libs | ||
|
||
RUN apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community \ | ||
libressl \ | ||
libressl-dev \ | ||
libzip-dev | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
graphicsmagick \ | ||
imagemagick \ | ||
grep \ | ||
net-tools \ | ||
zlib-dev \ | ||
cyrus-sasl-dev \ | ||
zip \ | ||
&& chmod +x /usr/local/bin/install-php-extensions \ | ||
&& sync \ | ||
&& install-php-extensions \ | ||
|
@@ -26,8 +38,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
mysqli \ | ||
opcache \ | ||
pdo_mysql \ | ||
pdo_pgsql \ | ||
pgsql \ | ||
pspell \ | ||
redis \ | ||
soap \ | ||
|
@@ -50,10 +60,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,9 @@ | ||
FROM php:5.6-cli | ||
FROM php:5.6-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -26,8 +26,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
mysqli \ | ||
opcache \ | ||
pdo_mysql \ | ||
pdo_pgsql \ | ||
pgsql \ | ||
pspell \ | ||
redis \ | ||
soap \ | ||
|
@@ -51,10 +49,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,13 @@ | ||
FROM php:7.0-cli | ||
FROM php:7.0-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
RUN apk add --repository=https://dl-cdn.alpinelinux.org/alpine/v3.9/main \ | ||
unixodbc \ | ||
unixodbc-dev | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -27,15 +31,27 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
opcache \ | ||
pdo_mysql \ | ||
pdo_pgsql \ | ||
pdo_sqlsrv \ | ||
pgsql \ | ||
pspell \ | ||
redis \ | ||
soap \ | ||
sqlsrv \ | ||
sysvsem \ | ||
xdebug-^2.8 \ | ||
zip \ | ||
# Manually install sqlsrv, docker-php-extension-installer downgrades unixodbc again which breaks the installation on alpine 3.7 \ | ||
&& mkdir /opt \ | ||
&& mkdir -p /tmp/src \ | ||
&& rm -rf /tmp/src/msodbcsql.apk \ | ||
&& curl -sSLf -o /tmp/src/msodbcsql.apk https://download.microsoft.com/download/e/4/e/e4e67866-dffd-428c-aac7-8d28ddafb39b/msodbcsql17_17.8.1.1-1_amd64.apk \ | ||
&& apk add --allow-untrusted /tmp/src/msodbcsql.apk \ | ||
&& rm -rf /tmp/src/msodbcsql.apk \ | ||
&& apk add --no-cache autoconf make gcc g++ \ | ||
&& pecl install pdo_sqlsrv-5.3.0 \ | ||
&& pecl install sqlsrv-5.3.0 \ | ||
&& apk del autoconf make gcc g++ \ | ||
&& docker-php-ext-enable pdo_sqlsrv \ | ||
&& docker-php-ext-enable sqlsrv \ | ||
# Continue regular setup | ||
&& mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini" \ | ||
&& sed -i s/';phar.readonly = On'/'phar.readonly = Off'/ $PHP_INI_DIR/php.ini \ | ||
&& sed -i s/'memory_limit = 128M'/'memory_limit = 2G'/ $PHP_INI_DIR/php.ini \ | ||
|
@@ -53,10 +69,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,9 @@ | ||
FROM php:7.1-cli | ||
FROM php:7.1-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -53,10 +53,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,9 @@ | ||
FROM php:7.2-cli | ||
FROM php:7.2-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -53,10 +53,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,9 @@ | ||
FROM php:7.3-cli-buster | ||
FROM php:7.3-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -53,10 +53,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |
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,9 +1,9 @@ | ||
FROM php:7.4-cli-buster | ||
FROM php:7.4-alpine | ||
MAINTAINER TYPO3 GmbH <[email protected]> | ||
|
||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
RUN apk add --no-cache \ | ||
bash \ | ||
file \ | ||
git \ | ||
|
@@ -53,10 +53,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
grep -v 'zend_extension=xdebug.so' | \ | ||
grep -v '^;' | \ | ||
grep -v '^$' > /etc/php/cli-no-xdebug/php.ini \ | ||
&& apt-get clean \ | ||
&& apt-get -y autoremove \ | ||
&& rm -rf \ | ||
/var/lib/apt/lists/* \ | ||
/tmp/* \ | ||
/var/tmp/* \ | ||
/usr/local/src/* | ||
&& rm -rf /var/cache/apk/* |