From d5daadb7d3cad124adf044f192ae2ddff9a6f2cf Mon Sep 17 00:00:00 2001 From: dborup Date: Fri, 2 Oct 2026 16:04:34 +0200 Subject: [PATCH] ci: bound the "Verify proto syntax" step so an apt stall fails fast Relates to #156. The step ran apt-get update/install with no timeout, so a stalled mirror held the runner (one PR run sat ~45 min on 2026-09-30). - timeout-minutes: 5 on the step - apt: Acquire::Retries=3 and Acquire::http::Timeout=30 on update and install, DEBIAN_FRONTEND=noninteractive - explicit error if protoc is missing after install - timeout-minutes: 40 on the "Go Build & Test" job (normal 16-22 min) --- .github/workflows/deploy.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index d3262947b..3f93aa07f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -37,6 +37,7 @@ jobs: go-test: name: "✅ Go Build & Test" runs-on: ubuntu-latest + timeout-minutes: 40 steps: - name: Checkout code uses: actions/checkout@v5 @@ -249,10 +250,15 @@ jobs: npx eslint public/*.js - name: Verify proto syntax + timeout-minutes: 5 run: | set -e - sudo apt-get update -qq - sudo apt-get install -y protobuf-compiler + # Bounded apt: retry transient mirror errors, give up on a stalled + # connection after 30s instead of hanging (#156). + APT_OPTS="-o Acquire::Retries=3 -o Acquire::http::Timeout=30" + sudo DEBIAN_FRONTEND=noninteractive apt-get $APT_OPTS update -qq + sudo DEBIAN_FRONTEND=noninteractive apt-get $APT_OPTS install -y protobuf-compiler + command -v protoc >/dev/null || { echo "::error::protoc not found after install"; exit 1; } for proto in proto/*.proto; do echo " ✓ $(basename "$proto")" protoc --proto_path=proto --descriptor_set_out=/dev/null "$proto"