diff --git a/dev-tools/kubernetes/filebeat/Dockerfile.debug b/dev-tools/kubernetes/filebeat/Dockerfile.debug index 661ac535c40..96458cbffbe 100644 --- a/dev-tools/kubernetes/filebeat/Dockerfile.debug +++ b/dev-tools/kubernetes/filebeat/Dockerfile.debug @@ -1,4 +1,4 @@ -FROM golang:alpine3.15 as builder +FROM golang:1.19.10 as builder ENV PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/go/bin:/usr/local/go/bin diff --git a/dev-tools/kubernetes/heartbeat/Dockerfile.debug b/dev-tools/kubernetes/heartbeat/Dockerfile.debug index cf61a85af40..bacfa95ca35 100644 --- a/dev-tools/kubernetes/heartbeat/Dockerfile.debug +++ b/dev-tools/kubernetes/heartbeat/Dockerfile.debug @@ -1,4 +1,4 @@ -FROM golang:alpine3.15 as builder +FROM golang:1.19.10 as builder ENV PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/go/bin:/usr/local/go/bin diff --git a/dev-tools/kubernetes/metricbeat/Dockerfile.debug b/dev-tools/kubernetes/metricbeat/Dockerfile.debug index 1462bc18b59..da68b4fb5d1 100644 --- a/dev-tools/kubernetes/metricbeat/Dockerfile.debug +++ b/dev-tools/kubernetes/metricbeat/Dockerfile.debug @@ -1,4 +1,4 @@ -FROM golang:alpine3.15 as builder +FROM golang:1.19.10 as builder ENV PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/go/bin:/usr/local/go/bin diff --git a/metricbeat/module/http/_meta/Dockerfile b/metricbeat/module/http/_meta/Dockerfile index 650c1c7c062..8565b542b1a 100644 --- a/metricbeat/module/http/_meta/Dockerfile +++ b/metricbeat/module/http/_meta/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16.5 +FROM golang:1.19.10 COPY test/main.go main.go diff --git a/metricbeat/module/nats/_meta/Dockerfile b/metricbeat/module/nats/_meta/Dockerfile index 24757de5400..bbc62eaa888 100644 --- a/metricbeat/module/nats/_meta/Dockerfile +++ b/metricbeat/module/nats/_meta/Dockerfile @@ -2,16 +2,16 @@ ARG NATS_VERSION=2.0.4 FROM nats:$NATS_VERSION # build stage -FROM golang:1.13-alpine3.11 AS build-env -RUN apk --no-cache add build-base git mercurial gcc -RUN cd src && go get -d github.com/nats-io/nats.go/ -RUN cd src/github.com/nats-io/nats.go/examples/nats-bench && git checkout tags/v1.10.0 && go build . +FROM golang:1.19.10 AS build-env +RUN apt-get install git mercurial gcc +RUN git clone https://github.com/nats-io/nats.go.git /nats-go +RUN cd /nats-go/examples/nats-bench && git checkout tags/v1.10.0 && go build . # create an enhanced container with nc command available since nats is based # on scratch image making healthcheck impossible FROM alpine:latest COPY --from=0 / /opt/nats -COPY --from=build-env /go/src/github.com/nats-io/nats.go/examples/nats-bench/nats-bench /nats-bench +COPY --from=build-env /nats-go/examples/nats-bench/nats-bench /nats-bench COPY run.sh /run.sh # Expose client, management, and cluster ports EXPOSE 4222 8222 6222 diff --git a/metricbeat/module/vsphere/_meta/Dockerfile b/metricbeat/module/vsphere/_meta/Dockerfile index d003155c7f7..c2a157cab08 100644 --- a/metricbeat/module/vsphere/_meta/Dockerfile +++ b/metricbeat/module/vsphere/_meta/Dockerfile @@ -1,7 +1,7 @@ ARG VSPHERE_GOLANG_VERSION -FROM golang:${VSPHERE_GOLANG_VERSION}-alpine +FROM golang:${VSPHERE_GOLANG_VERSION} -RUN apk add --no-cache curl git +RUN apt-get install curl git RUN go install github.com/vmware/govmomi/vcsim@v0.30.4 HEALTHCHECK --interval=1s --retries=60 --timeout=10s CMD curl http://localhost:8989/ diff --git a/x-pack/metricbeat/module/stan/_meta/Dockerfile b/x-pack/metricbeat/module/stan/_meta/Dockerfile index 030427a7c00..db00a41578f 100644 --- a/x-pack/metricbeat/module/stan/_meta/Dockerfile +++ b/x-pack/metricbeat/module/stan/_meta/Dockerfile @@ -2,17 +2,17 @@ ARG STAN_VERSION=0.15.1 FROM nats-streaming:$STAN_VERSION # build stage -FROM golang:1.13-alpine3.11 AS build-env -RUN apk --no-cache add build-base git mercurial gcc -RUN cd src && go get -d github.com/nats-io/stan.go/ -RUN cd src/github.com/nats-io/stan.go/examples/stan-bench && git checkout tags/v0.5.2 && go build . +FROM golang:1.19.10 AS build-env +RUN apt-get install git mercurial gcc +RUN git clone https://github.com/nats-io/stan.go.git /stan-go +RUN cd /stan-go/examples/stan-bench && git checkout tags/v0.5.2 && go build . # create an enhanced container with nc command available since nats is based # on scratch image making healthcheck impossible FROM alpine:latest RUN apk add --no-cache --upgrade bash COPY --from=0 nats-streaming-server /nats-streaming-server -COPY --from=build-env /go/src/github.com/nats-io/stan.go/examples/stan-bench/stan-bench /stan-bench +COPY --from=build-env /stan-go/examples/stan-bench/stan-bench /stan-bench # Expose client, management, and cluster ports EXPOSE 4222 8222 ADD healthcheck.sh /healthcheck.sh