fix build with using golang:latest
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from golang as builder
|
||||
FROM golang:1.16.0-buster as builder
|
||||
|
||||
RUN mkdir /app
|
||||
WORKDIR /app
|
||||
@@ -6,6 +6,12 @@ RUN go get github.com/docker/docker/api/types github.com/docker/docker/api/types
|
||||
|
||||
COPY orborus.go /app/orborus.go
|
||||
RUN go mod init orborus
|
||||
RUN go get github.com/docker/docker/api/types && \
|
||||
go get github.com/docker/docker/api/types/container && \
|
||||
go get github.com/docker/docker/client && \
|
||||
go get github.com/mackerelio/go-osstat/cpu && \
|
||||
go get github.com/mackerelio/go-osstat/memory && \
|
||||
go get github.com/satori/go.uuid
|
||||
RUN go build
|
||||
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o orborus .
|
||||
|
||||
|
||||
Reference in New Issue
Block a user