mirror of
https://gitlab.com/arm-research/smarter/smarter-device-manager.git
synced 2025-08-22 18:06:34 +00:00
Bitten by go 1.16 mod changes and k8s kubelet changes of api (1.20 or 0.20).
This commit is contained in:
@@ -5,11 +5,12 @@ RUN apk update && apk upgrade && apk add tar ca-certificates build-base
|
||||
ENV GOPATH /go
|
||||
RUN go version
|
||||
|
||||
WORKDIR /go/src/smarter-device-management
|
||||
WORKDIR /arm.com/smarter-device-management
|
||||
COPY . .
|
||||
|
||||
RUN echo $PATH;export CGO_LDFLAGS_ALLOW='-Wl,--unresolved-symbols=ignore-in-object-files' && \
|
||||
go install -ldflags="-s -w" -v smarter-device-management
|
||||
go mod init arm.com/smarter-device-management && go mod tidy && go mod vendor && \
|
||||
go build -ldflags="-s -w" .
|
||||
|
||||
FROM alpine
|
||||
|
||||
@@ -18,6 +19,6 @@ RUN apk update && apk upgrade
|
||||
WORKDIR /root
|
||||
|
||||
COPY conf.yaml /root/config/conf.yaml
|
||||
COPY --from=build /go/bin/smarter-device-management /usr/bin/smarter-device-management
|
||||
COPY --from=build /arm.com/smarter-device-management/smarter-device-management /usr/bin/smarter-device-management
|
||||
|
||||
CMD ["smarter-device-management","-logtostderr=true","-v=0"]
|
||||
CMD ["smarter-device-management","-logtostderr=true","-v=0"]
|
||||
|
Reference in New Issue
Block a user