站点更新:2018-07-06 15:11:14
This commit is contained in:
parent
570c261d3c
commit
63d2a1d728
@ -1,14 +1,18 @@
|
||||
FROM alpine:latest
|
||||
LABEL maintainer="ehlxr.me@gmail.com"
|
||||
|
||||
ENV TZ "Asia/Shanghai"
|
||||
|
||||
WORKDIR /app
|
||||
VOLUME /data
|
||||
|
||||
RUN apk add --update --no-cache mysql mysql-client \
|
||||
&& rm -f /var/cache/apk/*
|
||||
RUN apk add --update --no-cache mysql mysql-client tzdata \
|
||||
&& ln -sf /usr/share/zoneinfo/${TZ} /etc/localtime \
|
||||
&& echo ${TZ} > /etc/timezone \
|
||||
&& rm -rf /var/cache/apk/*
|
||||
|
||||
COPY my.cnf /etc/mysql/my.cnf
|
||||
COPY startup.sh /startup.sh
|
||||
|
||||
EXPOSE 3306
|
||||
CMD ["/startup.sh"]
|
||||
CMD ["/startup.sh"]
|
@ -9,6 +9,12 @@ RUN hexo generate && gulp
|
||||
|
||||
FROM nginx:alpine
|
||||
LABEL maintainer="ehlxr.me@gmail.com"
|
||||
ENV TZ "Asia/Shanghai"
|
||||
WORKDIR /usr/share/nginx/html
|
||||
COPY --from=0 /hexo/public .
|
||||
RUN apk upgrade --update \
|
||||
&& apk add tzdata \
|
||||
&& ln -sf /usr/share/zoneinfo/${TZ} /etc/localtime \
|
||||
&& echo ${TZ} > /etc/timezone \
|
||||
&& rm -rf /var/cache/apk/*
|
||||
ENTRYPOINT ["nginx", "-g", "daemon off;"]
|
Loading…
Reference in New Issue
Block a user