Skip to content

Conversation

@Mossaka
Copy link
Collaborator

@Mossaka Mossaka commented Feb 10, 2026

Summary

  • Adds a scheduled GitHub Actions workflow that builds and publishes nightly artifacts from main at 2:00 AM UTC
  • Reuses a single nightly release page (deletes and recreates each run) to avoid release page sprawl
  • Docker images are tagged :nightly only — :latest remains tied to versioned releases
  • Skips the build entirely if no new commits since the last nightly (compares the nightly tag SHA to HEAD)
  • Also supports manual trigger via workflow_dispatch

What gets published

Artifact Tag/Name
Squid image ghcr.io/.../squid:nightly
Agent image ghcr.io/.../agent:nightly
Agent-Act image ghcr.io/.../agent-act:nightly
Linux binary awf-linux-x64 (release asset)
npm tarball awf.tgz (release asset)
Checksums checksums.txt (release asset)

Differences from the release pipeline

Release (release.yml) Nightly (nightly.yml)
Trigger v*.*.* tag push Daily cron + manual
Docker tag :latest + :version :nightly only
Cosign signing Yes No
SBOM attestation Yes No
GitHub release One per version Single reused nightly page
Prerelease Only for alpha/beta/rc Always
Changelog Full GitHub-generated notes Commits since last nightly

Usage

# Pull nightly images
docker pull ghcr.io/$REPO/squid:nightly
docker pull ghcr.io/$REPO/agent:nightly

# Use with awf CLI
sudo awf --image-tag nightly --allow-domains example.com -- curl https://example.com

Test plan

  • Trigger manually via workflow_dispatch and verify it builds successfully
  • Verify Docker images are pushed with :nightly tag only (:latest unchanged)
  • Verify only one nightly release exists after multiple runs
  • Verify skip logic works when no new commits on main

🤖 Generated with Claude Code

Add a scheduled workflow that runs daily at 2:00 AM UTC to build and
publish nightly artifacts from the main branch. Key design decisions:

- Single GitHub release page: deletes and recreates the `nightly` release
  each run so there's only ever one nightly release on the repo
- Docker images tagged `:nightly` only — `:latest` remains tied to
  versioned releases
- Skips build if no new commits since last nightly (compares tag SHA)
- Publishes binary, npm tarball, and checksums as release assets
- Marked as prerelease to distinguish from stable releases
- Supports manual trigger via workflow_dispatch

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings February 10, 2026 21:42
@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

🎬 THE ENDSmoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

🌑 The shadows whisper... Smoke Codex failed. The oracle requires further meditation...

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

✅ Coverage Check Passed

Overall Coverage

Metric Base PR Delta
Lines 82.18% 82.18% ➡️ +0.00%
Statements 82.24% 82.24% ➡️ +0.00%
Functions 81.95% 81.95% ➡️ +0.00%
Branches 74.54% 74.54% ➡️ +0.00%

Coverage comparison generated by scripts/ci/compare-coverage.ts

@github-actions
Copy link
Contributor

Deno Build Test Results

Project Tests Status
oak 1/1 ✅ PASS
std 1/1 ✅ PASS

Overall: ✅ PASS

All Deno tests completed successfully.

AI generated by Build Test Deno

@github-actions
Copy link
Contributor

Build Test: Node.js - Results

All Node.js build tests PASSED

Project Install Tests Status
clsx PASS PASS
execa PASS PASS
p-limit PASS PASS

Overall: PASS

AI generated by Build Test Node.js

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new GitHub Actions workflow to produce and publish “nightly” artifacts from main on a schedule (and via manual trigger), including GHCR images and a GitHub prerelease that’s reused each run.

Changes:

  • Introduces .github/workflows/nightly.yml scheduled at 02:00 UTC with optional manual workflow_dispatch.
  • Builds and pushes :nightly Docker images (squid/agent/agent-act) and produces binary/npm/checksums release assets.
  • Implements “skip if no new commits” logic and regenerates a single nightly prerelease with a commit-based changelog.
Comments suppressed due to low confidence (2)

.github/workflows/nightly.yml:214

  • Using --target main can make the nightly tag/release point at a newer commit than the one this job built if new commits land on main while the workflow is running. To keep the release/tag consistent with the produced images/assets, create/update the nightly tag at the checked-out HEAD SHA (force-push if needed) and/or pass the explicit commit SHA as the --target.
          gh release create nightly \
            --title "Nightly Build (${DATE})" \
            --notes-file release_notes.md \
            --prerelease \
            --target main \
            release/awf-linux-x64 \

.github/workflows/nightly.yml:153

  • Like the earlier commit-check step, git rev-parse nightly / nightly..HEAD is ambiguous if a nightly branch ever exists. Use the explicit tag ref (refs/tags/nightly..HEAD) so the changelog is always computed from the last nightly tag.
          # Get commits since last nightly (or last 20 if no previous nightly)
          if git rev-parse nightly >/dev/null 2>&1; then
            CHANGELOG=$(git log --oneline --pretty=format:"- %s (%h)" nightly..HEAD 2>/dev/null || echo "- Nightly build from main")
          else
            CHANGELOG=$(git log --oneline --pretty=format:"- %s (%h)" -20 2>/dev/null || echo "- Initial nightly build")

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +28 to +29
if git rev-parse nightly >/dev/null 2>&1; then
LAST_NIGHTLY_SHA=$(git rev-parse nightly)
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

git rev-parse nightly can resolve to a branch name as well as a tag. Since this workflow’s logic depends on the tag specifically, use refs/tags/nightly (or nightly^{tag}) consistently when reading the last nightly SHA to avoid ambiguity if a nightly branch ever exists.

This issue also appears on line 149 of the same file.

Suggested change
if git rev-parse nightly >/dev/null 2>&1; then
LAST_NIGHTLY_SHA=$(git rev-parse nightly)
if git rev-parse refs/tags/nightly >/dev/null 2>&1; then
LAST_NIGHTLY_SHA=$(git rev-parse refs/tags/nightly)

Copilot uses AI. Check for mistakes.
- name: Check for new commits since last nightly
id: check_commits
run: |
# Get the timestamp of the existing nightly tag (if any)
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment says "Get the timestamp" but the code is actually comparing SHAs. Update the comment to match the behavior (SHA comparison) to avoid confusion when maintaining this workflow.

Suggested change
# Get the timestamp of the existing nightly tag (if any)
# Compare the commit SHA of the nightly tag (if any) with the current HEAD

Copilot uses AI. Check for mistakes.
Comment on lines +176 to +180
cat > release_notes.md <<EOF
## Nightly Build — ${DATE}

Built from [\`main@${SHORT_SHA}\`](${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}) (${NIGHTLY_VERSION})

Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The release notes link uses ${{ github.sha }}, but this workflow always checks out ref: main. For workflow_dispatch runs (or if the event SHA differs from the checked-out commit), this can generate a link that doesn’t match the artifacts/images that were actually built. Prefer linking to git rev-parse HEAD (full SHA) captured from the checkout.

This issue also appears on line 209 of the same file.

Copilot uses AI. Check for mistakes.
Comment on lines 161 to 165
gh release delete nightly --yes 2>/dev/null || true
# Delete the remote tag
git push origin :refs/tags/nightly 2>/dev/null || true
# Delete the local tag
git tag -d nightly 2>/dev/null || true
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This step ignores all errors when deleting the existing release/tag (|| true). That can hide real failures (auth/permission, API outages) and then later steps fail with less actionable errors (e.g., release already exists). Prefer checking for existence first (or only ignoring "not found"), and fail the job on unexpected delete failures.

Suggested change
gh release delete nightly --yes 2>/dev/null || true
# Delete the remote tag
git push origin :refs/tags/nightly 2>/dev/null || true
# Delete the local tag
git tag -d nightly 2>/dev/null || true
if gh release view nightly >/dev/null 2>&1; then
gh release delete nightly --yes
fi
# Delete the remote tag (if it exists)
if git ls-remote --tags origin nightly | grep -q 'refs/tags/nightly'; then
git push origin :refs/tags/nightly
fi
# Delete the local tag (if it exists)
if git rev-parse -q --verify refs/tags/nightly >/dev/null 2>&1; then
git tag -d nightly
fi

Copilot uses AI. Check for mistakes.
jobs:
nightly:
name: Nightly Build and Release
runs-on: ubuntu-latest
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a concurrency group for this workflow/job. As written, a manual workflow_dispatch run can overlap with the scheduled run, and both will delete/recreate the same nightly release/tag and push the same :nightly image tags, which can race and leave the release or images in an inconsistent state.

Suggested change
runs-on: ubuntu-latest
runs-on: ubuntu-latest
concurrency:
group: nightly-release
cancel-in-progress: false

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Contributor

Smoke Test Results - Claude Engine

✅ GitHub MCP: Last merged PR - "fix: use lowercase discussion categories to restore create_discussion tool"
✅ Playwright: GitHub page loaded with title "GitHub · Change is constant. GitHub keeps you ahead. · GitHub"
✅ File Writing: Created /tmp/gh-aw/agent/smoke-test-claude-21883495456.txt
✅ Bash Tool: Verified file content reads correctly

Status: PASS

AI generated by Smoke Claude

@github-actions
Copy link
Contributor

Go Build Test Results

Project Download Tests Status
color 1/1 PASS
env 1/1 PASS
uuid 1/1 PASS

Overall: PASS

All Go projects built and tested successfully.

AI generated by Build Test Go

@github-actions
Copy link
Contributor

Smoke Test Results 🧪

Status: ✅ PASS

cc @Mossaka @Copilot

AI generated by Smoke Copilot

@github-actions
Copy link
Contributor

❌ Build Test: Bun - FAILED

Test Status: FAILED - Environment Issue

Error Details

Bun installation succeeded, but bun install fails due to missing /proc filesystem access:

error: An internal error occurred (NotDir)

Root Cause: The /proc/cpuinfo file is not accessible in this environment. Bun requires access to the /proc filesystem to detect system capabilities (CPU info, etc.).

Environment Issue

This test cannot proceed without /proc filesystem access. The GitHub Actions runner environment does not provide the necessary kernel filesystem access that Bun requires.

Test Results

Project Install Tests Status
elysia ❌ Failed N/A BLOCKED
hono ❌ Failed N/A BLOCKED

Overall: FAILED - Environment incompatibility

Recommendation

This test requires:

  • Full /proc filesystem access
  • Container with proper kernel access
  • Alternative runner configuration

The label build-test-bun will NOT be added due to test failure.

AI generated by Build Test Bun

@github-actions
Copy link
Contributor

❌ Build Test: Rust - FAILED

Status: CRITICAL ENVIRONMENT ISSUE

Unable to execute Rust build tests due to a critical runner environment problem.

Issue Details

The Rust toolchain installation is corrupted on this GitHub Actions runner:

  • All Rust binaries (rustup, cargo, rustc) are replaced with copies of /bin/bash
  • File hash verification: md5sum shows all Rust binaries have identical hash to /bin/bash: 303330f9f1b6617b3b533e4dcfe1faf0
  • Multiple reinstallation attempts (including full removal of ~/.cargo and ~/.rustup) produce the same corrupted state

Attempted Solutions

  1. ✅ Successfully cloned test repository Mossaka/gh-aw-firewall-test-rust
  2. ❌ Initial Rust installation corrupted
  3. ❌ Complete removal and reinstall - still corrupted
  4. ❌ Direct binary execution attempts all execute bash instead

Required Action

This requires GitHub Actions runner environment investigation:

  • The rustup installer is somehow producing bash binaries instead of Rust binaries
  • This is not a code issue but an infrastructure/runner problem
  • Tests cannot proceed until the Rust toolchain can be properly installed

Test Projects Unable to Run

  • fd: Build and test skipped
  • zoxide: Build and test skipped

AI generated by Build Test Rust

- Add concurrency group to prevent parallel run races
- Add timeout-minutes (30min) to avoid wasting runner time
- Make workflow_dispatch bypass the "no new commits" skip logic
- Split heredoc into parts to avoid shell expansion of changelog
  content (commit messages with $ or backticks could corrupt notes)
- Add upload-artifact step for debugging failed runs
- Add binary verification logging (ls -lh, file)
- Remove redundant --oneline from git log commands
- Quote $GITHUB_OUTPUT references

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Contributor

Build Test: Java - FAILED ❌

Infrastructure Error

Cannot execute Java build tests due to corrupted Java installation on the runner:

Issue: The Java binary at /usr/lib/jvm/temurin-21-jdk-amd64/bin/java is executing as bash instead of the Java Runtime Environment.

Evidence:

$ /usr/lib/jvm/temurin-21-jdk-amd64/bin/java -help
GNU bash, version 5.2.21(1)-release-(x86_64-pc-linux-gnu)
Usage:	/usr/lib/jvm/temurin-21-jdk-amd64/bin/java [GNU long option] [option] ...

Impact: Cannot compile or test any Java projects (gson, caffeine) until the Java installation is fixed.

Test Status

Project Compile Tests Status
gson ❌ BLOCKED ❌ BLOCKED FAILED
caffeine ❌ BLOCKED ❌ BLOCKED FAILED

Overall: FAILED (Infrastructure issue - corrupted Java installation)


Action Required: GitHub Actions runner image needs Java reinstallation before Java build tests can proceed.

AI generated by Build Test Java

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

🌑 The shadows whisper... Smoke Codex failed. The oracle requires further meditation...

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

💫 TO BE CONTINUED... Smoke Claude failed! Our hero faces unexpected challenges...

@github-actions
Copy link
Contributor

C++ Build Test Results

Project CMake Build Status
fmt PASS
json PASS

Overall: PASS

All C++ projects built successfully.

AI generated by Build Test C++

@github-actions
Copy link
Contributor

Deno Build Test Results

Project Tests Status
oak 1/1 ✅ PASS
std 1/1 ✅ PASS

Overall: ✅ PASS

All Deno tests completed successfully.

AI generated by Build Test Deno

@github-actions
Copy link
Contributor

❌ Build Test: Rust - FAILED

Error: Rust toolchain not available in the test environment.

Project Build Tests Status
fd N/A FAIL - cargo not found
zoxide N/A FAIL - cargo not found

Overall: FAIL

Issue

The GitHub Actions runner does not have cargo or rustc installed.

Solution Required

Add Rust toolchain setup to the workflow file:

- name: Setup Rust
  uses: actions-rs/toolchain@v1
  with:
    toolchain: stable
    profile: minimal

or use dtolnay/rust-toolchain action.

AI generated by Build Test Rust

@github-actions
Copy link
Contributor

Build Test: Node.js - Results

Project Install Tests Status
clsx PASS PASS
execa PASS PASS
p-limit PASS PASS

Overall: PASS

All Node.js projects successfully installed dependencies and passed their test suites.

AI generated by Build Test Node.js

@github-actions
Copy link
Contributor

Go Build Test Results

Project Download Tests Status
color 1/1 PASS
env 1/1 PASS
uuid 1/1 PASS

Overall: PASS

All Go projects successfully downloaded dependencies and passed their tests.

AI generated by Build Test Go

@github-actions
Copy link
Contributor

Smoke Test Results ✅ PASS

cc @Mossaka

AI generated by Smoke Copilot

@github-actions
Copy link
Contributor

Build Test: Java - ❌ FAILED

Status: Unable to execute tests due to environment issues

Test Results

Project Compile Tests Status
gson ❌ N/A N/A FAILED
caffeine ❌ N/A N/A FAILED

Overall: FAILED

Error Details

The Java runtime environment is not functional in the GitHub Actions runner. Attempts to execute Java commands result in errors:

java -version
# Output: GNU bash, version 5.2.21(1)-release
# Expected: openjdk version info

mvn compile
# Error: /usr/share/apache-maven-3.9.12/boot/plexus-classworlds-2.9.0.jar: cannot execute binary file: Exec format error

Investigation needed:

  • Java binaries may be corrupted or misconfigured
  • Environment variable conflicts (PATH, JAVA_HOME)
  • Runner image may need JDK reinstallation

The test repository was cloned successfully from Mossaka/gh-aw-firewall-test-java, but Maven compilation cannot proceed without a working Java environment.

AI generated by Build Test Java

@github-actions
Copy link
Contributor

Build Test: Bun - FAILED ❌

Status: Unable to run tests due to environmental limitations

Summary

Project Install Tests Status
elysia N/A FAIL
hono N/A FAIL

Overall: FAIL

Issue

Bun cannot execute in this environment due to missing /proc filesystem access:

  • Only /proc/self is available (required: /proc/cpuinfo and others)
  • All Bun operations fail with "Aborted (core dumped)" errors
  • Error: An internal error occurred (NotDir)

Recommendation

To run Bun tests, use a standard GitHub Actions runner environment:

runs-on: ubuntu-latest  # Instead of container-based execution

Or consider using Node.js/Deno runtimes which don't require /proc access.

AI generated by Build Test Bun

@Mossaka Mossaka closed this Feb 10, 2026
@Mossaka Mossaka reopened this Feb 10, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

🎬 THE ENDSmoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤

@github-actions
Copy link
Contributor

github-actions bot commented Feb 10, 2026

🌑 The shadows whisper... Smoke Codex failed. The oracle requires further meditation...

@github-actions
Copy link
Contributor

Smoke Test Results - Claude

Last 2 merged PRs:

✅ GitHub MCP - retrieved PR data
✅ Playwright - navigated to github.com, title verified
✅ File Write - created test file in /tmp/gh-aw/agent/
✅ Bash Tool - verified file contents

Status: PASS

AI generated by Smoke Claude

@github-actions
Copy link
Contributor

Deno Build Test Results ✅

Project Tests Status
oak 1/1 ✅ PASS
std 1/1 ✅ PASS

Overall: PASS

All Deno tests completed successfully.

AI generated by Build Test Deno

@github-actions
Copy link
Contributor

Copilot Smoke Test Results

Last 2 merged PRs:

✅ GitHub MCP
✅ Playwright (title: "GitHub · Change is constant. GitHub keeps you ahead. · GitHub")
✅ File Writing
✅ Bash Tool

Status: PASS

cc @Mossaka

AI generated by Smoke Copilot

@github-actions
Copy link
Contributor

Node.js Build Test Results

Project Install Tests Status
clsx PASS ✅ PASS
execa PASS ✅ PASS
p-limit PASS ✅ PASS

Overall: ✅ PASS

All Node.js projects built and tested successfully.

AI generated by Build Test Node.js

@github-actions
Copy link
Contributor

C++ Build Test Results

Project CMake Build Status
fmt PASS
json PASS

Overall: PASS

All C++ projects built successfully.

AI generated by Build Test C++

@github-actions
Copy link
Contributor

Build Test: Bun - FAILED ❌

Summary: Bun runtime installed successfully, but the test runner crashes in the GitHub Actions environment.

Project Install Tests Status
elysia N/A ❌ Crashed FAIL
hono N/A ❌ Crashed FAIL

Overall: FAIL

Error Details

Bun Version: 1.3.9
Environment: GitHub Actions (Ubuntu 24.04, Linux 6.11.0-1018-azure)

Both test projects failed with the same error:

bun test v1.3.9 (cf6cdbbb)
Aborted (core dumped)

Root Cause: The Bun test runner consistently crashes with a core dump in the GitHub Actions container environment. This occurs even with minimal test files using only Bun's built-in test framework (bun:test).

Attempted:

  • ✅ Bun installed successfully
  • ✅ Repository cloned successfully
  • ✅ Basic Bun commands (--help, --version) work
  • bun test crashes in all scenarios
  • ❌ Simple standalone test file also crashes

This appears to be an incompatibility between Bun's test runner and the GitHub Actions containerized environment, possibly related to missing system capabilities or kernel features required by Bun's test harness.

AI generated by Build Test Bun

@github-actions
Copy link
Contributor

Build Test Results: Rust

Project Build Tests Status
fd 1/1 PASS
zoxide 1/1 PASS

Overall: PASS

All Rust projects built successfully and passed their test suites.

AI generated by Build Test Rust

@github-actions
Copy link
Contributor

Build Test: Java - UNABLE TO EXECUTE

Status: ❌ FAILED - Java Runtime Not Available

Summary

Unable to execute Java tests due to a runtime environment issue within the AWF firewall container.

Issue Details

When attempting to run Java binaries (/usr/lib/jvm/temurin-21-jdk-amd64/bin/java), the execution fails and returns bash output instead. This indicates a fundamental incompatibility between the AWF chroot environment and Java binary execution.

Attempted diagnostics:

  • ✅ Java binaries are present at expected paths
  • ✅ Files are valid ELF executables (verified with file command)
  • ❌ Execution fails: every Java invocation returns GNU bash version info instead of running Java
  • ❌ Even direct loader invocation (/lib64/ld-linux-x86-64.so.2 /path/to/java) exhibits the same behavior

Root Cause

This appears to be a deep integration issue with the AWF chroot environment (AWF_CHROOT_ENABLED=true). The container's execution environment is intercepting or redirecting binary execution in a way that prevents Java from running.

Required Action

This workflow cannot be completed until Java execution is properly supported in the AWF firewall environment. This likely requires:

  1. Investigation of the AWF container entrypoint and chroot setup
  2. Modifications to support Java runtime execution
  3. Testing with other compiled binaries to determine scope of the issue

Test Projects

Project Compile Tests Status
gson FAILED - Java not executable
caffeine FAILED - Java not executable

Overall: FAILED

AI generated by Build Test Java

@Mossaka Mossaka closed this Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant