github.com/docker/app@v0.9.1-beta3.0.20210611140623-a48f773ab002/docs/yaml/Dockerfile (about) 1 FROM golang:1.13-alpine AS base 2 3 ARG PROJECT=github.com/docker/app 4 ARG PROJECT_PATH=/go/src/${PROJECT} 5 ENV CGO_ENABLED=0 6 ENV PATH=${PATH}:${PROJECT_PATH}/build 7 WORKDIR $PROJECT_PATH 8 9 RUN mkdir -p docs/yaml/gen 10 11 COPY . . 12 RUN go build -o build/yaml-docs-generator ${PROJECT}/docs/yaml 13 RUN build/yaml-docs-generator \ 14 --root "${PROJECT_PATH}" \ 15 --target "${PROJECT_PATH}/docs/yaml/gen" 16 17 18 FROM scratch 19 ARG PROJECT=github.com/docker/app 20 ARG PROJECT_PATH=/go/src/${PROJECT} 21 # CMD cannot be nil so we set it to empty string 22 CMD [""] 23 COPY --from=base ${PROJECT_PATH}/docs/reference /docs/reference 24 COPY --from=base ${PROJECT_PATH}/docs/yaml/gen /docs/yaml