diff --git a/.github/workflows/agents-release.yml b/.github/workflows/agents-release.yml index 89f85e6b8b..f637505d42 100644 --- a/.github/workflows/agents-release.yml +++ b/.github/workflows/agents-release.yml @@ -272,7 +272,6 @@ jobs: ["linux-aarch64"]="linux/arm64" ["linux-x64"]="linux/amd64" ["windows-aarch64"]="windows/arm64" - ["windows-x64"]="windows/amd64" ) for platform in "${!TARGETS[@]}"; do IFS=/ read -r goos goarch <<< "${TARGETS[$platform]}" @@ -284,6 +283,20 @@ jobs: CGO_ENABLED=0 GOOS="$goos" GOARCH="$goarch" go build -trimpath -ldflags="-s -w" -o "$output" . done ls -lh ../../../release-native + # Go 1.20 is the last release that supports Windows 7; keep other targets on Go 1.22. + - name: Set up Go for Windows 7-compatible RabbitMQ agent + uses: actions/setup-go@v5 + with: + go-version: "1.20.14" + cache-dependency-path: agents/drivers/rabbitmq/go.sum + - name: Build Windows 7-compatible RabbitMQ agent + shell: bash + working-directory: agents/drivers/rabbitmq + run: | + output="../../../release-native/dbx-agent-rabbitmq-windows-x64.exe" + CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -trimpath -ldflags="-s -w" -o "$output" . + go version -m "$output" | tee /tmp/rabbitmq-windows-x64-build-info.txt + grep -q ': go1\.20\.14$' /tmp/rabbitmq-windows-x64-build-info.txt - uses: actions/upload-artifact@v4 with: name: rabbitmq-native diff --git a/agents/drivers/rabbitmq/go.mod b/agents/drivers/rabbitmq/go.mod index a3769c9a67..401f9a4bca 100644 --- a/agents/drivers/rabbitmq/go.mod +++ b/agents/drivers/rabbitmq/go.mod @@ -1,5 +1,5 @@ module github.com/t8y2/dbx/agents/drivers/rabbitmq -go 1.22 +go 1.20 require github.com/rabbitmq/amqp091-go v1.13.0