-
Notifications
You must be signed in to change notification settings - Fork 12
/
Dockerfile
51 lines (48 loc) · 1.13 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
FROM php:7.3-alpine3.15
ENV COMPOSER_ALLOW_SUPERUSER 1
ENV COMPOSER_HOME /tmp
ENV COMPOSER_VERSION 2.2.23
RUN set -eux ; \
apk add --no-cache --virtual .composer-rundeps \
bash \
coreutils \
git \
make \
openssh-client \
patch \
subversion \
tini \
bzip2 \
bzip2-dev \
zlib \
zlib-dev \
libzip \
libzip-dev \
unzip \
zip
RUN set -eux ; \
# install necessary/useful extensions not included in base image
docker-php-ext-install \
bz2 \
zip \
; \
# download installer.php, see https://getcomposer.org/download/
curl \
--silent \
--fail \
--location \
--retry 3 \
--output /tmp/installer.php \
--url https://raw.githubusercontent.com/composer/getcomposer.org/f24b8f860b95b52167f91bbd3e3a7bcafe043038/web/installer \
; \
# install composer phar binary
php /tmp/installer.php \
--no-ansi \
--install-dir=/usr/bin \
--filename=composer \
--version=${COMPOSER_VERSION} \
; \
composer --ansi --version --no-interaction ; \
composer diagnose ; \
rm -f /tmp/installer.php ; \
find /tmp -type d -exec chmod -v 1777 {} + \