|
@ -1,14 +1,14 @@ |
|
|
# ==================== |
|
|
# ==================== |
|
|
# --- Build Assets --- |
|
|
# --- Build Assets --- |
|
|
# ==================== |
|
|
# ==================== |
|
|
FROM node:10.14-alpine AS assets |
|
|
|
|
|
|
|
|
FROM node:10.15-alpine AS assets |
|
|
|
|
|
|
|
|
RUN apk update && \ |
|
|
RUN apk update && \ |
|
|
apk add yarn g++ make python --no-cache && \ |
|
|
apk add yarn g++ make python --no-cache && \ |
|
|
rm -rf /var/cache/apk/* && \ |
|
|
rm -rf /var/cache/apk/* && \ |
|
|
mkdir -p /var/wiki |
|
|
|
|
|
|
|
|
mkdir -p /wiki |
|
|
|
|
|
|
|
|
WORKDIR /var/wiki |
|
|
|
|
|
|
|
|
WORKDIR /wiki |
|
|
|
|
|
|
|
|
COPY ./client ./client |
|
|
COPY ./client ./client |
|
|
COPY ./dev ./dev |
|
|
COPY ./dev ./dev |
|
@ -19,28 +19,28 @@ COPY ./.eslintrc.yml ./.eslintrc.yml |
|
|
|
|
|
|
|
|
RUN yarn --cache-folder /codefresh/volume/yarn |
|
|
RUN yarn --cache-folder /codefresh/volume/yarn |
|
|
RUN yarn build |
|
|
RUN yarn build |
|
|
RUN rm -rf /var/wiki/node_modules |
|
|
|
|
|
|
|
|
RUN rm -rf /wiki/node_modules |
|
|
RUN yarn --production |
|
|
RUN yarn --production |
|
|
|
|
|
|
|
|
# =============== |
|
|
# =============== |
|
|
# --- Release --- |
|
|
# --- Release --- |
|
|
# =============== |
|
|
# =============== |
|
|
FROM node:10.14-alpine |
|
|
|
|
|
|
|
|
FROM node:10.15-alpine |
|
|
LABEL maintainer="requarks.io" |
|
|
LABEL maintainer="requarks.io" |
|
|
|
|
|
|
|
|
RUN apk update && \ |
|
|
RUN apk update && \ |
|
|
apk add bash curl git openssh supervisor --no-cache && \ |
|
|
apk add bash curl git openssh supervisor --no-cache && \ |
|
|
rm -rf /var/cache/apk/* && \ |
|
|
rm -rf /var/cache/apk/* && \ |
|
|
mkdir -p /var/wiki && \ |
|
|
|
|
|
|
|
|
mkdir -p /wiki && \ |
|
|
mkdir -p /logs |
|
|
mkdir -p /logs |
|
|
|
|
|
|
|
|
WORKDIR /var/wiki |
|
|
|
|
|
|
|
|
WORKDIR /wiki |
|
|
|
|
|
|
|
|
COPY ./dev/build/supervisord.conf /etc/supervisord.conf |
|
|
COPY ./dev/build/supervisord.conf /etc/supervisord.conf |
|
|
COPY --from=assets /var/wiki/assets ./assets |
|
|
|
|
|
COPY --from=assets /var/wiki/node_modules ./node_modules |
|
|
|
|
|
|
|
|
COPY --from=assets /wiki/assets ./assets |
|
|
|
|
|
COPY --from=assets /wiki/node_modules ./node_modules |
|
|
COPY ./server ./server |
|
|
COPY ./server ./server |
|
|
COPY --from=assets /var/wiki/server/views ./server/views |
|
|
|
|
|
|
|
|
COPY --from=assets /wiki/server/views ./server/views |
|
|
COPY ./dev/build/config.yml ./config.yml |
|
|
COPY ./dev/build/config.yml ./config.yml |
|
|
COPY ./dev/docker/wait.sh ./wait.sh |
|
|
COPY ./dev/docker/wait.sh ./wait.sh |
|
|
COPY ./package.json ./package.json |
|
|
COPY ./package.json ./package.json |
|
@ -48,4 +48,4 @@ COPY ./LICENSE ./LICENSE |
|
|
|
|
|
|
|
|
EXPOSE 3000 |
|
|
EXPOSE 3000 |
|
|
|
|
|
|
|
|
CMD ["supervisord", "--nodaemon", "-c", "/etc/supervisord.conf"] |
|
|
|
|
|
|
|
|
CMD ["node", "server"] |