mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-06 19:01:54 +00:00
GitHub cancels a job queued for 24h. A line starting swarm, compose and host at once queues its whole matrix in one go, so with more roles than runner slots the tail waits past that cut and dies unrun -- 54 of 241 jobs in run 30937913632. Deploy the modes one after the other instead, heaviest first, which restarts the queue clock per mode. cli.meta.ci.sequencing counts a line's matrix jobs on the row basis the discover steps use and serialises above INFINITO_CI_SEQUENTIAL_THRESHOLD; below it the modes still start together, so a small diff pays no wall-clock for this. A needs: edge is static, so both layouts exist as jobs and the decision skips one. Their conditions are structurally asserted, not evaluated: ten near-identical if expressions invite a copied sentinel or a missing chain edge, and both failures are silent at runtime. mode_fail_fast stops a serial line at its first failed mode, on by default. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Shared Utilities (utils/)
This directory contains shared Python helpers used by custom modules and plugins.
Purpose
Use utils/ for reusable code that should not be duplicated across:
library/modules,plugins/action/,plugins/filter/,plugins/lookup/.
Typical shared utilities:
- API clients,
- validation/conversion helpers,
- path and configuration helpers,
- cross-plugin/module domain logic.
- Shared HTTP(S) connection handler for multiple modules.
- Common validation or transformation functions for user input.
- Utility functions for interacting with Docker, LDAP, etc.
- Grouped helper packages such as
utils/domains/for related domain logic.
Design Guidelines
- Keep helpers focused and composable.
- Avoid side effects during import.
- Prefer explicit function/class APIs over implicit globals.
- Keep dependencies minimal so modules/plugins stay lightweight.
Example Import
from utils.domains.primary_domain import get_primary_domain
What Does Not Belong Here
- Standalone executable modules (put in
library/). - Ansible plugin entrypoints (put in
plugins/*).
References
- Module utilities: https://docs.ansible.com/ansible/latest/dev_guide/developing_module_utilities.html
- Plugin development: https://docs.ansible.com/ansible/latest/dev_guide/developing_plugins.html