vole
Site
Clone
Read only, no credentials:
https://rodent.software/vole.git
Write over SSH with a registered key:
git clone ssh://git@rodent.software/vole.git
Self-hosted forge that lives in your Git repo.
Bound the runner's image storage by age
3455902aa415e013b0e5525e3fd2271a2b1a4e9a · Keenan Nemetz · 3d ago · parent 1a9b3838
Bound the runner's image storage by age The job cache and saved checkouts have caps, but image storage belonged to the runtime and grew two ways: a changed `.vole/images` definition left a permanent new digest tag behind, and a moved registry tag left the previous layers dangling. `--disk-reserve` could not reclaim either; it stops a job instead. Add `--image-max-age` (default 168h; 0 keeps every image), threaded through agent.Options. At startup and on the cache trimmer's beat the runner asks the runtime to prune unused images older than the age, using the filter docker, podman, and nerdctl all express. A job holds an image guard from resolution until its container is up, so a pass that races a lease gives way. A runner with `--container-pull never` keeps every tagged image and prunes dangling layers only, because it may have no network to fetch an evicted image again. A runtime that will not prune is reported once and then left alone: the runner keeps serving. The primitive lives in ci/container so `vole workflow run` can use it later; the policy and its beat live in ci/agent beside the two existing trimmers. closes: 01M8CR0RN88JF14PKAZ0D387ND
docs/runner.md +15−1
| @@ -186,6 +186,20 @@ Concurrent jobs needing the same definition share one build. Waiting jobs keep | |||
| 186 | 186 | their leases alive, and all waiting jobs receive the same build error if it | |
| 187 | 187 | fails. | |
| 188 | 188 | ||
| 189 | Image storage belongs to the runtime, so the runner bounds it by age rather than | ||
| 190 | by bytes: layers are shared and Vole cannot count what removing one tag would | ||
| 191 | free. `--image-max-age` (default `168h`; `0` keeps every image) runs the | ||
| 192 | runtime's own prune at startup and every five minutes. Images older than the age | ||
| 193 | that no container uses are removed, together with dangling layers; an image a | ||
| 194 | container is running from never is. A prune pass that races a job resolving or | ||
| 195 | starting an image gives way to the job. | ||
| 196 | |||
| 197 | With `--container-pull never` the runner keeps every tagged image and prunes | ||
| 198 | dangling layers only, because it may have no network to fetch an evicted image | ||
| 199 | again. Expiring a `vole/image-file:*` tag costs a rebuild, and the rebuild needs | ||
| 200 | the runtime's network to fetch the base image. A runtime that cannot prune is | ||
| 201 | reported once at startup and then left alone; the runner keeps serving. | ||
| 202 | |||
| 189 | 203 | The image build uses the runtime's default network because it may fetch the base | |
| 190 | 204 | image and packages; the job's `network:` does not constrain the build. To build | |
| 191 | 205 | without network access, preload dependencies and configure the runtime host | |
| @@ -204,7 +218,7 @@ review contributor changes to `.vole/images/` before allowing CI. See the | |||
| 204 | 218 | | Job cache | `--cache-size` evicts whole least-recently-written namespaces; active namespaces are deferred | | |
| 205 | 219 | | Containers | Memory, CPU, PID, and tmpfs flags apply per container, so parallel jobs multiply them | | |
| 206 | 220 | | Checkout disk | `--disk-reserve` checks free space once per second and stops a job below the reserve | | |
| 207 | | Images | The OCI runtime owns image storage and writable-layer quotas | | ||
| 221 | | Images | `--image-max-age` prunes unused images older than the age (default `168h`; `0` keeps every image); `--container-pull never` keeps tagged images | | ||
| 208 | 222 | ||
| 209 | 223 | PID and tmpfs limits have non-removable defaults because `/tmp` consumes memory | |
| 210 | 224 | and unbounded process creation can exhaust the host. Set an explicit memory | |