mirror of
https://github.com/halverneus/static-file-server.git
synced 2024-11-24 09:05:30 +00:00
Moved or removed EXPOSE in Dockerfiles.
This commit is contained in:
parent
f76f7f8f76
commit
a55be22716
@ -1,6 +1,8 @@
|
||||
################################################################################
|
||||
## GO BUILDER
|
||||
################################################################################
|
||||
FROM golang:1.11.3 as builder
|
||||
|
||||
EXPOSE 8080
|
||||
ENV VERSION 1.5.1
|
||||
ENV BUILD_DIR /build
|
||||
|
||||
@ -14,7 +16,12 @@ COPY . .
|
||||
RUN go test -cover ./...
|
||||
RUN CGO_ENABLED=0 go build -a -tags netgo -installsuffix netgo -ldflags "-X github.com/halverneus/static-file-server/cli/version.version=${VERSION}" -o /serve /build/bin/serve
|
||||
|
||||
################################################################################
|
||||
## DEPLOYMENT CONTAINER
|
||||
################################################################################
|
||||
FROM scratch
|
||||
|
||||
EXPOSE 8080
|
||||
COPY --from=builder /serve /
|
||||
ENTRYPOINT ["/serve"]
|
||||
CMD []
|
||||
|
@ -1,6 +1,5 @@
|
||||
FROM golang:1.11.3 as builder
|
||||
|
||||
EXPOSE 8080
|
||||
ENV VERSION 1.5.1
|
||||
ENV BUILD_DIR /build
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user