golang.org/x/build@v0.0.0-20240506185731-218518f32b70/cmd/watchflakes/Dockerfile (about) 1 # Copyright 2024 The Go Authors. All rights reserved. 2 # Use of this source code is governed by a BSD-style 3 # license that can be found in the LICENSE file. 4 5 FROM golang:1.22-bookworm AS build 6 LABEL maintainer="golang-dev@googlegroups.com" 7 8 COPY go.mod /go/src/golang.org/x/build/go.mod 9 COPY go.sum /go/src/golang.org/x/build/go.sum 10 11 WORKDIR /go/src/golang.org/x/build 12 13 # Download module dependencies to improve speed of re-building the 14 # Docker image during minor code changes. 15 RUN go mod download 16 17 COPY . /go/src/golang.org/x/build/ 18 19 RUN go install golang.org/x/build/cmd/watchflakes 20 21 FROM debian:bookworm 22 LABEL maintainer="golang-dev@googlegroups.com" 23 24 # netbase and ca-certificates are needed for dialing TLS. 25 # The rest are useful for debugging if somebody needs to exec into the container. 26 RUN apt-get update && apt-get install -y \ 27 --no-install-recommends \ 28 netbase \ 29 ca-certificates \ 30 curl \ 31 strace \ 32 procps \ 33 lsof \ 34 psmisc \ 35 && rm -rf /var/lib/apt/lists/* 36 37 COPY --from=build /go/bin/watchflakes / 38 ENTRYPOINT ["/watchflakes"]