Skip to content

GitHub Actions Workflows

opencode-agent[bot] edited this page Aug 17, 2026 · 1 revision

GitHub Actions Workflows

CI/CD automation for JNode: build, test, boot verification, agent-driven issue resolution, and wiki maintenance.

Overview

JNode uses GitHub Actions for continuous integration, automated testing, boot verification, AI-assisted issue resolution, and wiki maintenance. Five workflows cover the full development lifecycle from code push to documentation updates.

All workflows use concurrency groups to prevent redundant runs and share common setup patterns (JDK 8, QEMU, artifact caching).

Workflows

Workflow File Trigger Purpose
Java CI ant.yml push/PR to master, manual Build ISO, run JUnit tests, QEMU boot test
OpenCode opencode.yml issue/PR comment with /oc AI agent resolves issues or reviews PRs
Orchestrator orchestrator.yml /orchestrate comment, workflow completion, PR review Multi-agent task coordination
Pages pages.yml push to master (pages paths), manual Deploy MkDocs documentation to GitHub Pages
Wiki Update wiki-update.yml Weekly cron (Sunday 06:00 UTC), manual Analyze commits and update wiki pages

Java CI (ant.yml)

Three-job pipeline: build → test → boot.

Build Job

  1. Checkout code, set up JDK 8 (Zulu), install nasm and qemu-system-x86
  2. Run ./build.sh clean -Dbuild.properties.file=../.github/qemu/jnode.properties cd-x86-lite regression-tests
  3. Upload */build/** and all/lib/classlib.jar as artifacts (1-day retention)

Test Job

Downloads build artifacts, runs ./test.sh all (invokes ant -f <project>/build-tests.xml for each subproject). Publishes JUnit XML results via test-summary/action@v2.

Boot Job

Downloads build artifacts, starts QEMU with the ISO, waits up to 120s for "System has finished" on serial console. Uploads boot log as artifact.

Key details:

  • QEMU: qemu-system-x86_64 -cdrom jnode-x86-lite.iso -m 1024 -M pc -cpu pentium -boot once=d,menu=off -net none -serial file:/tmp/com1.txt -display none
  • Concurrency: ant-${{ github.ref }} with cancel-in-progress: true

OpenCode (opencode.yml)

Triggered by issue or PR comments containing /oc. Only collaborators, members, or owners can trigger.

Flow:

  1. Checkout, clone wiki, set up JDK 8, install QEMU
  2. Copy .github/qemu/jnode.properties for build config
  3. Cache ISO build (keyed on *.java, build.xml, build.sh hash)
  4. Build ISO if not cached
  5. Run OpenCode agent with opencode/mimo-v2.5-free model
  6. Post-step: apply agent/* label, close issue if work-product is the comment

Permissions: id-token: write, contents: write, pull-requests: write, issues: write

Orchestrator (orchestrator.yml)

Coordinates multi-agent workflows. Triggered by:

  • /orchestrate issue comment
  • opencode workflow completion
  • PR review submission

Uses actions/github-script@v7 to call .github/scripts/orchestrator.js.

Concurrency: orchestrator-concurrency with cancel-in-progress: false (runs must complete)

Pages (pages.yml)

Deploys MkDocs documentation to GitHub Pages.

Trigger: Push to master affecting .github/pages/** or the workflow itself.

Build:

  1. Python 3.11, install mkdocs-material, mkdocs-git-revision-date-localized-plugin, mkdocs-minify-plugin
  2. mkdocs build --strict --verbose in .github/pages/
  3. Deploy via actions/deploy-pages@v4

Wiki Update (wiki-update.yml)

Automated weekly wiki maintenance. Runs every Sunday at 06:00 UTC or via manual dispatch.

Flow:

  1. Checkout, clone wiki
  2. Determine commit range (from .last-wiki-update marker or 7 days ago)
  3. List commits in range; skip if none
  4. Run OpenCode agent with prompt to analyze commits and update wiki
  5. Update .last-wiki-update marker

Inputs:

  • since (optional): Override start date (YYYY-MM-DD)

Key features:

  • Concurrency group wiki-update with cancel-in-progress
  • Reads .wiki/.last-wiki-update for incremental updates
  • Agent follows update-wiki skill workflow
  • Creates and closes issue with update summary

Key Components

Component File Purpose
ant.yml .github/workflows/ant.yml Build, test, boot pipeline
opencode.yml .github/workflows/opencode.yml AI agent issue/PR handler
orchestrator.yml .github/workflows/orchestrator.yml Multi-agent coordination
pages.yml .github/workflows/pages.yml MkDocs deployment
wiki-update.yml .github/workflows/wiki-update.yml Weekly wiki maintenance
jnode.properties .github/qemu/jnode.properties QEMU build configuration
opencode-post-step.js .github/scripts/opencode-post-step.js Post-agent label/close logic
orchestrator.js .github/scripts/orchestrator.js Orchestration logic

Gotchas

  • ISO caching — The opencode.yml workflow caches the ISO build. If build scripts or Java files change, the cache key hash changes and a rebuild occurs. Stale caches can cause boot failures.
  • QEMU boot timeout — The boot job uses a 120s timeout. Slow CI runners may need this increased.
  • Wiki auto-push — The wiki-update workflow clones .wiki/ as a separate git repo. Changes must be pushed explicitly from within .wiki/, not via the main repo's auto-push.
  • Concurrency groupsant.yml cancels in-progress runs for the same ref; orchestrator.yml does NOT cancel (runs must complete). Choose carefully when adding new workflows.
  • Permissions — Agent workflows need id-token: write for OIDC and contents: write for wiki cloning. New workflows should follow the same pattern.

Related Pages

  • Build-System — Ant build targets and BootImageBuilder
  • Testing — JUnit tests and boot testing
  • Boot-Log — Serial output used by boot job verification
  • Architecture — System layers and CI integration points

Clone this wiki locally