parent
e87932e375
commit
1e228ed338
10 changed files with 105 additions and 34 deletions
14
Dockerfile
14
Dockerfile
|
@ -1,4 +1,10 @@
|
|||
FROM docker.io/nginx:latest
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
COPY html/ /usr/share/nginx/html/
|
||||
COPY static/ /usr/share/nginx/static/
|
||||
FROM docker.io/golang:1.23 as build
|
||||
COPY src/ .
|
||||
RUN printf 'module yw5n\ngo 1.23' > go.mod && CGO_ENABLED=0 go build -o /app
|
||||
|
||||
FROM scratch
|
||||
COPY --from=build /app /app
|
||||
COPY static/ /static/
|
||||
COPY html/ /html/
|
||||
EXPOSE 3000
|
||||
CMD ["/app"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue