Repository navigation
Make the pupmod acceptance jobs survive Launchpad PPA outages - #126
Conversation
The acceptance jobs in both pupmod PR Tests templates installed vagrant and vagrant-libvirt from ppa:evgeni/vagrant alone, so a Launchpad outage failed every acceptance job and, through the required 'All checks' status, blocked merging. Ubuntu dropped both packages after 23.10, and the PPA carries vagrant 2.3.7 (the last MPL-licensed release) with a matching vagrant-libvirt. The PPA stays the primary source, wrapped so its outages don't matter: * The PPA's two .debs are kept in the Actions cache, keyed on the Ubuntu codename, architecture and the pinned package versions. On a cache hit the step installs them without contacting Launchpad; their dependencies come from the Ubuntu archive. * add-apt-repository, apt-get update and the download are retried three times, 30s and then 60s apart. * If the PPA is still down, the step installs Vagrant pinned to 2.4.9 from HashiCorp's apt repository and vagrant-libvirt 0.12.2 with `vagrant plugin install`, and emits a warning saying so. The PPA only publishes for noble, and ubuntu-latest is moving to 26.04 (resolute), where the old step fails on the PPA's missing Release file. On a series the PPA doesn't publish for, the step goes straight to the HashiCorp path with a notice. The acceptance block is repo-owned during syncs (preserve_blocks), so a template change to it never reached the fleet. merge_gha_workflows gains a `template_steps` option: inside a preserved job, the steps with those names are replaced by the template's, in template order, where the first of them was. A job with none of them is left alone, so podman-based and acceptance-free modules are unchanged. The new 20261102-vagrant-ppa-fallback config uses it to sync the change. Fixes simp#122 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… default branch - Install Vagrant with simp/github-action-setup-vagrant-libvirt, which restores the PPA's packages from the Actions cache, then tries the PPA, then HashiCorp. It caches every package the PPA provides, unpinned, with the key derived from their file names; refreshes only the PPA's index with --error-on=any; and removes the PPA's sources file directly. - Add vagrant_package_cache.yml, which saves the cache from the default branch, where pull requests can restore it. - merge_gha_workflows template_steps: replace named steps in place, keep comments that belong to the next step, and fail when the template lacks a named step instead of deleting it. - Sync to a repolist of the 36 Vagrant repos only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The action moved from its own repo into simp/gha-workflows, so there is one repo to manage. Pin it at v1.1.0, the release that adds it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The setup action moved out of its own repo and into simp/gha-workflows (simp/gha-workflows#18), so there is one repo to manage. The templates now use |
|
I ran the task from this branch against the live 1. Two repos missing from the repolist
2. The cache workflow while acceptance runs on
|
- pupmods_vagrant_acceptance: add pupmod-simp-rngd (main) and pupmod-simp-simp_authselect, which have the Vagrant step but aren't in pupmods.yaml. - vagrant_package_cache.yml runs on push only when the file itself changes, so it seeds the cache when it lands without a run (that fails during a Launchpad outage) on every merge. Its header says how it is delivered, since it isn't in the pupmod present_action_files. - merge_gha_workflows: template_steps fails when a name matches more than one step in a job instead of replacing both, keeps commented-out keys at a step's key column with the step, and the header documents that preserve_keys still applies to grafted steps. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@hcaballero2 thanks for running it against the live fleet. Addressed in bd824a8: 1. Missing repos: added 2. The cache workflow: we're keeping it (option a). It's a hedge for acceptance jobs on
3. Minor:
Both have specs. |
Fixes #122.
The templates pin simp/gha-workflows
v1.1.0(simp/gha-workflows#18).The pupmod acceptance jobs installed
vagrantandvagrant-libvirtfromppa:evgeni/vagrantalone, so a Launchpad outage failed every acceptance job and, through the requiredAll checksstatus, blocked merging. This keeps the PPA as the primary source and makes the setup survive its outages.Workflow templates
In both
pr_tests.ymltemplates, "Setup libvirt for Vagrant" becomes one step:The
setup-vagrant-libvirtaction in simp/gha-workflows installs from the Actions cache, then the PPA (with retries), then HashiCorp's apt repository plusvagrant plugin install vagrant-libvirt, with a warning that the last is BSL-licensed. simp/gha-workflows#18 has the details. Because the logic lives in gha-workflows, a later fix is a tag bump that Renovate proposes per repo, not a fleet sync. Any other repo with a Vagrant/libvirt acceptance job, including Ruby projects, can use the same step.A pull request can only restore caches saved from its own ref, its base branch or the default branch, so caches saved by pull requests don't help other PRs. The new
vagrant_package_cache.ymltemplate runs the action withcache-only: 'true'from the default branch. It runs twice a week, which also keeps the cache from being evicted after seven days without use, and on a push to the default branch that changes the workflow file, which seeds the cache when it lands. Other pushes don't run it, so merges during a Launchpad outage don't each get a failed run. It runs onubuntu-24.04because the PPA only publishes for noble, so it only helps acceptance jobs onubuntu-24.04; see the next section.Only modules whose acceptance job uses Vagrant get this workflow, so it isn't in the pupmod baseline's
present_action_files. This sync adds it withensure_files, and latermerge_github_workflowsruns refresh it wherever it exists.Ubuntu 26.04 runners
ubuntu-latestis moving to 26.04 (resolute): the 2026-10-27 auditd acceptance run was onubuntu-24.04, and test runs on 2026-11-02 gotubuntu-26.04. The PPA has noresolutebuilds, so the current step fails there. On 26.04 the action goes straight to HashiCorp's Vagrant 2.4.9 with a notice. Pinning the acceptance job toruns-on: ubuntu-24.04would keep the MPL build until GitHub retires that image.runs-onis part of each repo's preserved acceptance block, so that would be a separate change.Syncing to the fleet
jobs.acceptanceis repo-owned during syncs (preserve_blocks), so a template change to it can't reach the repositories.merge_gha_workflowsgains atemplate_stepsoption for steps the template stays authoritative for inside preserved blocks:if:, say).preserve_keysstill applies to grafted steps, so a repo whose Renovate has bumped the action past the template's tag keeps its tag on the next sync. A later template change that needs a new tag together with new inputs reaches each repo as the inputs at sync time and the tag through Renovate.The plan passes
puppetsync.plans.sync.merge_github_workflows.template_stepsthrough.The new
20261102-vagrant-ppa-fallbackconfig uses it, together withensure_filesforvagrant_package_cache.yml.ensure_filesadds the file to every repo in the session, so the config is meant for the newpupmods_vagrant_acceptancerepolist: the 38 pupmods whose acceptance job uses Vagrant. That is 36 frompupmods.yamlpluspupmod-simp-rngdandpupmod-simp-simp_authselect, which aren't in it. Bothlatest.yamlsymlinks point at them. Run against the currentpr_tests.ymlof those 38 and of every repository inpupmods.yaml:After this merges, run
bolt plan run puppetsync config=20261102-vagrant-ppa-fallback repolist=pupmods_vagrant_acceptanceto open the downstream PRs.Testing
rspec(266 examples) and the BoltSpec plan specs (32) pass. New specs cover in-place replacement, steps kept between named steps, steps the job lacks, comments belonging to the next step, commented-out keys belonging to the step, reindentation, jobs without the named steps, the errors for a name the template lacks and for a name two steps share, the repo's tag surviving a later sync, idempotency and the plan passthrough.cache(Launchpad reachable and blocked),ppa, andhashicorp(Launchpad blocked on 24.04, and on 26.04).🤖 Generated with Claude Code