Commit Graph
17 Commits
Author SHA1 Message Date
FredApps fa34e3106d fix(freebsd): preserve and isolate cross-target Cargo caches 2026-11-19 03:42:06 +01:00
Martin Ball 59d1ecc4ea Fix shared cache save policy and target paths (#253)
Disable Rust cache saves after failed runs and resolve CARGO_TARGET_DIR relative to the checkout. Use dated FreeBSD cache entries and skip a matching same-day save. Keep inherited-target tests independent of the caller environment.

Contributor: @benandez.

Validated with the passing hosted test job, 95 focused passes plus one existing csh skip, and four inherited-target tests. Native Windows/FreeBSD VM and live cache-service execution were not claimed.
2026-11-15 19:19:40 -06:00
FredApps 7d19a7f5e4 release.yml: a publish input publishes a complete draft at the end of the run (#209)
* release.yml: a publish input publishes a complete draft at the end of the run

Part E of the faster-release plan: no one waits by the run to publish. Only on the release
branch, not in a dry run, only when no build job failed (the job already requires that) or was
cancelled, and only when the draft has at least as many assets as the last published release, so
a skipped build job can't publish an incomplete release. Off by default; apps opt in.

* publish: compare with the most recently published release, and say why in the summary

gh release list orders by creation, so the newest-created release was the baseline; an older
draft published later would have been missed. Every refusal now also writes its reason to the
job summary, not only an error annotation.

* tests: publish doesn't change the FreeBSD build, so it stays out of the cache key
2026-11-13 14:09:41 +01:00
FredApps 293de72429 release.yml: a FreeBSD cache a later release can restore, with the aarch64 cross output (#216)
The release FreeBSD jobs keyed their Cargo cache on toJSON(inputs), and
contributors-artifact is contributor-snapshot-<run id>-<attempt>, so every run
wrote an entry no other run could restore: on 11 Nov every release built FreeBSD
cold. The key now holds only the inputs that change the FreeBSD build (app name,
architecture, craft-fonts ref, FreeBSD release); dry-run is left out too, so a dry
run warms the cache a release restores. A test makes every new input pick a side.

The aarch64 job cross-compiles, and Cargo writes that output to
target/aarch64-unknown-freebsd/release, which the cache action never saved: only
the host build scripts in target/release were kept. The action takes the triple as
a new target input and saves and restores that directory too.
2026-11-12 07:25:29 +01:00
Dylan M. Taylor 15058dc71e ci: use StepSecurity's maintained actions (#206)
* ci: use StepSecurity's maintained actions

Each third-party action that StepSecurity publishes a secure drop-in
replacement for now uses that replacement, pinned to a commit with its
version as a comment. Versions follow what we used: the newest
StepSecurity release in the same major, or the closest major they
publish. dtolnay/rust-toolchain refs that named a toolchain (stable,
nightly, 1.76) become the replacement's `toolchain` input.

* tests: find the FreeBSD VM, SonarCloud scan and install-action steps by their StepSecurity names
2026-11-11 14:55:40 -05:00
Saadi 11013609b1 fix(freebsd-cache): fall back to a compatible cache when manifests move (#41)
The identity step hashed the caller's source hash into the cache prefix and
restore-keys only matched that prefix, so any revision that touched Cargo.toml,
Cargo.lock, build.rs, .cargo, rust-toolchain or packaging/ started from an
empty cache. Releases bump a version in the manifests, and PRs that change a
dependency do too. Issue #33 records the consequence on the aarch64 leg:
compiling ~260 dependency crates takes 4h32m under emulation, and 93 PR runs
were cancelled at the 300-minute limit with 0 passing.

Keep the exact key as the primary match and add a second restore key that pins
only what decides artifact compatibility: the guest toolchain and packages, the
serialized configuration and the profile. Cargo's fingerprints still reject
stale artifacts, so restoring a previous revision only saves work.

Bump the cache namespace to v3 because the key layout changed. Existing v2
entries are not readable through the new prefixes, so the first run after this
merge starts cold, as for any namespace bump.

Refs #33, #39
2026-10-22 15:00:48 -04:00
ZuujisandClaude Opus 5.5 50a6bc4968 ci(release): cross-compile FreeBSD aarch64 in the x86_64 VM (#50)
* ci(release): cross-compile FreeBSD aarch64 in the x86_64 VM

The FreeBSD release job built aarch64 in an emulated aarch64 guest, which
ran into the 300-minute limit for most apps, so aarch64 was dropped from
releases (#39). #49 fixed the same problem in freebsd.yml by cross-compiling
in the KVM-accelerated x86_64 guest; this ports that setup to release.yml.

The release VM is now always x86_64. For aarch64 it pins the quarterly
package branch, installs lang/rust and runs the same "Set up the aarch64
cross toolchain" step as freebsd.yml; a test keeps the two copies identical.
The build step sets the version before loading the cross environment, so
xtask still builds for the guest. The built-in packager reads binaries from
target/<triple>/release, and the job fails if an archive does not match the
matrix architecture.

aarch64 stays opt-in through the new freebsd-architectures input (default
'["x86_64"]'): each app's package.sh still reads target/release and names
its archive after uname -m, so it must honor CARGO_BUILD_TARGET first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci(release): reject unsupported FreeBSD architectures before the VM starts

The guest is always x86_64 and only aarch64 is cross-compiled, so any other
freebsd-architectures value would build x86_64 binaries and the fallback
packager would label them with that value. Check matrix.arch on the host
first and fail for anything but x86_64 and aarch64.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 14:58:24 -04:00
Zuujis a4acae8e3a ci(freebsd): cross-compile aarch64 in the x86_64 VM instead of emulating it (#49)
The aarch64 leg booted an emulated aarch64 guest, which compiles about 23
times slower than the KVM-accelerated x86_64 one, so it ran into the
300-minute limit in every caller (#33). GitHub's Arm runners cannot help:
none of them exposes nested virtualization.

Both legs now boot an x86_64 guest. The aarch64 leg pins the quarterly
package branch, installs lang/rust, copies the aarch64 standard library from
the aarch64 lang/rust package of the same version, builds an arm64 sysroot
from base.txz and the GUI library packages, and builds the workspace with
CARGO_BUILD_TARGET=aarch64-unknown-freebsd through base clang and lld. Stable
Rust, no -Zbuild-std.

The cross leg compiles every target, including the tests, but cannot run them
or package.sh, which builds for the guest's own architecture.
2026-10-22 01:44:01 -04:00
Brandon ThomasandClaude Opus 5.5 39962f26c3 Release: drop FreeBSD aarch64 until it can be built in time (#40)
The emulated aarch64 VM takes over 5 hours for most apps, so the job is
cancelled at the limit. GitHub's ARM64 runners have no KVM, so they do not
help. Releases ship FreeBSD x86_64 only until #39 is fixed.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 08:41:36 -04:00
skylar taylor-barrick f49277a3d0 fix(ci): let GitHub manage FreeBSD cache storage limits 2026-10-18 22:46:35 -06:00
skylar taylor-barrick 2f3b0f5e83 test(ci): make empty-profile regression independent of filesystem 2026-10-18 22:07:57 -06:00
skylar taylor-barrick c347980c9f fix(ci): retain untouched profiles and isolate workflow fixtures 2026-10-18 22:01:49 -06:00
skylar taylor-barrick f3d700ca15 fix(ci): support FreeBSD login shells and prioritize artifact delivery 2026-10-18 21:45:22 -06:00
skylar taylor-barrick 0efb69ba2a fix(ci): preserve bounded caches and tolerate absent Cargo sources 2026-10-18 21:30:50 -06:00
skylar taylor-barrick 69e4aa9c2c fix(ci): bound FreeBSD caches and recover from cache failures 2026-10-18 21:25:32 -06:00
skylar taylor-barrick 0156a114e8 fix(freebsd): keep cache-save failures from blocking package delivery 2026-10-18 19:10:19 -06:00
skylar taylor-barrick adcd8bf032 ci(freebsd): keep ARM coverage outside default PR checks and cache Cargo builds 2026-10-18 18:59:20 -06:00