2024-10-19 14:36:33 +00:00
|
|
|
# Building Backend
|
2024-11-12 12:48:48 +00:00
|
|
|
FROM golang:alpine as nexus-server
|
2024-10-19 14:36:33 +00:00
|
|
|
|
|
|
|
WORKDIR /source
|
|
|
|
COPY . .
|
|
|
|
|
|
|
|
WORKDIR /source
|
|
|
|
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -buildvcs -o /dist ./pkg/main.go
|
|
|
|
|
|
|
|
# Runtime
|
|
|
|
FROM golang:alpine
|
|
|
|
|
2024-11-12 12:48:48 +00:00
|
|
|
COPY --from=nexus-server /dist /nexus/server
|
2024-10-19 14:36:33 +00:00
|
|
|
|
|
|
|
EXPOSE 8444
|
|
|
|
|
2024-11-12 12:48:48 +00:00
|
|
|
CMD ["/nexus/server"]
|