minify/Dockerfile

17 lines
319 B
Docker
Raw Normal View History

2022-04-28 00:52:28 +00:00
FROM node:lts-alpine AS frontend-builder
2022-04-28 00:48:21 +00:00
2022-04-28 00:50:50 +00:00
ADD . .
2022-04-28 00:48:21 +00:00
RUN cd frontend && npm install && npm run build
FROM golang:alpine AS builder
2022-04-28 00:52:28 +00:00
ADD . /app
COPY --from=frontend-builder frontend/dist /app/frontend/dist
2022-04-28 00:48:21 +00:00
2022-04-28 00:52:28 +00:00
RUN cd /app && go build -o minify
2022-04-28 00:48:21 +00:00
FROM alpine
COPY --from=builder minify /usr/bin/minify
CMD ["/usr/bin/minify"]