Liz Rice f62309f388 Add healthcheck to DockerHubStats sample function
Signed-off-by: Liz Rice <liz@lizrice.com>
2017-11-09 10:41:10 +00:00

18 lines
494 B
Docker

FROM golang:1.7.5-alpine
MAINTAINER alexellis2@gmail.com
ENTRYPOINT []
RUN apk --no-cache add make
WORKDIR /go/src/github.com/openfaas/faas/sample-functions/DockerHubStats
COPY . /go/src/github.com/openfaas/faas/sample-functions/DockerHubStats
RUN make
ADD https://github.com/openfaas/faas/releases/download/0.6.0/fwatchdog /usr/bin
RUN chmod +x /usr/bin/fwatchdog
ENV fprocess "/go/bin/DockerHubStats"
HEALTHCHECK --interval=5s CMD [ -e /tmp/.lock ] || exit 1
CMD [ "/usr/bin/fwatchdog"]