Files
computer-playbook/docs/contributing/environment/hardware.md
T
kevinveenbirkenbachandClaude Opus 4.7 9a578952c3 feat(env): SPOT env-pipeline + INFINITO_* namespace
Replace 8 bash env modules with a single Python generator
(cli.meta.env) that materialises env/static.env + runtime context
into a gitignored .env. Each variable lives in its own handler
under utils/env/handlers/; defaults carry inline one-line `# ...`
comments.

Rename to the INFINITO_* schema:
- workflow inputs: APPS, SERVICES_DISABLED, CMD, DEBUG, WHITELIST,
  BUNDLES, FULL_CYCLE, VARIANT, RUN_FLAGS, LIMIT_HOST, PARALLEL
- inventory: INVENTORY_DIR / INVENTORY_FILE / HOST_VARS_FILE,
  PW_FILE -> INVENTORY_PASSWORD_FILE
- venv: VENV_BASE / VENV_FALLBACK / VENV_NAME
- new SPOT defaults: COMPILE_SILENCE, CONTAINER_NO_CA,
  WAIT_HEALTH_TIMEOUT_S, PACKAGE_CACHE_FRONTEND_INIT_IMAGE,
  promoted IMAGE_TAG from GHA-only to general passthrough

compose.yml hardening:
- inline \${VAR:-default} removed; strict \${VAR:?...} everywhere
- new integration lint blocks regressions

Tooling:
- scripts/install/all.sh owns the stamp-file install logic
  (Makefile target delegates)
- scripts/meta/env/load.sh is the single shell entry point;
  8 bash modules deleted
- new shell lint: no INFINITO_* defaults outside env/static.env

Tests:
- 93 new unit tests for utils/env/{builder,parser,runtime,writer}
- restructure tests/lint into repository/ (file-content rules) vs
  filesystem/{shell,python,env}/ (filesystem-shape rules)
- drift + smoke integration tests against the generator

Docs:
- variables.md is now a pointer; per-variable docs live next to
  the key in env/static.env / env/ci.env
- compose.yml.md drops the Default column

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 20:40:34 +02:00

4.9 KiB

Manage Low-Hardware Resources

Use this guide when you work on a machine with limited CPU, RAM, or disk.

Goal Hardware

A practical long-term target is:

  • 64 GB RAM
  • a swapfile about the same size as RAM
  • an external SSD with more than 500 GB if your computer does not have sufficient storage space
  • enough room for Docker images, volumes, build cache, and local repositories

If disk space is tight, you SHOULD move Docker data, caches, and your working directory to the SSD.

On Linux, you MAY move Docker to a different data path:

{
  "data-root": "/mnt/ssd/docker"
}

Then restart Docker:

sudo systemctl restart docker

The mount MUST be available before Docker starts. Otherwise the daemon may fall back to the system drive or fail to start cleanly.

On macOS and Windows, you MUST use Docker Desktop settings instead of daemon.json.

A same-size swapfile helps absorb memory spikes on Linux. On Windows and macOS, you SHOULD keep enough free disk space available for virtual memory and local caches.

Load Only What You Need

For a broad stack like the Community Hub, you SHOULD start only the services you actually need. If you are working on Discourse, you do not need Mastodon, Pixelfed, PeerTube, or Friendica in the same session.

You MAY set the INFINITO_SERVICES_DISABLED environment variable before creating the inventory to disable services automatically across all applications without editing any file:

make deploy-fresh-purged-apps INFINITO_APPS=web-app-discourse INFINITO_SERVICES_DISABLED="matomo"

This sets enabled: false and shared: false for every listed service in the generated inventory. See variables.md for details.

Service Optional What it provides Effect of disabling Safe to disable when
matomo 🟢 Analytics tracking No usage statistics collected. Usually no functional impact. You are not testing analytics integration
oidc 🟠 Single sign-on via Keycloak App falls back to local login You are not testing SSO/OIDC flows
ldap 🟠 Central user directory via OpenLDAP App uses its own local user store You are not testing LDAP/user sync
css 🟠 Custom theming/branding stylesheet App uses its default upstream theme You are not testing visual customization
logout 🟠 Shared logout endpoint across apps Single sign-out does not propagate You are not testing cross-app logout
dashboard 🟠 Central navigation hub App is not reachable via the dashboard You access the app directly by URL
redis 🔴 In-memory cache and session store Caching and queuing are disabled The app does not require sessions or queues (rarely safe)
database 🔴 Shared relational database (MariaDB/Postgres) App cannot persist data Never disable. Required by almost every app.

Legend:

  • 🟢 Safe to disable. Usually no functional impact.
  • 🟠 Optional. Can be disabled, but reduces functionality.
  • 🔴 Required. MUST NOT be disabled.

This is a development profile, not a production target.

When running Playwright tests, you SHOULD only disable matomo. All other services (🟠) are REQUIRED for full end-to-end scenario coverage. Disabling them will cause Playwright tests that depend on SSO, LDAP, theming, or logout flows to fail or produce incomplete results.

Test Smarter

On small machines, you SHOULD limit validation to the role you are touching.

For Discourse, start with:

make deploy-fresh-purged-apps INFINITO_APPS=web-app-discourse INFINITO_SERVICES_DISABLED="matomo"

If the local inventory and stack already exist, you SHOULD reuse them:

make deploy-reuse-kept-apps INFINITO_APPS=web-app-discourse INFINITO_SERVICES_DISABLED="matomo"

You SHOULD use make deploy-fresh-kept-all only when you need broad coverage and have enough time and resources.

Measure Before You Delete

You SHOULD check what is actually consuming space before cleaning up:

make system-disk-usage

That makes it easier to see whether the real issue is Docker, journald, a package cache, or project state.

Cleanup

Run the full cleanup pass to free disk and memory:

make system-purge

On WSL2 or Windows, you MUST pass the additional flag to also configure and run the Windows Disk Cleanup profile. Windows manages its own system caches independently from Linux and Docker:

make system-purge PURGE_WINDOWS_CLEANMGR_SETUP=true

Further Information

Discussion

Discuss this topic in the related forum article.