some fixes for docker and migrations

This commit is contained in:
2025-10-31 00:17:48 +01:00
parent 84ec54a893
commit 8d908a0502
13 changed files with 202 additions and 26 deletions
+9 -6
View File
@@ -2,10 +2,13 @@ FROM golang:1.25.2-alpine3.22 AS builder
WORKDIR /app
COPY go.mod go.sum ./
COPY server/ ./server/
COPY internal/ ./internal/
COPY assets/ ./assets/
COPY pkg/ ./pkg/
COPY service_a/go.mod service_a/go.sum ./service_a/
COPY service_a/server/ ./service_a/server/
COPY service_a/internal/ ./service_a/internal/
COPY service_a/assets/ ./service_a/assets/
WORKDIR /app/service_a
RUN go mod download
@@ -13,13 +16,13 @@ RUN go test ./... -v
RUN rm -rf ./assets/
RUN go build -o /app/service_a ./server/main.go
RUN go build -o /app/bin/service_a ./server/main.go
FROM alpine:latest
WORKDIR /app
COPY --from=builder /app/service_a /app/service_a
COPY --from=builder /app/bin/service_a /app/service_a
EXPOSE 8080