From 4b9a850c1e6415144c8d5882fa00dfb1cb845d4f Mon Sep 17 00:00:00 2001 From: peterxcli Date: Sun, 18 Feb 2024 16:49:30 +0800 Subject: [PATCH] feat: update Dockerfile to specify the main binary path --- Dockerfile_Backend | 6 +++--- Dockerfile_Notifier | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Dockerfile_Backend b/Dockerfile_Backend index 972895b..ef8619a 100644 --- a/Dockerfile_Backend +++ b/Dockerfile_Backend @@ -21,7 +21,7 @@ FROM alpine:latest AS runtime RUN apk --no-cache add ca-certificates # Copy the binary from the build stage to the runtime stage -COPY --from=build /app/main /app - +COPY --from=build /app/main /app/main +WORKDIR /app # Set the entry point to execute the binary directly -ENTRYPOINT ["/app"] +ENTRYPOINT /app/main diff --git a/Dockerfile_Notifier b/Dockerfile_Notifier index 18c1323..92e1dcf 100644 --- a/Dockerfile_Notifier +++ b/Dockerfile_Notifier @@ -21,7 +21,7 @@ FROM alpine:latest AS runtime RUN apk --no-cache add ca-certificates # Copy the binary from the build stage to the runtime stage -COPY --from=build /app/main /app - +COPY --from=build /app/main /app/main +WORKDIR /app # Set the entry point to execute the binary directly -ENTRYPOINT ["/app"] +ENTRYPOINT /app/main