cadvisor-multi-arch/Dockerfile
Ian Fijolek 48af0c7e18
Some checks reported errors
continuous-integration/drone/push Build was killed
continuous-integration/drone/tag Build is passing
Add healthcheck
2020-07-14 16:54:10 -07:00

18 lines
538 B
Docker

ARG REPO=library
FROM multiarch/qemu-user-static:4.2.0-2 as qemu-user-static
FROM ${REPO}/alpine:3.10
# Copying all qemu files because amd64 doesn't exist and cannot condional copy
COPY --from=qemu-user-static /usr/bin/qemu-* /usr/bin/
ARG GOARCH=amd64
COPY ./cadvisor-${GOARCH} /usr/bin/cadvisor
ENV CADVISOR_HEALTHCHECK_URL=http://localhost:8080/healthz
HEALTHCHECK --interval=30s --timeout=3s \
CMD wget --quiet --tries=1 --spider $CADVISOR_HEALTHCHECK_URL || exit 1
EXPOSE 8080
ENTRYPOINT ["/usr/bin/cadvisor", "-logtostderr"]