Skip to content

Commit 9e7b8cb

Browse files
committed
docker: pass version and debug params
1 parent cf4fd49 commit 9e7b8cb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

build/Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ COPY web /tmp/web
33
WORKDIR /tmp/web
44
ARG APP_VERSION="1.0.0"
55
ARG GITHUB_URL="https://github.com/x1unix/go-playground"
6-
RUN REACT_APP_VERSION=${APP_VERSION} REACT_APP_GITHUB_URL=${GITHUB_URL} yarn install --silent && yarn build
6+
RUN yarn install --silent && REACT_APP_VERSION=$APP_VERSION REACT_APP_GITHUB_URL=$GITHUB_URL yarn build
77

88
FROM golang:1.13-alpine as build
99
WORKDIR /tmp/playground
@@ -17,8 +17,9 @@ FROM golang:1.13-alpine as production
1717
WORKDIR /opt/playground
1818
ENV GOROOT /usr/local/go
1919
ENV APP_CLEAN_INTERVAL=10m
20+
ENV APP_DEBUG=false
2021
COPY data ./data
2122
COPY --from=ui-build /tmp/web/build ./public
2223
COPY --from=build /tmp/playground/server .
2324
EXPOSE 8000
24-
ENTRYPOINT /opt/playground/server -f=/opt/playground/data/packages.json -addr=:8000 -clean-interval=${APP_CLEAN_INTERVAL}
25+
ENTRYPOINT /opt/playground/server -f=/opt/playground/data/packages.json -addr=:8000 -clean-interval=${APP_CLEAN_INTERVAL} -debug=${APP_DEBUG}

0 commit comments

Comments
 (0)