Skip to content

Commit

Permalink
Merge pull request #28 from txsvc/develop
Browse files Browse the repository at this point in the history
added a VOLUME to the Dockerfile
  • Loading branch information
mickume authored Jan 4, 2023
2 parents b35bfa4 + 711ae70 commit fe0530c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions examples/service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,16 @@ FROM registry.access.redhat.com/ubi8-minimal
ENV SVC_NAME svc

ENV APP_ROOT=/opt/app-root \
DATA_ROOT=/opt/data \
HOME=/opt/app-root/src \
PATH=/opt/app-root/src/bin:/opt/app-root/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

USER root

VOLUME ${DATA_ROOT}
RUN mkdir -p ${DATA_ROOT} && \
chown -R 1001:0 ${DATA_ROOT}

RUN mkdir -p ${HOME}/bin && \
chown -R 1001:0 ${APP_ROOT}

Expand All @@ -16,8 +21,6 @@ COPY $SVC_NAME ${HOME}/bin/svc
RUN chown -R 1001:0 ${APP_ROOT} && \
chmod -R ug+rwx ${APP_ROOT}

VOLUME ${HOME}

WORKDIR ${HOME}
EXPOSE 8080

Expand Down

0 comments on commit fe0530c

Please sign in to comment.