diff --git a/Dockerfile b/Dockerfile index 2a05fc76200ac35c9fb740cff5ada1fcbee33fd5..5275b0122bf2a33a5797ad0368ead04ef122592f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,23 +19,21 @@ RUN go env | grep GOINSECURE RUN go env -w GOINSECURE=github.com && go mod download # Copy the source code into the container -COPY ./cmd/migrate ./ +COPY . /app # Build the Go app -# RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o main ./main.go -RUN GOOS=linux GOARCH=arm64 go build -o main ./main.go +RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o main ./main.go -# Uncomment the following line to compile an image for arm64 arch -# RUN GOOS=linux GOARCH=arm64 go build -o main ./main.go +#Uncomment the following line to compile an image for arm64 arch +#RUN GOOS=linux GOARCH=arm64 go build -o main ./intent-based-migration.go # Stage 2: Create the final image FROM alpine:latest -# Set the working directory inside the final image WORKDIR /root # Copy the pre-built binary from the builder stage COPY --from=builder /app/main . # Command to run the executable -CMD ["./main"] +CMD ["./main"] \ No newline at end of file