-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
39 lines (29 loc) · 928 Bytes
/
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
FROM php:5.6.30-alpine
MAINTAINER herloct <herloct@gmail.com>
ENV COMPOSER_VERSION=1.4.2 \
COMPOSER_HOME=/composer \
PATH=$COMPOSER_HOME/vendor/bin:$PATH
COPY install-composer.sh /usr/local/bin/install-composer.sh
RUN apk update --no-cache \
&& apk add --no-cache \
curl \
git \
mercurial \
openssh \
openssl \
subversion \
&& mkdir -p $COMPOSER_HOME \
&& ( \
cd /tmp \
&& install-composer.sh \
&& rm /usr/local/bin/install-composer.sh \
) \
&& export COMPOSER_ALLOW_SUPERUSER=1 \
&& composer global require -a --prefer-dist "hirak/prestissimo:^0.3" \
&& export COMPOSER_ALLOW_SUPERUSER=0 \
&& chmod -R 0777 $COMPOSER_HOME/cache \
&& rm -rf /var/cache/apk/* /var/tmp/* /tmp/* $COMPOSER_HOME/cache/*
VOLUME ["/project", "$COMPOSER_HOME/cache"]
WORKDIR /project
ENTRYPOINT ["composer"]
CMD ["--version"]