Commit graph onionwire/.forgejo/workflows
Author SHA1 Message Date
Sirius DevOps
6f96d19901
ci: watch upstream Arti/tor-* releases daily and file an upgrade issue
.forgejo/workflows/arti-watch.yml runs daily (06:17 UTC) and via
workflow_dispatch: scripts/arti-watch.py compares each tor-*/arti-* pin in
Cargo.toml against crates.io and files one Forgejo issue per distinct
major.minor bump, deduped on the title so a repeat run is a no-op. It changes
no dependency.

docs/ARTI_UPGRADE.md records the pinned set (arti-client, tor-cell,
tor-hsservice, tor-rtcompat at 0.46), the lockstep rule, the rustc 1.91
floor, and the tests a bump must pass (tests/tor_hs.rs live publish +
probe-connect + byte pipe, the 360s fail-closed wait and the src/hs.rs
circuit-timeout workarounds in tests/hs.rs, the Android rustls build).

Both artefacts state what this does not cover: Tor Project security
announcements, a yanked crate, and a vulnerability with no version bump.
2026-09-12 13:55:07 -04:00
f01cb7b937 Merge branch 'main' into wt/t_87d7245b 2026-09-12 13:43:24 +00:00
Sirius DevOps
30b0294c2b
ci(release): delete dangling tags from the publish job
The sibling cleanup job ran after a successful v0.1.0 publish (run 135)
because act leaves needs.publish.result unset, so != success is true.
It Early-terminated before deleting, but that is not a guard. Fold
fail-closed delete into publish as if: failure() and drop the extra job.
2026-09-12 03:01:14 -04:00
Sirius DevOps
9b7e72b257
ci(release): publish from the Pi; surface API 422s
Run 116 built both arches then POST /releases returned 422 six times
(--retry-all-errors) with no body, while sitting on docker-amd64 behind
android. Move publish to the Pi runner (same path as tag create) and
print the Forgejo error instead of retrying 4xx. README now matches the
core-only path filter and onionwire-ci-pi concurrency.
2026-09-12 02:51:07 -04:00
Sirius DevOps
63abd8eaf2
fix(ci): do not fail the Android verify pipe on SIGPIPE from head
All checks were successful
ci / test (pull_request) Successful in 2m44s
BUILD SUCCESSFUL produced a 33MB arm64 APK; pipefail + aapt|head then
exited 141 and dropped the artifacts before docker cp.
2026-09-12 02:23:34 -04:00
Sirius DevOps
c90c59146d
fix(ci): new android-release concurrency group so dry_run can queue
All checks were successful
ci / test (pull_request) Successful in 2m46s
2026-09-12 02:06:37 -04:00
Sirius DevOps
1218869629
ci: skip cargo suite when the change cannot affect Rust
Some checks failed
ci / test (pull_request) Has been cancelled
Path allowlist on push-to-main and pull_request: src/, crates/, tests/,
Cargo.toml, Cargo.lock, and this workflow. workflow_dispatch still always
runs. No branch protections, so a skipped run is not a merge trap.
2026-09-12 01:42:01 -04:00
Sirius DevOps
1e6a4c12b2
fix(ci): join latest tag when its release lacks the APK
All checks were successful
ci / test (pull_request) Successful in 2m45s
Core owns tag creation. If vN exists and the release is missing the
Android APK, attach there instead of minting N+1. Never delete tags.
Path filter is sources/Gradle only — README edits do not publish.
2026-09-12 01:37:40 -04:00
Sirius DevOps
ae9cd5728e
ci(release): do not mint a release for workflow-only edits
All checks were successful
ci / test (pull_request) Successful in 4m46s
Drop release.yml and build-release-local.sh from on.push.paths so a CI
tweak cannot cut a user-facing tag. Validate those files with dry_run
dispatch instead. release-body.md stays because it is the published body.
2026-09-12 01:35:13 -04:00
Sirius DevOps
eaea3d49f7
ci(release): apt retries on IPv4; never skip the publish job
All checks were successful
ci / test (pull_request) Successful in 3m39s
Concurrent dind rust containers looped on apt InRelease; abort and retry
with ForceIPv4. Publish always runs after version so cleanup is not
blocked by Forgejo act "'runs-on' key not defined" on a skipped job.
Do not bake a custom rust image on this card.
2026-09-12 01:30:16 -04:00
Sirius DevOps
87ab0d2869
fix(ci): use debian:bookworm for the Android sibling container
All checks were successful
ci / test (pull_request) Successful in 3m0s
eclipse-temurin:17-jdk-bookworm is not a published tag (manifest unknown).
debian:bookworm is current and has openjdk-17.
2026-09-12 01:16:28 -04:00
Sirius DevOps
c087b223e9
fix(ci): build Android APK in a bookworm sibling container
All checks were successful
ci / test (pull_request) Successful in 4m57s
node:20-bullseye (the amd64 job image) is EOL; apt-get there fails on
expired/404 security indexes. Run JDK 17 + SDK/NDK + cargo-ndk inside
eclipse-temurin:17-jdk-bookworm via docker create + stdin tar, matching
the Rust CI pattern. Fetch a static docker CLI if the job image lacks
one. On publish failure after creating a tag, delete that tag so the
next run retries the same version (first release stays v0.1.0).
2026-09-12 01:14:43 -04:00
3e72f40e0e Merge pull request 'fix(ci): Android APK build in bookworm sibling container' (#29) from wt/t_87d7245b into main
All checks were successful
ci / test (push) Successful in 3m40s
Reviewed-on: #29
2026-09-12 05:13:46 +00:00
Sirius DevOps
898b943485
ci(release): share ci.yml concurrency; make cleanup actually delete
Some checks failed
ci / test (pull_request) Failing after 2m51s
Use onionwire-ci-pi so cargo release builds cannot race tests on the
Pi's shared /target volume. Strip PAT newlines in cleanup and treat
publish skipped/failed as the signal to delete the tag this run created,
so the next run retries the same version instead of advancing.
2026-09-12 01:09:46 -04:00
Sirius DevOps
951439d7e2
ci(release): install static docker CLI on amd64 jobs
All checks were successful
ci / test (pull_request) Successful in 3m48s
The docker-amd64 runner's node:20-bullseye job image has no docker
binary (Pi jobs get one via the host socket mount). Fetch the upstream
static CLI so the rust:1.91-bookworm sibling build can run.
2026-09-12 01:03:22 -04:00
4a248f5b73 Merge pull request 'feat(android): auto-publish signed APK and AAR from CI' (#26) from wt/t_87d7245b into main
All checks were successful
ci / test (push) Successful in 3m8s
Reviewed-on: #26
2026-09-12 04:59:41 +00:00
Sirius DevOps
c8693d2006
fix(ci): android-release HTTPS apt mirrors and dry_run input
All checks were successful
ci / test (pull_request) Successful in 7m9s
dind timed out on http://deb.debian.org:80. Flip sources to HTTPS.
Do not let workflow_call's boolean false clobber dispatch dry_run.
2026-09-12 01:00:42 -04:00
Sirius DevOps
1c4aaefb01
feat(android): auto-publish signed APK and AAR from CI
Some checks failed
ci / test (pull_request) Failing after 3m13s
Push to main that touches android/** builds a release APK + SDK AAR on
docker-amd64, verifies size/ABI/signature, and create-or-joins the Forgejo
release. Version is latest v*.*.* patch+1, or v0.1.0 when there are no tags.
Release signing uses repo secrets (ANDROID_KEYSTORE_*), not the debug key.
2026-09-12 00:54:17 -04:00
Sirius DevOps
58e10a0bc0
ci(release): honor dry_run input and send JSON Content-Type
Some checks failed
ci / test (pull_request) Failing after 4m1s
Forgejo dispatch passes string inputs; boolean dry_run stayed false and
tried to mint v0.1.0. Strip PAT newlines so Authorization does not eat
the next header (422 Empty Content-Type).
2026-09-12 00:55:18 -04:00
Sirius DevOps
111b95c3ae
ci(release): auto-tag and publish aarch64+x86_64 on main
Some checks failed
ci / test (pull_request) Failing after 2m16s
Drop the tag-push trigger so API-created tags cannot start a second run.
Core paths on main (or workflow_dispatch) mint the next v*.*.* tag
(v0.1.0 when none exist), build both arches in CI, and publish one
release. dry_run builds without tagging. Fail closed on empty assets.
2026-09-12 00:52:46 -04:00
Sirius DevOps
bfd28fce6b
fix(ci): serialize Pi jobs; valid XMR fixture after F4
All checks were successful
ci / test (pull_request) Successful in 2m49s
Overlapping Actions used a fixed docker name onionwire-ci (Conflict)
and OOM-killed with 137. Unique run_id names + one-at-a-time
concurrency. F1 ingest test still used 8+B*94 which F4 checksums reject.
2026-09-10 20:12:41 -04:00
Sirius DevOps
ef78be4035
fix(release): refuse to publish 0-byte assets + log on-disk sizes
Some checks failed
ci / test (push) Has been cancelled
Run 309 reported success but uploaded 0 bytes for both aarch64 assets
(a 0.85s 'upload' of an 18MB file). The Pack step had just listed
18258736 bytes and sha256sum -c'd OK, so the failure is in the handoff,
not the build.

- publish-release.sh now fails loudly on a 0-byte asset instead of
  publishing a release that silently breaks every download
- the workflow logs pwd, GITHUB_WORKSPACE, ls -l dist/ and the byte count
  of each dist file immediately before publishing

Ruled out: the api_curl retry wrapper. Reproduced from inside a
node:20-bullseye container (curl 7.74, same as CI) — wrapper and plain
curl both uploaded 994 bytes correctly through Cloudflare.
2026-09-10 14:20:45 -04:00
Sirius DevOps
9441bccf58
fix(release): tooling checkout so old tags can publish; never move a tag
Some checks failed
ci / test (push) Successful in 5m46s
release / aarch64 (push) Failing after 5m46s
The dispatched build of v0.1.1 kept failing at publish with
'scripts/publish-release.sh: No such file or directory' — the workflow is
read from the dispatch ref (main) but the workspace was the v0.1.1 tag,
whose tree predates scripts/ and .forgejo/.

- second checkout of the workflow's own ref into .ci-tools; publish runs
  .ci-tools/scripts/publish-release.sh (and .ci-tools/scripts/release-body.md)
- exclude ./.ci-tools from the build context tar
- target_commitish is now opt-in in publish-release.sh and only set for a
  push event, so a re-publish can never move an existing tag

Verified locally end-to-end against a throwaway tag: create, idempotent
re-run (stale assets deleted + replaced), public download, sha256sum -c,
--version. Test release and tag deleted afterwards.
2026-09-10 13:58:46 -04:00
Sirius DevOps
154bed7823
fix(ci): clippy clean on tests/hs.rs + pin step cwd to GITHUB_WORKSPACE
Some checks failed
ci / test (push) Successful in 3m47s
release / aarch64 (push) Failing after 5m25s
Two separate breakages from the first green-ish CI run:

1. tests/hs.rs asserted on a constant, which clippy rejects under
   -D warnings (clippy::assertions_on_constants) because the compiler
   folds the assert away. Compare through a runtime binding instead.

2. The release workflow built the aarch64 binary fine (13m02s, verified
   ARM ELF) but the publish step died with:
       /var/run/act/workflow/3: line 6: scripts/publish-release.sh: No such file or directory
   run: steps execute with act's cwd, not the repo root, so relative
   paths miss. Pin every run step with cd "${GITHUB_WORKSPACE}" (the
   pattern the osint-dashboard workflow already relies on).

Verified locally before pushing: cargo test 41 passed, cargo clippy
--all-targets -- -D warnings clean.
2026-09-10 13:50:57 -04:00
Sirius DevOps
a278e71627
ci: install the clippy component in the rust image
Some checks failed
ci / test (push) Has been cancelled
rust:1.91-bookworm ships without clippy, so the clippy step died with
'cargo-clippy is not installed for the toolchain' after all 39 tests
passed. Also pushes the watcher fix (1=success 2=failure in Forgejo job
statuses, not action_run's numbering).
2026-09-10 13:24:59 -04:00
Sirius DevOps
19af4cc768
ci: build on rust 1.91 — the locked Arti 0.46 crates require rustc >= 1.91
Some checks failed
ci / test (push) Failing after 9m2s
The rust:1.87-bookworm job image failed every builder step with
'tor-*@0.46.0 requires rustc 1.91 ... either upgrade rustc or select
compatible dependency versions'. Cargo.toml declared rust-version 1.87,
which was simply wrong: cargo 1.87 could not even resolve the lockfile.

- rust-version 1.87 -> 1.91 (README requirement text too)
- RUST_IMAGE rust:1.87-bookworm -> rust:1.91-bookworm in ci and release
2026-09-10 13:14:55 -04:00
Sirius DevOps
e7c0b98a2b
ci(release): build the dispatched tag, not the dispatch ref
Some checks failed
ci / test (push) Failing after 21s
Without this a workflow_dispatch re-publish would have built main and
attached a binary whose --version did not match the release tag.
2026-09-10 13:12:39 -04:00
Sirius DevOps
91fd9601b8
ci: Forgejo-native ci + release workflows
Some checks failed
ci / test (push) Failing after 1m6s
The GitHub workflows could never run on this instance: jobs asked for
ubuntu-24.04 runners (the Pi runner only registers the 'docker' label, so
every job sat in waiting), and release.yml published to github.com, which
is not a remote of this repo.

- .forgejo/workflows/ci.yml  — cargo test + clippy on the 'docker' label,
  Rust work in a rust:1.87-bookworm sibling container (aarch64 native)
- .forgejo/workflows/release.yml — on v*.*.* tags, build aarch64, strip,
  sha256, publish to the Forgejo release; workflow_dispatch takes a tag
  to re-publish
- scripts/publish-release.sh — idempotent create-or-update release +
  asset upload via the Forgejo API (replaces same-named assets)
- scripts/build-release-local.sh — x86_64 path (no x86_64 runner exists)
- scripts/release-body.md — release notes template (@TAG@ substituted)
- README: install URLs -> Forgejo, accurate maintainer release procedure
- remove .github/workflows/*
2026-09-10 13:10:56 -04:00