mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-29 14:30:52 +00:00
feat(roles): pull custom roles from inventory-declared sources
An inventory group web-app-cst-<name> with applications.<id>.custom: true and
a pinned source {url, version, path} is pulled into roles/ before the play,
read raw (Jinja, Ansible tags and credential URLs refused), placed through a
staging directory under an exclusive lock, and owned by a marker that names
its own directory, so a pull or roles-clean never replaces or removes a
directory it did not place and a failed pull leaves roles/ as it was.
Directory inventories, host lists and non-UTF-8 files behave as Ansible
reads them; generated test deploys pass --skip-pull. make roles-pull,
roles-clean and roles list, INFINITO_EXTRA_MOUNTS for local sources, the
web-app-cst category, the reserved prefix lint and a central
repository_files() that also yields the gitignored custom roles let every
lint scan them like in-tree roles. Supersedes the uncommitted 045 External
Roles draft and reuses its fetch, sync and mount design.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
cb4d340de9
commit
d92375922d
101 files changed
+3731
-248
No files matched your search
@@ -11,6 +11,10 @@ cd "${REPO_ROOT}"
|
||||
RUFF_CACHE_DIR="build/ruff-cache-$(id -u)"
|
||||
export RUFF_CACHE_DIR
|
||||
|
||||
# shellcheck source=scripts/lint/diff/files.sh
|
||||
source "${SCRIPT_DIR}/diff/files.sh"
|
||||
mapfile -t custom_roles < <(lint_custom_roles)
|
||||
|
||||
shfmt -w scripts
|
||||
ruff format .
|
||||
ruff check . --fix
|
||||
ruff format . "${custom_roles[@]}"
|
||||
ruff check . --fix "${custom_roles[@]}"
|
||||
Reference in new issue
Block a user