diff --git a/.github/workflows/ab-report.yml b/.github/workflows/ab-report.yml index 51e3c89..5a420be 100644 --- a/.github/workflows/ab-report.yml +++ b/.github/workflows/ab-report.yml @@ -30,7 +30,7 @@ jobs: - uses: actions/setup-go@v5 with: - go-version-file: go.mod + go-version: "1.27.3" - name: Detect app id id: app diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 826666a..ccd3432 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,10 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" + # Go 1.27.3 everywhere in this repo: these jobs, the VM builds + # (deploy.yml, deploy/*/startup.sh) and the images (deploy/docker/). + # Go 1.25 is end of life. go.mod's go line is left alone. + go-version: "1.27.3" cache: true - name: gofmt (must be clean) @@ -64,7 +67,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version: "1.27.3" cache: true # staticcheck via `go run @latest` builds with THIS module's Go toolchain, # so it always matches the go.mod version (golangci-lint v1 is built with an @@ -78,7 +81,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version: "1.27.3" cache: true - name: broker end-to-end (real process, multi-user) run: ./scripts/e2e-broker.sh @@ -89,7 +92,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version: "1.27.3" cache: true - name: full publish→build→register→sign→broker→partner→meter+ratelimit run: ./scripts/e2e-managed.sh diff --git a/.github/workflows/deploy-appstore-meta.yml b/.github/workflows/deploy-appstore-meta.yml index b77f113..944897a 100644 --- a/.github/workflows/deploy-appstore-meta.yml +++ b/.github/workflows/deploy-appstore-meta.yml @@ -57,6 +57,14 @@ jobs: --tunnel-through-iap \ --command ' set -e + # Go 1.27.3 on the VM before building: startup.sh installs it on + # boot, this covers a VM that has not been reset since. + GO_VERSION=1.27.3 + if ! /usr/local/go/bin/go version 2>/dev/null | grep -q "go${GO_VERSION} "; then + tgz=$(mktemp) + curl -fsSL "https://go.dev/dl/go${GO_VERSION}.linux-amd64.tar.gz" -o "$tgz" + sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf "$tgz" && rm -f "$tgz" + fi sudo -u pilot bash -c "export PATH=\$PATH:/usr/local/go/bin; \ cd /opt/pilot/app-template && git pull --ff-only && \ go run ./cmd/appstore-meta-api -check && \ diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index abb1c8a..37752f1 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -65,6 +65,15 @@ jobs: set -euo pipefail gcloud compute ssh "$INSTANCE" --project "$PROJECT" --zone "$ZONE" --tunnel-through-iap --command ' set -e + # Go 1.27.3 on the VM before building: startup.sh installs it on + # boot, this covers a VM that has not been reset since. + # publish-server also compiles submitted adapters with it. + GO_VERSION=1.27.3 + if ! /usr/local/go/bin/go version 2>/dev/null | grep -q "go${GO_VERSION} "; then + tgz=$(mktemp) + curl -fsSL "https://go.dev/dl/go${GO_VERSION}.linux-amd64.tar.gz" -o "$tgz" + sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf "$tgz" && rm -f "$tgz" + fi sudo -u pilot bash -c "export PATH=\$PATH:/usr/local/go/bin; \ cd /opt/pilot/app-template && git pull --ff-only && \ go build -o /opt/pilot/publish-server ./cmd/publish-server && \ diff --git a/.github/workflows/publish-on-merge.yml b/.github/workflows/publish-on-merge.yml index b3a4c7e..983fad9 100644 --- a/.github/workflows/publish-on-merge.yml +++ b/.github/workflows/publish-on-merge.yml @@ -32,7 +32,7 @@ jobs: - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version: "1.27.3" - name: Build verifier run: go build -o /tmp/pilot-app ./cmd/pilot-app diff --git a/.github/workflows/rotate-wallet-publisher.yml b/.github/workflows/rotate-wallet-publisher.yml index 91b1978..b6771b2 100644 --- a/.github/workflows/rotate-wallet-publisher.yml +++ b/.github/workflows/rotate-wallet-publisher.yml @@ -21,7 +21,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version-file: go.mod + go-version: "1.27.3" - name: Rotate io.pilot.wallet's publisher pin env: CATALOG_PUBLISH_TOKEN: ${{ secrets.CATALOG_PUBLISH_TOKEN }} diff --git a/.github/workflows/submission-validate.yml b/.github/workflows/submission-validate.yml index 07daced..667a3d1 100644 --- a/.github/workflows/submission-validate.yml +++ b/.github/workflows/submission-validate.yml @@ -19,7 +19,7 @@ jobs: - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version: "1.27.3" - name: Build, vet, test the tool run: | diff --git a/deploy/appstore-meta/startup.sh b/deploy/appstore-meta/startup.sh index d05d821..9ca5303 100755 --- a/deploy/appstore-meta/startup.sh +++ b/deploy/appstore-meta/startup.sh @@ -16,7 +16,7 @@ # appstore-meta-ref git ref to build (empty -> main) set -euo pipefail -GO_VERSION=1.25.0 +GO_VERSION=1.27.3 ARCH=linux-amd64 REPO=https://github.com/pilot-protocol/app-template diff --git a/deploy/docker/broker.Dockerfile b/deploy/docker/broker.Dockerfile index e9e958e..29f1745 100644 --- a/deploy/docker/broker.Dockerfile +++ b/deploy/docker/broker.Dockerfile @@ -3,7 +3,7 @@ # # Build from the repo root: # docker build -f deploy/docker/broker.Dockerfile -t pilot-broker . -FROM golang:1.25 AS build +FROM golang:1.27.3 AS build WORKDIR /src COPY go.mod go.sum ./ RUN go mod download diff --git a/deploy/docker/publish-server.Dockerfile b/deploy/docker/publish-server.Dockerfile index 3b5f991..9fe5acc 100644 --- a/deploy/docker/publish-server.Dockerfile +++ b/deploy/docker/publish-server.Dockerfile @@ -5,7 +5,7 @@ # # Build from the repo root: # docker build -f deploy/docker/publish-server.Dockerfile -t pilot-publish-server . -FROM golang:1.25 +FROM golang:1.27.3 RUN apt-get update \ && apt-get install -y --no-install-recommends git ca-certificates \ && rm -rf /var/lib/apt/lists/* diff --git a/deploy/smol-broker/startup.sh b/deploy/smol-broker/startup.sh index b9dbcf7..86cc1dd 100755 --- a/deploy/smol-broker/startup.sh +++ b/deploy/smol-broker/startup.sh @@ -12,7 +12,7 @@ # SMOL_DERIVE_SECRET the HMAC secret used to mint per-user keys set -euo pipefail -GO_VERSION=1.25.0 +GO_VERSION=1.27.3 BRANCH="${BROKER_BRANCH:-main}" HOSTNAME_FQDN="smol-broker.pilotprotocol.network" diff --git a/deploy/startup.sh b/deploy/startup.sh index c0b6954..1c425d9 100755 --- a/deploy/startup.sh +++ b/deploy/startup.sh @@ -9,7 +9,7 @@ # admin-token gates /admin + approve/reject set -euo pipefail -GO_VERSION=1.25.0 +GO_VERSION=1.27.3 ARCH=linux-amd64 apt-get update -y