forked from MilesChou/composer-action
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.template
39 lines (30 loc) · 917 Bytes
/
Dockerfile.template
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
FROM php:%%PHP_VERSION%%
LABEL repository="https://github.com/MilesChou/composer-action" \
maintainer="MilesChou <jangconan@gmail.com>"
RUN set -xe && \
apk add --no-cache \
libzip \
&& \
apk add --no-cache --virtual .build-deps \
libzip-dev \
zlib-dev \
&& \
docker-php-ext-install -j "$(getconf _NPROCESSORS_ONLN)" \
zip \
&& \
apk del --no-cache .build-deps \
&& \
php -m
ENV COMPOSER_ALLOW_SUPERUSER=1 \
COMPOSER_MEMORY_LIMIT=-1 \
COMPOSER_HOME=/tmp \
COMPOSER_PATH=/usr/local/bin/composer \
COMPOSER_VERSION=1.9.1
COPY --from=composer:1.9.1 /usr/bin/composer /usr/local/bin/composer
RUN set -xe && \
composer global require hirak/prestissimo && \
composer clear-cache
COPY docker-entrypoint /usr/local/bin/docker-entrypoint
WORKDIR /app
ENTRYPOINT ["/usr/local/bin/docker-entrypoint"]
CMD ["--info"]