mirror of
https://github.com/mainflux/mainflux.git
synced 2025-05-01 13:48:56 +08:00
9 lines
294 B
Docker
9 lines
294 B
Docker
![]() |
FROM golang:1.8-alpine AS builder
|
||
|
WORKDIR /go/src/github.com/mainflux/mainflux
|
||
|
COPY . .
|
||
|
RUN cd cmd/writer && CGO_ENABLED=0 GOOS=linux go build -ldflags "-s" -a -installsuffix cgo -o exe
|
||
|
|
||
|
FROM scratch
|
||
|
COPY --from=builder /go/src/github.com/mainflux/mainflux/cmd/writer/exe /
|
||
|
ENTRYPOINT ["/exe"]
|