mirror of
https://github.com/yeasy/docker_practice.git
synced 2024-11-01 04:03:39 +00:00
48a3624644
Fix #216 #218
27 lines
444 B
Docker
27 lines
444 B
Docker
FROM node:9-alpine
|
|
|
|
ENV TZ=Asia/Shanghai
|
|
|
|
WORKDIR /srv/gitbook
|
|
|
|
COPY book.json book.json
|
|
|
|
COPY docker-entrypoint.sh /usr/local/bin/
|
|
|
|
RUN apk add --no-cache \
|
|
tzdata \
|
|
&& npm install -g gitbook-cli \
|
|
&& gitbook install \
|
|
&& ln -s /usr/local/bin/docker-entrypoint.sh / \
|
|
&& rm -rf /root/.npm /tmp/*
|
|
|
|
EXPOSE 4000
|
|
|
|
VOLUME /srv/gitbook-src
|
|
|
|
WORKDIR /srv/gitbook-src
|
|
|
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
|
|
|
CMD server
|