You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Self-hosted incremental-build runner: writable state is shared between runs #5697
The incremental-build job runs as root with read-write access to state that later runs reuse as-is:
the persistent source and build tree volume (ubuntu-2404, including .git)
the Conan home (conan-data-gha)
the runner's reused workspace (/__w)
the ccache store
Anything one run writes there carries into the next PR, push or dispatch run, and into the packages those runs upload. This does not depend on --privileged.
Closing it means not sharing writable state between PR runs, or rebuilding that state from a trusted run. Most of that is a runner-side decision for the admins.
Side note from the same comment: the actions/cache step on ~/.ccache restores nothing, because ccache 4 keeps its store in ~/.cache/ccache unless ~/.ccache already exists.
Proposed plan, to keep incremental-build speed without one PR run writing state the next one trusts:
One trusted writer. Today incremental-build.yml runs only on pull_request, so every PR run writes the shared state the next PR reuses. Add a push: develop (or nightly) run that refreshes the Conan and ccache caches from merged, reviewed code. Only that run writes them.
PR runs read only. PR runs mount the Conan home and the ccache store read-only. container.volumes accepts expressions, so the mount mode can switch on github.event_name.
Throwaway build tree for PRs. PRs build in a fresh tree that is deleted after the run, instead of reusing the persistent ubuntu-2404 checkout (including its .git).
Most of the speed should carry over: a PR usually changes a few files relative to develop, so nearly every compile should come from ccache and the dependencies from the Conan cache. The cost is a CMake configure and full link on every PR run (not measured yet).
Order: the read-only mounts are only enforceable once job containers lose the host Docker socket (#5696) and stop running as root (#5698). Until then a job can work around them. So the sequence is #5696 → #5698 → this change.
Activity
anchapin commentedon Nov 10, 2026
Proposed plan, to keep incremental-build speed without one PR run writing state the next one trusts:
incremental-build.ymlruns only onpull_request, so every PR run writes the shared state the next PR reuses. Add apush: develop(or nightly) run that refreshes the Conan and ccache caches from merged, reviewed code. Only that run writes them.container.volumesaccepts expressions, so the mount mode can switch ongithub.event_name.ubuntu-2404checkout (including its.git).Most of the speed should carry over: a PR usually changes a few files relative to
develop, so nearly every compile should come from ccache and the dependencies from the Conan cache. The cost is a CMake configure and full link on every PR run (not measured yet).Order: the read-only mounts are only enforceable once job containers lose the host Docker socket (#5696) and stop running as root (#5698). Until then a job can work around them. So the sequence is #5696 → #5698 → this change.