Skip to content

feat(ci): Vivado in GitHub Actions Docker — Closes #604#622

Merged
gHashTag merged 3 commits into
masterfrom
feat/vivado-gha-docker
May 14, 2026
Merged

feat(ci): Vivado in GitHub Actions Docker — Closes #604#622
gHashTag merged 3 commits into
masterfrom
feat/vivado-gha-docker

Conversation

@gHashTag
Copy link
Copy Markdown
Owner

Summary

Replaces the Railway self-hosted runner approach (PR #621) with a pure GitHub Actions Docker setup. No self-hosted runner, no Railway costs, no external infra.

Architecture

build-vivado-image.yml  (one-time, manual)
  -> fetches Vivado_2025.2_Lin64.bin from a private GH Release asset
  -> silent-installs Vivado ML Standard, Artix-7 family only (~35 GB)
  -> pushes ghcr.io/<owner>/t27-vivado:2025.2

vivado-synth.yml  (per PR + workflow_dispatch)
  container: ghcr.io/<owner>/t27-vivado:2025.2
  -> builds t27c
  -> t27c fpga-build --smoke    (Verilog from .t27 specs)
  -> vivado -mode batch          (synth + P&R + bitstream)
  -> uploads .bit + utilization summary as artifacts

Files

  • infra/vivado-docker/Dockerfile — multi-stage Ubuntu 22.04 + Vivado 2025.2 install. Strips all non-Artix-7 device families and discards installer stage.
  • infra/vivado-docker/install_config.txt — silent-install config (Modules=Vivado:1, Artix-7:1, others:0, DocNav:0, EnableDiskUsageOptimization=1).
  • infra/vivado-docker/README.md — operator runbook (2-step setup: release upload + workflow click) and troubleshooting.
  • .github/workflows/build-vivado-image.yml — manual image-build workflow with easimon/maximize-build-space to free ~45 GB before install. Pushes to GHCR with GHA layer cache.
  • .github/workflows/vivado-synth.yml — synth pipeline using container: directive. Triggers on PRs touching fpga/, specs/fpga/, bootstrap/src/, and on manual dispatch with design selection (blinky / gf16 / phi_heartbeat) and UART toggle.
  • Removed obsolete .github/workflows/vivado-bitstream.yml (used dead kkrizka/vivado:2019.2 image).

Operator steps after merge

  1. Upload Vivado installer once as a private GH Release asset:
    gh release create vivado-installer-2025.2 \
      --repo gHashTag/t27 \
      --prerelease \
      ~/Downloads/Vivado_2025.2_Lin64.bin
    
  2. Actions tab → 'Build Vivado Docker Image' → Run workflow (one-time, ~60-90 min).
  3. Subsequent PRs to fpga/** auto-trigger vivado-synth.yml and produce bitstream artifacts.

Why this beats Railway

Railway runner (#621) GHA Docker (this PR)
Monthly cost $35–55 $0
Setup steps 9 manual (CLI + UI) 2 (release upload + click)
Vivado upgrade SSH into container Re-run workflow
Cold start Always-on 3–5 min image pull

Hardware-in-the-loop tok/s still requires DLC-10 JTAG attached to a real host. That stays the trios-bridge → Tailscale path on the Mac (gaia-macbook-air.tail2c3a29.ts.net): synth in GHA → bridge endpoint flashes the FPGA → uart-smoke binary streams telemetry back.

Policy compliance

Supersedes

Refs #604
Refs #620

Pure GH Actions setup, no self-hosted runner, no Railway:

- infra/vivado-docker/Dockerfile: multi-stage Ubuntu 22.04 + Vivado 2025.2 ML Standard
  silent-installed Artix-7-only (~35 GB final image). License-free WebPACK mode.
- infra/vivado-docker/install_config.txt: minimal install config (Vivado=1, Artix-7=1,
  all other families=0, DocNav=0).
- infra/vivado-docker/README.md: architecture, 2-step setup runbook, troubleshooting.

- .github/workflows/build-vivado-image.yml: manual workflow that fetches the
  Vivado installer from a private GitHub Release asset (tag vivado-installer-2025.2),
  builds the image, pushes ghcr.io/<owner>/t27-vivado:2025.2 with GHA layer cache.
- .github/workflows/vivado-synth.yml: per-PR synth pipeline using
  container: ghcr.io/<owner>/t27-vivado:2025.2; builds t27c, runs fpga-build --smoke
  for Verilog gen, runs Vivado synth/P&R/bitstream, extracts utilization/timing
  via inline awk, uploads bit + log artifacts. Triggers on fpga/ specs/fpga/
  bootstrap/src/ changes + workflow_dispatch.
- Removed obsolete .github/workflows/vivado-bitstream.yml (used kkrizka/vivado:2019.2
  which is dead and exceeded GH-hosted disk).

Easimon/maximize-build-space frees ~45 GB on ubuntu-latest before image pull.
GH-hosted 4 vCPU/16 GB sufficient for gf16_top synth+P&R (~25-40 min).

Refs #604
Refs #620
@github-actions
Copy link
Copy Markdown

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@gHashTag gHashTag changed the title feat(ci): Vivado in GitHub Actions Docker (replaces Railway runner) feat(ci): Vivado in GitHub Actions Docker — Closes #604 May 14, 2026
@github-actions
Copy link
Copy Markdown

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

vivado-synth.yml job fails on every PR because the container image
ghcr.io/<owner>/t27-vivado:2025.2 does not yet exist on the registry.
Disable the pull_request trigger until build-vivado-image.yml is run
once manually; workflow_dispatch remains available for first-build testing.

Comment-only block makes re-enabling a one-line edit after image exists.

Refs #604
@github-actions
Copy link
Copy Markdown

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@gHashTag gHashTag merged commit 9752bab into master May 14, 2026
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant