aboutsummaryrefslogtreecommitdiffhomepage
path: root/Dockerfile
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2019-07-27 12:34:30 +0200
committerArthurHoaro <arthur@hoa.ro>2019-07-27 12:34:30 +0200
commit38672ba0d1c722e5d6d33a58255ceb55e9410e46 (patch)
treedae4c7c47532380eac3ae641db99122fc77c93dc /Dockerfile
parent83faedadff76c5bdca036f39f13943f63b27e164 (diff)
parent1e77e0448bbd25675d8c0fe4a73206ad9048904b (diff)
downloadShaarli-38672ba0d1c722e5d6d33a58255ceb55e9410e46.tar.gz
Shaarli-38672ba0d1c722e5d6d33a58255ceb55e9410e46.tar.zst
Shaarli-38672ba0d1c722e5d6d33a58255ceb55e9410e46.zip
Merge tag 'v0.10.4' into stable
Release v0.10.4
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile16
1 files changed, 13 insertions, 3 deletions
diff --git a/Dockerfile b/Dockerfile
index 93146c52..d8921cee 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -5,7 +5,7 @@ FROM python:3-alpine as docs
5ADD . /usr/src/app/shaarli 5ADD . /usr/src/app/shaarli
6RUN cd /usr/src/app/shaarli \ 6RUN cd /usr/src/app/shaarli \
7 && pip install --no-cache-dir mkdocs \ 7 && pip install --no-cache-dir mkdocs \
8 && mkdocs build 8 && mkdocs build --clean
9 9
10# Stage 2: 10# Stage 2:
11# - Resolve PHP dependencies with Composer 11# - Resolve PHP dependencies with Composer
@@ -15,8 +15,17 @@ RUN cd shaarli \
15 && composer --prefer-dist --no-dev install 15 && composer --prefer-dist --no-dev install
16 16
17# Stage 3: 17# Stage 3:
18# - Frontend dependencies
19FROM node:9.9-alpine as node
20COPY --from=composer /app/shaarli shaarli
21RUN cd shaarli \
22 && yarn install \
23 && yarn run build \
24 && rm -rf node_modules
25
26# Stage 4:
18# - Shaarli image 27# - Shaarli image
19FROM alpine:3.6 28FROM alpine:3.8
20LABEL maintainer="Shaarli Community" 29LABEL maintainer="Shaarli Community"
21 30
22RUN apk --update --no-cache add \ 31RUN apk --update --no-cache add \
@@ -47,12 +56,13 @@ RUN rm -rf /etc/php7/php-fpm.d/www.conf \
47 56
48 57
49WORKDIR /var/www 58WORKDIR /var/www
50COPY --from=composer /app/shaarli shaarli 59COPY --from=node /shaarli shaarli
51 60
52RUN chown -R nginx:nginx . \ 61RUN chown -R nginx:nginx . \
53 && ln -sf /dev/stdout /var/log/nginx/shaarli.access.log \ 62 && ln -sf /dev/stdout /var/log/nginx/shaarli.access.log \
54 && ln -sf /dev/stderr /var/log/nginx/shaarli.error.log 63 && ln -sf /dev/stderr /var/log/nginx/shaarli.error.log
55 64
65VOLUME /var/www/shaarli/cache
56VOLUME /var/www/shaarli/data 66VOLUME /var/www/shaarli/data
57 67
58EXPOSE 80 68EXPOSE 80