Skip to content

Commit

Permalink
Dockerfiles: use /app and make a volume out of /app/db
Browse files Browse the repository at this point in the history
  • Loading branch information
jessepeterson committed Aug 11, 2023
1 parent bc55bae commit 63c7c73
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
8 changes: 6 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,12 @@ FROM gcr.io/distroless/static

ARG TARGETOS TARGETARCH

COPY kmfddm-$TARGETOS-$TARGETARCH /usr/bin/kmfddm
COPY kmfddm-$TARGETOS-$TARGETARCH /app/kmfddm

EXPOSE 9002

ENTRYPOINT ["/usr/bin/kmfddm"]
VOLUME ["/app/db"]

WORKDIR /app

ENTRYPOINT ["/app/kmfddm"]
10 changes: 7 additions & 3 deletions Dockerfile.buildx
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,12 @@ FROM gcr.io/distroless/static

ARG TARGETOS TARGETARCH

COPY --from=builder /go/app/kmfddm-$TARGETOS-$TARGETARCH /usr/bin/kmfddm
COPY --from=builder /go/app/kmfddm-$TARGETOS-$TARGETARCH /app/kmfddm

EXPOSE 8080
EXPOSE 9002

ENTRYPOINT ["/usr/bin/kmfddm"]
VOLUME ["/app/db"]

WORKDIR /app

ENTRYPOINT ["/app/kmfddm"]

0 comments on commit 63c7c73

Please sign in to comment.