-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #100 from jdel/fix/container
Fix version of alpine and upgrade php and composer
- Loading branch information
Showing
2 changed files
with
11 additions
and
10 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,4 +1,4 @@ | ||
FROM alpine:edge | ||
FROM alpine:3.17 | ||
LABEL maintainer="Julien Del-Piccolo <[email protected]>" | ||
LABEL branch=${BRANCH} | ||
LABEL commit=${COMMIT} | ||
|
@@ -7,19 +7,20 @@ USER root | |
|
||
COPY . /var/www/localhost/htdocs/ | ||
|
||
RUN apk update && apk add --no-cache ca-certificates curl apache2 php8-apache2 php8-phar php8-ctype php8-json \ | ||
&& apk add --virtual=.build-dependencies openssl php8 php8-openssl php8-iconv php8-mbstring git \ | ||
RUN apk update && apk add --no-cache ca-certificates curl apache2 php81-apache2 php81-phar php81-ctype php81-json \ | ||
&& apk add --virtual=.build-dependencies openssl php81 php81-openssl php81-iconv php81-mbstring git \ | ||
&& ln -sf /usr/bin/php81 /usr/local/bin/php \ | ||
&& rm -f /var/www/localhost/htdocs/index.html \ | ||
&& curl -sSL https://getcomposer.org/download/2.2.6/composer.phar -o /usr/local/bin/composer \ | ||
&& curl -sSL https://getcomposer.org/download/2.5.1/composer.phar -o /usr/local/bin/composer \ | ||
&& chmod +x /usr/local/bin/composer \ | ||
&& cd /var/www/localhost/htdocs \ | ||
&& composer install --no-dev \ | ||
; rm -f /usr/local/bin/composer \ | ||
&& rm -f /usr/local/bin/composer \ | ||
&& apk del .build-dependencies \ | ||
&& rm -rf /var/cache/apk/* \ | ||
&& mkdir -p /run/apache2 \ | ||
&& sed -i 's/Listen 80/Listen 8080/' /etc/apache2/httpd.conf \ | ||
&& sed -i 's/^variables_order = "GPCS"/variables_order = "EGPCS"/' /etc/php8/php.ini \ | ||
&& sed -i 's/^variables_order = "GPCS"/variables_order = "EGPCS"/' /etc/php81/php.ini \ | ||
&& ln -sf /dev/stdout /var/log/apache2/access.log \ | ||
&& ln -sf /dev/stderr /var/log/apache2/error.log \ | ||
&& ln -sf /var/www/localhost/htdocs/packages /packages \ | ||
|