Skip to content

Commit fcdd9d7

Browse files
colinsaramprice
authored andcommitted
fix(ci/fly-bats): inline Go compile step with 1.26.3 workaround
1 parent bffbe95 commit fcdd9d7

1 file changed

Lines changed: 34 additions & 1 deletion

File tree

ci/fly-bats.yml

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,40 @@ jobs:
8686
file: bosh-ci/ci/tasks/make-candidate.yml
8787

8888
- task: compile-bosh-release
89-
file: bosh-deployment/ci/tasks/shared/bosh-agent-compile.yml
89+
config:
90+
platform: linux
91+
# ubuntu-noble-stemcell ships the BOSH agent at /var/vcap/bosh/bin/bosh-agent.
92+
image_resource:
93+
type: registry-image
94+
source:
95+
repository: ghcr.io/cloudfoundry/ubuntu-noble-stemcell
96+
inputs:
97+
- name: release
98+
outputs:
99+
- name: compiled-release
100+
run:
101+
path: /bin/bash
102+
args:
103+
- -exc
104+
- |
105+
# golang-1.26-linux on this branch is a stub (env files only; no binary
106+
# blob in GCS yet). Install Go 1.26.3 and drop a shim at
107+
# /usr/local/bin/go so `go build` works even though $GOROOT/bin is empty.
108+
GO_VERSION=1.26.3
109+
if ! /usr/local/go/bin/go version 2>/dev/null | grep -q "go${GO_VERSION}"; then
110+
curl -sSfL "https://go.dev/dl/go${GO_VERSION}.linux-amd64.tar.gz" \
111+
| tar -C /usr/local -xz
112+
fi
113+
cat > /usr/local/bin/go <<'GOSHIM'
114+
#!/bin/bash
115+
export GOROOT=/usr/local/go
116+
exec /usr/local/go/bin/go "$@"
117+
GOSHIM
118+
chmod +x /usr/local/bin/go
119+
120+
/var/vcap/bosh/bin/bosh-agent compile \
121+
--output-directory compiled-release \
122+
release/*.tgz
90123
91124
- task: run-bats
92125
image: integration-image

0 commit comments

Comments
 (0)