Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ RUN curl -sSL "https://awscli.amazonaws.com/awscli-exe-linux-$(arch).zip" -o aws
./aws/install --bin-dir /usr/local/bin --install-dir /usr/local/aws-cli --update && \
rm -rf awscliv2.zip ./aws

ENV GO_VERSION=1.25.9
ENV GO_VERSION=1.26.9
ENV GOPATH=/root/go-packages
ENV GOROOT=/root/go
ENV PATH=$GOROOT/bin:$GOPATH/bin:$PATH
Expand Down Expand Up @@ -255,7 +255,7 @@ RUN curl -fsSL https://github.com/csweichel/oci-tool/releases/download/v0.2.0/oc
&& chmod +x /usr/local/bin/oci-tool

# Install golangci-lint
RUN go install -v github.com/golangci/golangci-lint/cmd/golangci-lint@latest
RUN GOBIN=/opt/golangci-lint/bin go install -v github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.15.0

ENV USE_GKE_GCLOUD_AUTH_PLUGIN=True

Expand Down Expand Up @@ -376,3 +376,6 @@ ENV PRE_COMMIT_HOME=/workspace/.pre-commit
# terminal sessions in Gitpod workspaces.
ENV PREVIEW_ENV_DEV_SA_KEY_PATH=/root/.config/gcloud/sa.json
ENV GOOGLE_EXTERNAL_ACCOUNT_ALLOW_EXECUTABLES=1

# Prefer the pinned linter over tools installed elsewhere in the image.
ENV PATH=/opt/golangci-lint/bin:$PATH
11 changes: 7 additions & 4 deletions dev/image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,17 @@ USER root
### Go ###
# Pin Go version explicitly to ensure all CI-built binaries use a
# non-vulnerable toolchain (CVE-2026-27143 requires >= 1.25.9).
ENV GO_VERSION=1.25.9
ENV GO_VERSION=1.26.9
RUN rm -rf /usr/local/go /home/gitpod/go /home/gitpod/.cache/go-build \
&& curl -fsSL "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz" | tar -C /usr/local -xz \
&& ln -sf /usr/local/go/bin/go /usr/bin/go \
&& ln -sf /usr/local/go/bin/gofmt /usr/bin/gofmt
ENV GOROOT=/usr/local/go
ENV PATH=/usr/local/go/bin:$PATH

# Install golangci-lint separately from tools inherited from the base image.
RUN GOBIN=/opt/golangci-lint/bin go install -v github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.15.0

### cloud_sql_proxy ###
ARG CLOUD_SQL_PROXY=/usr/local/bin/cloud_sql_proxy
RUN curl -fsSL https://dl.google.com/cloudsql/cloud_sql_proxy.linux.amd64 > $CLOUD_SQL_PROXY \
Expand Down Expand Up @@ -289,10 +292,10 @@ RUN curl -fsSL https://github.com/ericchiang/pup/releases/download/v0.4.0/pup_v0
RUN curl -fsSL https://github.com/csweichel/oci-tool/releases/download/v0.2.0/oci-tool_0.2.0_linux_amd64.tar.gz | sudo tar xz -C /usr/local/bin \
&& sudo chmod +x /usr/local/bin/oci-tool

# Install golangci-lint
RUN go install -v github.com/golangci/golangci-lint/cmd/golangci-lint@latest

RUN sudo install-packages pigz

# Install pre-commit hooks under /workspace during prebuilds
ENV PRE_COMMIT_HOME=/workspace/.pre-commit

# Prefer the pinned linter over any copy inherited from the base image.
ENV PATH=/opt/golangci-lint/bin:$PATH
Loading