You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
456 B
Docker
18 lines
456 B
Docker
2 years ago
|
FROM node:18 AS frontend-builder
|
||
|
WORKDIR /frontend
|
||
|
COPY ./_frontend .
|
||
|
RUN npm install
|
||
|
RUN npm run build
|
||
|
|
||
|
FROM golang:1.18-alpine AS server-builder
|
||
|
WORKDIR /server
|
||
|
COPY . .
|
||
|
RUN go build -buildvcs=false -o storage-server -v .
|
||
|
|
||
|
FROM alpine:latest AS runner
|
||
|
WORKDIR /app
|
||
|
COPY --from=frontend-builder /frontend/dist ./_frontend/dist
|
||
|
COPY ./scripts ./scripts
|
||
|
COPY --from=server-builder /server/storage-server ./storage-server
|
||
|
EXPOSE 4000
|
||
|
CMD ["./storage-server"]
|