github.com/hellofresh/janus@v0.0.0-20230925145208-ce8de8183c67/Dockerfile.dev (about) 1 # run this from the root of janus 2 FROM golang:1.14-alpine AS build-debug-common 3 4 ARG VERSION='0.0.1-docker' 5 6 WORKDIR /janus 7 8 COPY . ./ 9 10 # Add tooling to install GCC 11 RUN apk add build-base 12 # Add cqlsh to the image. 13 RUN apk add --update \ 14 bash \ 15 curl \ 16 py-pip 17 RUN go get github.com/go-delve/delve/cmd/dlv@v1.6.0 18 19 RUN apk add --update bash make git 20 RUN export JANUS_BUILD_ONLY_DEFAULT=1 && \ 21 export VERSION=$VERSION && \ 22 make build 23 24 # --- 25 26 FROM alpine 27 28 COPY --from=build-debug-common /janus/dist/janus / 29 30 RUN apk add --no-cache ca-certificates 31 RUN mkdir -p /etc/janus/apis && \ 32 mkdir -p /etc/janus/auth 33 34 RUN apk add --update curl && \ 35 rm -rf /var/cache/apk/* 36 37 HEALTHCHECK --interval=5s --timeout=5s --retries=3 CMD curl -f http://localhost:8081/status || exit 1 38 39 FROM build-debug-common as dev 40 EXPOSE 8080 8081 8443 8444 40000 41 COPY entry-dev.sh /usr/local/bin 42 COPY cassandra/schema.sql /usr/local/bin 43 RUN chmod 755 /usr/local/bin/entry-dev.sh 44 ENTRYPOINT ["/usr/local/bin/entry-dev.sh"] 45 #ENTRYPOINT ["/janus", "start"]