utils.env.handlers.infinito package

Subpackages

Submodules

utils.env.handlers.infinito.cache_stack module

INFINITO_CACHE_STACK: whether the pull-through cache stack should run.

utils.env.handlers.infinito.cache_stack.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.container module

INFINITO_CONTAINER: compose service container name derived from INFINITO_DISTRO. Always overrides whatever the static-env default was.

When COMPOSE_PROJECT_NAME is set to a non-default value (e.g. “runner-1” for self-hosted runner instances), the project name is incorporated so runner CI jobs don’t conflict with the always-running dev container.

utils.env.handlers.infinito.container.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.distros module

INFINITO_DISTROS: every distro id declared in meta/distros.yml.

The key carries no static default; it is generated here so the shell and CI side of the project read the same SPOT the Python side does.

utils.env.handlers.infinito.distros.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.docker_volume module

INFINITO_DOCKER_VOLUME: GHA-side override pointing at the runner’s large-disk mount.

utils.env.handlers.infinito.docker_volume.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.ghcr_mirror module

INFINITO_GHCR_MIRROR: whether image references are rewritten to the GHCR mirror.

utils.env.handlers.infinito.ghcr_mirror.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.image module

INFINITO_IMAGE: fully-qualified GHCR image reference assembled from owner, repo, distro and tag (GHA-only).

utils.env.handlers.infinito.image.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.image_repository module

INFINITO_IMAGE_REPOSITORY: lowercased repository name resolved from scripts/meta/resolve/repository/name.sh (GHA-only).

utils.env.handlers.infinito.image_repository.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.inventory module

Inventory resolution: one helper-script call yields INFINITO_INVENTORY_DIR, INFINITO_INVENTORY_FILE and INFINITO_INVENTORY_HOST_VARS_FILE. Kept together because the latter two are derived path-joins on the first.

utils.env.handlers.infinito.inventory.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.ip_range module

INFINITO_IP_RANGE: the dynamic IPAM pool of the compose stack’s bridge.

Docker hands every container that joins the bridge without an ipv4_address the lowest free address of the pool. Worktree stacks join the primary’s network as the cache network, so without a pool they took the primary’s static addresses below .128. The pool is the upper half of the final INFINITO_SUBNET; every static address sits in the lower half.

utils.env.handlers.infinito.ip_range.finalize(eb: EnvBuilder) → None
utils.env.handlers.infinito.ip_range.upper_half(subnet: str) → str

Return the upper half of subnet.

Parameters:

subnet – an IPv4 CIDR such as 172.30.0.0/24.

Returns:

The CIDR of its upper half, e.g. 172.30.0.128/25.

utils.env.handlers.infinito.is_wsl2 module

INFINITO_IS_WSL2: true when /proc/version identifies the host as WSL2.

utils.env.handlers.infinito.is_wsl2.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.outer_network_mtu module

INFINITO_OUTER_NETWORK_MTU: MTU of the compose stack’s bridge network.

Derived from the host’s default-route interface MTU so the compose bridge never exceeds the path MTU (TLS handshakes silently drop fragments otherwise). When no default route is readable (agent sandboxes run in a network namespace whose /proc/net/route is empty, while /sys/class/net still shows the host NICs), falls back to the minimum MTU across UP physical interfaces; only if that finds nothing either does the static default from default.env apply.

utils.env.handlers.infinito.outer_network_mtu.apply(eb: EnvBuilder, ctx: BuildContext) → None
utils.env.handlers.infinito.outer_network_mtu.detect_outer_mtu() → str | None

utils.env.handlers.infinito.parent_image module

INFINITO_PARENT_IMAGE: pkgmgr base image reference composed from INFINITO_PARENT_IMAGE_OWNER, INFINITO_DISTRO and INFINITO_PARENT_IMAGE_TAG.

utils.env.handlers.infinito.parent_image.apply(eb: EnvBuilder, ctx: BuildContext) → None
utils.env.handlers.infinito.parent_image.compose(owner: str, distro: str, tag: str) → str

utils.env.handlers.infinito.pull_policy module

INFINITO_PULL_POLICY: GHA-side override – always pull the published image instead of trusting whatever is cached on the runner.

utils.env.handlers.infinito.pull_policy.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.registry_cache_max_size module

INFINITO_CACHE_REGISTRY_MAX_SIZE: registry-cache soft cap (half of free disk at INFINITO_CACHE_REGISTRY_HOST_PATH, floor 1g).

utils.env.handlers.infinito.registry_cache_max_size.apply(eb: EnvBuilder, ctx: BuildContext) → None

utils.env.handlers.infinito.tor_socks_port module

INFINITO_TOR_SOCKS_PORT: node Tor SOCKS port, read from the single source of truth in svc-net-tor’s meta/services.yml (services.tor.ports.local.socks). Keeps shell consumers (e.g. the Playwright rerunner) off a hard-coded port literal.

Stdlib line parse on purpose: env handlers feed the .env generation, which bootstraps fresh hosts before PyYAML exists (canonical pattern: utils/storage/nfs.py).

utils.env.handlers.infinito.tor_socks_port.apply(eb: EnvBuilder, ctx: BuildContext) → None

Module contents

INFINITO_*-key env handlers; one module per owned key.