docker fix
Some checks failed
build and deploy kleinTodo / build (push) Failing after 5s

This commit is contained in:
Darius klein 2025-08-23 19:28:39 +02:00
parent 69785d74a8
commit 0de80ee1bf

View File

@ -4,19 +4,19 @@ FROM golang:latest as build
# Set the working directory to /app # Set the working directory to /app
WORKDIR /app WORKDIR /app
# Copy the current directory contents into the container at /app # Copy the current directory contents into the container at /app
COPY go.mod . COPY server/go.mod .
COPY go.sum . COPY server/go.sum .
# Download and install any required dependencies # Download and install any required dependencies
RUN go mod download RUN go mod download
COPY .. . COPY .. .
# Build the Go app # Build the Go app
RUN go build . RUN go build -o serverBinary ./server/
FROM gcr.io/distroless/base-debian12 FROM gcr.io/distroless/base-debian12
COPY --from=build /app/kleinTodo . COPY --from=build /app/serverBinary .
# Define the command to run the app when the container starts # Define the command to run the app when the container starts
CMD ["./kleinTodo"] CMD ["./serverBinary"]