Rearranging
This commit is contained in:
parent
a1760b1ee6
commit
08a5a4d8d6
@ -10,6 +10,18 @@ ARG SITE_PACKAGES_DIR=/usr/local/lib/python3.6/site-packages
|
|||||||
ENV APP_DIR "${APP_DIR}"
|
ENV APP_DIR "${APP_DIR}"
|
||||||
ENV SKIP_PIPENV true
|
ENV SKIP_PIPENV true
|
||||||
|
|
||||||
|
# Set port to open
|
||||||
|
EXPOSE "${APP_PORT}"
|
||||||
|
|
||||||
|
# Run as the unprivileged APP user
|
||||||
|
USER "${APP_USER}"
|
||||||
|
|
||||||
|
# Use dumb-init for proper signal handling
|
||||||
|
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
||||||
|
|
||||||
|
# Default command is to launch the server
|
||||||
|
CMD ["bash", "-c", "${APP_DIR}/script/server"]
|
||||||
|
|
||||||
# Copy installed python packages from the tester image
|
# Copy installed python packages from the tester image
|
||||||
COPY --from=atst-tester:latest "${SITE_PACKAGES_DIR}" "${SITE_PACKAGES_DIR}"
|
COPY --from=atst-tester:latest "${SITE_PACKAGES_DIR}" "${SITE_PACKAGES_DIR}"
|
||||||
|
|
||||||
@ -26,15 +38,3 @@ RUN set -x ; \
|
|||||||
# Update file ownership
|
# Update file ownership
|
||||||
RUN set -x ; \
|
RUN set -x ; \
|
||||||
chown -R atst:atat "${APP_DIR}"
|
chown -R atst:atat "${APP_DIR}"
|
||||||
|
|
||||||
# Set port to open
|
|
||||||
EXPOSE "${APP_PORT}"
|
|
||||||
|
|
||||||
# Run as the unprivileged APP user
|
|
||||||
USER "${APP_USER}"
|
|
||||||
|
|
||||||
# Use dumb-init for proper signal handling
|
|
||||||
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
|
||||||
|
|
||||||
# Default command is to launch the server
|
|
||||||
CMD ["bash", "-c", "${APP_DIR}/script/server"]
|
|
||||||
|
@ -7,6 +7,12 @@ ARG CIBUILD=true
|
|||||||
|
|
||||||
ENV SKIP_PIPENV true
|
ENV SKIP_PIPENV true
|
||||||
|
|
||||||
|
# Use dumb-init for proper signal handling
|
||||||
|
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
||||||
|
|
||||||
|
# Default command is to run all the tests
|
||||||
|
CMD ["${APP_DIR}/script/cibuild"]
|
||||||
|
|
||||||
# Create application directory
|
# Create application directory
|
||||||
RUN set -x ; \
|
RUN set -x ; \
|
||||||
mkdir -p ${APP_DIR}
|
mkdir -p ${APP_DIR}
|
||||||
@ -25,8 +31,3 @@ RUN set -x ; \
|
|||||||
RUN set -x ; \
|
RUN set -x ; \
|
||||||
script/setup
|
script/setup
|
||||||
|
|
||||||
# Use dumb-init for proper signal handling
|
|
||||||
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
|
||||||
|
|
||||||
# Default command is to run all the tests
|
|
||||||
CMD ["${APP_DIR}/script/cibuild"]
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user