Skip to content

Instantly share code, notes, and snippets.

@JaniKibichi
Created June 30, 2021 08:52
Show Gist options
  • Save JaniKibichi/5be387ffab203b73d9eefe466df5adf5 to your computer and use it in GitHub Desktop.
Save JaniKibichi/5be387ffab203b73d9eefe466df5adf5 to your computer and use it in GitHub Desktop.
sbt native packager generated
FROM openjdk:8 as stage0
LABEL snp-multi-stage="intermediate"
LABEL snp-multi-stage-id="52ff43b3-42bb-43db-a05f-231396a6736c"
WORKDIR /opt/docker
COPY 1/opt /1/opt
COPY 2/opt /2/opt
USER root
RUN ["chmod", "-R", "u=rX,g=rX", "/1/opt/docker"]
RUN ["chmod", "-R", "u=rX,g=rX", "/2/opt/docker"]
RUN ["chmod", "u+x,g+x", "/1/opt/docker/bin/utility-ussd"]
FROM openjdk:8 as mainstage
USER root
RUN id -u demiourgos728 1>/dev/null 2>&1 || (( getent group 0 1>/dev/null 2>&1 || ( type groupadd 1>/dev/null 2>&1 && groupadd -g 0 root || addgroup -g 0 -S root )) && ( type useradd 1>/dev/null 2>&1 && useradd --system --create-home --uid 1001 --gid 0 demiourgos728 || adduser -S -u 1001 -G root demiourgos728 ))
WORKDIR /opt/docker
COPY --from=stage0 --chown=demiourgos728:root /1/opt/docker /opt/docker
COPY --from=stage0 --chown=demiourgos728:root /2/opt/docker /opt/docker
EXPOSE 7500
USER 1001:0
ENTRYPOINT ["/opt/docker/bin/utility-ussd"]
CMD []
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment