Commit Graph
20 Commits
Author SHA1 Message Date
evangelostsak 95cfc8b7bd fix(ansible): profile every task, not the slowest 300
The callback truncated its summary, so a deploy's per-task table was
only ever its own top 300. Comparing two transports needs the tasks the
truncation dropped, and 'all' is a value the plugin handles explicitly.
2026-10-07 09:54:32 +02:00
Alejandro Roman a390fea9e9 fix(swarm-stalwart): fix CI issues, cmments mapache 2026-09-28 18:23:16 +04:00
Alejandro Roman fadf36e0a6 fix(swarm-stalwart): fix CI issues 2026-09-26 18:05:56 +04:00
kevinveenbirkenbachandClaude Opus 5 bbfd82f893 fix(profiling): let the task recap reach past the twenty slowest
ansible.cfg enables profile_tasks, whose output_limit defaults to 20. On a deploy round of this size the recap therefore cut off at 66.07s and printed nothing below, so a role whose cost is spread over many cheap tasks could not be attributed at all: in run 33828309745 that left 22.7 of sys-svc-compose 51.9 minutes unexplained, and the same blind spot covers web-app-nextcloud and web-app-keycloak almost entirely.

The callback accepts all, which disables the cap, but the recap prints one line per task execution and pass 1 alone ran over 7500 of them. Since the Actions worker dies silently on ENOSPC while writing its own logs, which is why utils/tests/swarm/matrix.py aborts a step at DISK_FLOOR_MB, the limit stays bounded at 300: about 600 extra lines across both passes.

Measured with a 30-task play: 30 recap entries with this config, 20 with the upstream default forced through PROFILE_TASKS_TASK_OUTPUT_LIMIT. The lint pins the setting so removing the section cannot silently restore the truncation.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-04 16:45:44 +02:00
kevinveenbirkenbachandClaude Opus 4.7 182260d6ee feat(ci): surface top-N Ansible role runtimes in deploy job summary
Enable the ansible.posix.profile_roles callback alongside profile_tasks
so every deploy run emits a per-role runtime block. Each test-deploy
workflow now writes the Ansible log to ANSIBLE_LOG_PATH and runs a new
post-step that parses the block, aggregates duplicate role entries,
sorts by total duration, and writes the top-N (default 20, override via
INFINITO_PROFILE_TOP_N) as a Markdown table to $GITHUB_STEP_SUMMARY so
the table appears on the Actions job overview page. Includes 15 unit
tests covering aggregation, ANSI stripping, task/total filtering,
env-knob handling, and step-summary writes.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-21 17:57:14 +02:00
kevinveenbirkenbachandClaude Opus 4.7 16e290c9ed refactor(library): move database_query module from plugins/modules to library
The first reuse-kept deploy after introducing `database_query` failed
with `couldn't resolve module/action 'database_query'`: ansible only
searches for custom modules along the `library` config path, and the
module had landed under `plugins/modules/` (collection-style layout)
without that path being registered in ansible.cfg.

Realign with the repo's existing convention — `library/cert_check_exists.py`
and `library/docker_bridge_gateway.py` are already there — by relocating
the module to `library/database_query.py`. Make the search path explicit
in ansible.cfg (`library = ./library`) instead of relying on ansible's
implicit playbook-adjacent discovery, so the resolver stays predictable
across CLI / playbook / role-include entry points.

Move the unit suite into `tests/unit/library/` alongside the moved
module, fix the doc-string reference in the lint guard that points
callers at the canonical module location, and drop the now-empty
`tests/unit/plugins/modules/` package.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-15 21:52:34 +02:00
kevinveenbirkenbach 189267496d Rename module_utils package to utils 2026-03-21 02:05:39 +01:00
kevinveenbirkenbach c6f5fdea15 refactor plugins layout and migrate uri calls to uri_retry 2026-03-19 01:41:07 +01:00
kevinveenbirkenbach 97f5b2ade8 fix(ansible): switch stdout callback to builtin default with yaml result format
Replace removed community.general.yaml callback with ansible.builtin.default
and enable YAML output via callback_result_format to stay compatible with
ansible-core >= 2.13 and community.general >= 12.

https://chatgpt.com/share/69615ae5-bb70-800f-8227-a4ad389dfd32
2026-01-09 20:45:16 +01:00
kevinveenbirkenbach aa28b08d7b ansible: restore task timing output via callbacks_enabled
Re-enable timer and profile_tasks by switching from deprecated
callback_whitelist to callbacks_enabled, ensuring task and total
runtime are shown again with the yaml stdout callback.

https://chatgpt.com/share/695bee3b-c7b8-800f-ba1b-14edd4f6fe24
2026-01-05 18:00:29 +01:00
kevinveenbirkenbach d7a5c8d9ca Added YAML Output for Ansible
https://chatgpt.com/share/695bb21c-a83c-800f-baae-90ef7442c0b3
2026-01-05 13:44:05 +01:00
kevinveenbirkenbach 897fb8db2d chore(ansible): add local collections support and unify install workflow
- Ignore locally installed Ansible collections directory
- Add install-ansible target using requirements.yml
- Split install into venv, python, and ansible steps
- Configure ansible.cfg to use local collections and roles paths
- Clean up Makefile PHONY targets and fix test dependency

https://chatgpt.com/share/694731a8-0300-800f-8785-6011e414994b
2025-12-21 00:30:43 +01:00
kevinveenbirkenbach 94f97ed1f3 Refactor: Migrate deprecated Ansible facts to ansible_facts[] syntax
Why:
- Ansible 2.20+ deprecates INJECT_FACTS_AS_VARS and direct usage of top-level ansible_* facts.
- This change updates all affected roles and vars files to the new supported syntax.
- Ensures compatibility with upcoming Ansible 2.24 removal of implicit fact injection.

Conversation reference:
https://chatgpt.com/share/692f639b-1380-800f-9f18-732f7108e9e2
2025-12-02 23:09:46 +01:00
kevinveenbirkenbach 46174125bc Refine deploy CLI, test-deploy workflow and Ansible output
Changes:
- Update GitHub Actions test-deploy workflow to run three staged deploys (normal+debug, reset+debug, async) using inventory-generated vault password files.
- Switch Ansible stdout_callback to ansible.builtin.default and enable YAML-style result_format via callback_default.
- Refactor cli/deploy.py: typed run_ansible_playbook(), structured MODE_* handling, better error reporting, and preserved vault/interactive behaviour.
- Add unit tests for deploy CLI (bool parsing, MODE_* loading, dynamic args, validation, and ansible-playbook command construction) under tests/unit/cli/test_deploy.py.

Context: see ChatGPT conversation on 2025-12-02: https://chatgpt.com/share/692f1035-6bc4-800f-91a9-342db54e1a75
2025-12-02 20:25:26 +01:00
kevinveenbirkenbach 01ea9b76ce Enable pipelining globally and modernize SSH settings
- Activated pipelining in [defaults] for better performance.
- Replaced deprecated 'scp_if_ssh' with 'transfer_method'.
- Flattened multi-line ssh_args for compatibility.
- Verified configuration parsing as discussed in https://chatgpt.com/share/68efc179-1a10-800f-9656-1e8731b40546
2025-10-15 17:45:16 +02:00
kevinveenbirkenbach 2067804e9f Solved ansible multiplexing auth bug 2025-08-12 04:23:45 +02:00
kevinveenbirkenbach 918355743f Updated ansible.cfg for better performance and tracking 2025-08-11 21:00:33 +02:00
kevinveenbirkenbach cfeb8a5bf8 General optimations and refactorings in preparation for simpleicon role implementation 2025-07-06 14:54:31 +02:00
kevinveenbirkenbach 37dcc5f74e In between commit domain restruturing 2025-05-19 17:17:57 +02:00
kevinveenbirkenbach 567622f523 Solved OpenProject build bug 2025-04-16 00:56:29 +02:00