[#666] Add Docker images for neofs-adm

Signed-off-by: Stanislav Bogatyrev <stanislav@nspcc.ru>
remotes/fyrchik/meta-pebble
Stanislav Bogatyrev 2021-07-09 13:40:18 +03:00 committed by Stanislav Bogatyrev
parent cf8f640726
commit 45cd851c46
4 changed files with 34 additions and 2 deletions

22
Dockerfile.adm 100644
View File

@ -0,0 +1,22 @@
FROM golang:1.16-alpine as basebuilder
RUN apk add --update make bash
FROM basebuilder as builder
ARG BUILD=now
ARG VERSION=dev
ARG REPO=repository
WORKDIR /src
COPY . /src
RUN make bin/neofs-adm
# Executable image
FROM alpine AS neofs-adm
RUN apk add --no-cache bash
WORKDIR /
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /src/bin/neofs-adm /bin/neofs-adm
CMD ["neofs-adm"]

View File

@ -5,6 +5,7 @@ ARG HUB_TAG=latest
FROM ${HUB_IMAGE}-cli:${HUB_TAG} as neofs-cli
FROM ${HUB_IMAGE}-ir:${HUB_TAG} as neofs-ir
FROM ${HUB_IMAGE}-storage:${HUB_TAG} as neofs-storage
FROM ${HUB_IMAGE}-adm:${HUB_TAG} as neofs-adm
# Executable image
FROM alpine AS neofs-aio
@ -20,5 +21,6 @@ WORKDIR /
COPY --from=neofs-cli /bin/neofs-cli /bin/neofs-cli
COPY --from=neofs-ir /bin/neofs-ir /bin/neofs-ir
COPY --from=neofs-storage /bin/neofs-node /bin/neofs-node
COPY --from=neofs-adm /bin/neofs-adm /bin/neofs-adm
CMD ["neofs-cli"]

View File

@ -0,0 +1,8 @@
FROM alpine
RUN apk add --no-cache bash ca-certificates
WORKDIR /
COPY bin/neofs-adm /bin/neofs-adm
CMD ["neofs-adm"]

View File

@ -83,10 +83,10 @@ image-%:
-t $(HUB_IMAGE)-$*:$(HUB_TAG) .
# Build all Docker images
images: image-storage image-ir image-cli
images: image-storage image-ir image-cli image-adm
# Build dirty local Docker images
dirty-images: image-dirty-storage image-dirty-ir image-dirty-cli
dirty-images: image-dirty-storage image-dirty-ir image-dirty-cli image-dirty-adm
# Run all code formatters
fmts: fmt imports