Skip to content

Where people and agents ship software together. The open-source git platform for the whole job: issues, agents, checks and deploys to the edge.

Commit

Sandboxes have the command-line tools GitHub's Ubuntu runners have: on flagon-io/automation-lab, the Machine size workflow's `df -h / && nproc && free -g` failed with exit 127 (free: command not found) on both machines, because node:24-bookworm-slim has no procps and the base never installed it. The base's last layer now installs what a workflow written for GitHub reaches for without a setup step: procps, psmisc, lsof, time, less, tzdata, acl; iproute2, iputils-ping, dnsutils, netcat-openbsd, net-tools, rsync; bzip2, lz4, p7zip-full, pigz, brotli; autoconf, automake, libtool, m4, bison, flex, cmake, ninja-build, patchelf; git-lfs (installed system-wide), shellcheck, sqlite3 and the sqlite, bz2 and lzma headers, parallel, tree and python-is-python3. Last, so adding to the list rebuilds nothing above it. The actions guide lists them under "Command-line tools". Base rebuilt and pushed (base-20261015-77b70a7e6383, 4.32 GB unpacked; node:24-bookworm-slim had moved, so Node 24.22.0 and Docker 29.9.1 come with it). Deploy: runner. Checked: every package installed in node:24-bookworm-slim and each tool ran; in the pushed base, as the job user, `df -h / && nproc && free -g` exits 0, with python, rustc, ruby, java and git lfs answering.

G1t-Session:
ses_01m4zvcyhhenraj9ymkb78dheb
syntaqxcommitted Parent84f4718Browse files
3 files+51−110/3 viewed
+18−1
469469
470470 Jobs run in a fresh sandbox each: Debian with Node 24, Python 3, Go, Rust,
471471 Java 21, .NET 8, Ruby 3.3, `build-essential`, `git`, `curl`, `jq`, Docker
472−(with Buildx and Compose) and passwordless `sudo`, in GitHub's layout
472+(with Buildx and Compose), the [command-line tools](#command-line-tools)
473+GitHub's Ubuntu runners have, and passwordless `sudo`, in GitHub's layout
473474 (`/home/runner/work`, `RUNNER_WORKSPACE`, `RUNNER_TEMP`, `RUNNER_TOOL_CACHE`).
474475 `runner.os` is `Linux`. Each step's `GITHUB_ACTION` is its `id`, or
475476 GitHub's name for it: `__run`, `__run_2` and on for `run:` steps,
515516 The headers that gems and .NET need to build native code (`libyaml`,
516517 `libffi`, `zlib`, OpenSSL, ICU) are installed too.
517518
519+### Command-line tools
520+
521+Installed in every sandbox, so a step can use them without installing
522+anything first:
523+
524+| For | Tools |
525+| --- | --- |
526+| Processes and the system | `free`, `ps`, `top`, `kill`, `killall`, `pgrep`, `lsof`, `time`, `less`, `setfacl` |
527+| The network | `curl`, `wget`, `ip`, `ping`, `dig`, `nslookup`, `nc`, `netstat`, `rsync`, `ssh`, `scp` |
528+| Archives | `tar`, `gzip`, `pigz`, `bzip2`, `xz`, `zstd`, `lz4`, `brotli`, `zip`, `unzip`, `7z` |
529+| Building | `make`, `gcc`, `g++`, `musl-gcc`, `pkg-config`, `autoconf`, `automake`, `libtool`, `bison`, `flex`, `cmake`, `ninja`, `patchelf` |
530+| Everything else | `git`, Git LFS, `jq`, `ripgrep` (`rg`), `shellcheck`, `sqlite3`, `parallel`, `tree`, `file`, `gpg`, `python` (Python 3) |
531+
532+Anything else is an `apt-get` away: run `sudo apt-get update` first, as on
533+GitHub.
534+
518535 ### Calling g1t's API from a job
519536
520537 The `gh` command is not installed: it needs a GraphQL API, and g1t's API
+8−8
11 {
2− "image": "registry.cloudflare.com/1e6f2cffa3f445920836e8ebe446bb58/g1t-runner:base-20261014-9cb0c1c3ba59",
3− "digest": "sha256:ac4349507e453028275dd60e5020d577c0d1673e1eac9582e7fcf5e64527119f",
2+ "image": "registry.cloudflare.com/1e6f2cffa3f445920836e8ebe446bb58/g1t-runner:base-20261015-77b70a7e6383",
3+ "digest": "sha256:71c62fecd7d95b6752df42689003a914fdaea0397f90e4bca2a8f8f9ccf1722e",
44 "pushed": true,
5− "inputs": "9cb0c1c3ba5983ad9df9daa5a1b48d2e905a7f065f45cec2527edc30309f4488",
6− "built_at": "2026-10-14T20:06:49.272Z",
7− "size_bytes": 4155695227,
5+ "inputs": "77b70a7e63830cca8f257491f23ee2c70a4a3590975b89d8e1ec1b21d8d18f96",
6+ "built_at": "2026-10-15T13:28:06.296Z",
7+ "size_bytes": 4319969665,
88 "versions": {
9− "node": "v24.21.0",
10− "npm": "11.19.0",
9+ "node": "v24.22.0",
10+ "npm": "11.19.1",
1111 "python": "3.11.2",
1212 "go": "go1.27.1",
1313 "rust": "1.99.0",
1515 "dotnet": "8.0.425",
1616 "ruby": "3.3.12",
1717 "git": "2.39.5",
18− "docker": "29.8.2",
18+ "docker": "29.9.1",
1919 "debian": "12.15"
2020 }
2121 }
+25−2
55 # builds all run in it: git, Node, Python, Go, Rust (with the formatter,
66 # the linter, and the wasm32 and musl targets), Java (Temurin 21), .NET
77 # (SDK 8), Ruby (3.3), the usual build tools, Docker (Engine, Buildx,
8−# Compose).
8+# Compose), and the command-line tools GitHub's Ubuntu runners have.
99 #
1010 # Built and pushed by `node scripts/deploy.mjs build-base` (by hand, or by
1111 # .g1t/workflows/runner-base.yml), which records what it pushed in
1414 # runner builds in seconds. The deploy-to-cloudflare guide explains the two.
1515 #
1616 # Layers go from what changes least to what changes most: the system's
17−# packages, Docker, then Go, then Rust, then Java, .NET and Ruby.
17+# packages, Docker, then Go, then Rust, then Java, .NET and Ruby, then
18+# the command-line tools.
1819 #
1920 # Java and Ruby live in the runner's tool cache (RUNNER_TOOL_CACHE,
2021 # /home/runner/_tool), laid out as the setup actions look for them, so
190191 && chown -R node:node "/home/runner/_tool/Ruby"
191192 ENV PATH=${JAVA_HOME}/bin:/home/runner/_tool/Ruby/${RUBY_VERSION}/x64/bin:$PATH
192193
194+# The everyday tools a workflow written for GitHub's Ubuntu runners
195+# reaches for without installing them first: process and system tools
196+# (`free`, `ps`, `top`, `killall`, `lsof`, `time`), the network's (`ip`,
197+# `ping`, `dig`, `nc`, `netstat`, `rsync`, `ssh`), archives (bzip2, lz4,
198+# 7z, pigz, brotli), autotools, CMake and Ninja, Git LFS, ShellCheck,
199+# SQLite, GNU parallel, `tree`, and `python` as python3. The last layer,
200+# because this is the list most likely to grow: adding to it rebuilds
201+# nothing above it.
202+RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
203+ --mount=type=cache,target=/var/lib/apt/lists,sharing=locked \
204+ apt-get update \
205+ && apt-get install -y --no-install-recommends -o Dpkg::Options::=--force-unsafe-io \
206+ procps psmisc lsof time less tzdata acl \
207+ iproute2 iputils-ping dnsutils netcat-openbsd net-tools rsync \
208+ bzip2 lz4 p7zip-full pigz brotli \
209+ autoconf automake libtool m4 bison flex cmake ninja-build patchelf \
210+ git-lfs shellcheck sqlite3 libsqlite3-dev libbz2-dev liblzma-dev \
211+ parallel tree python-is-python3 \
212+ && rm -rf /var/log/apt /var/log/dpkg.log /var/cache/debconf/*-old \
213+ && git lfs install --system --skip-repo \
214+ && free -h && ps --version && dig -v && cmake --version | head -n1 && git lfs version && shellcheck --version | head -n2
215+
193216 USER node

Comments

Sign in to comment.