Automated summary
Checks Ansible playbook syntax and then runs ansible-lint on the full playbook, a named role, or a specific file.
Strengths
- Chains syntax checking and linting in a single run
- Scopes the lint step based on the argument passed (site.yml, a role under local-roles/, or a file path)
- Activates the project venv automatically and respects the production profile in .ansible-lint
Limitations
- Assumes a fixed layout: venv at ~/.ansible-venv, inventory at tests/inventory, and tests/test.yml
- Does not fix issues; it only surfaces errors and suggests possible fixes
- External roles under roles/ are excluded from linting, so they go unchecked
Run it before committing or executing a playbook to catch syntax errors and Ansible style violations.
Not useful for testing actual playbook runtime behavior, or on projects that don't follow this venv and file layout.
Security analysis
SafeThe skill only activates a local Ansible virtualenv and runs ansible-playbook --syntax-check plus ansible-lint against project files. It does not fetch remote content, exfiltrate secrets, delete files, or disable safety mechanisms. Bash usage is limited to legitimate Ansible validation commands.
No concerns found
How this analysis is madeExamples
Validate the Ansible syntax and run ansible-lint on site.yml.Run ansible-validate on the vagrant role to check it before I commit.Can you syntax-check my playbook and lint local-roles/webserver/tasks/main.yml?name: ansible-validate description: Validate Ansible playbook syntax and run ansible-lint allowed-tools: Bash(source ~/.ansible-venv/bin/activate*), Bash(ansible*), Read, Grep, Glob
Validate Ansible syntax and lint for this project.
Steps
-
Activate the project venv and run syntax check:
source ~/.ansible-venv/bin/activate && ansible-playbook -vv -i tests/inventory tests/test.yml --syntax-check -
Run ansible-lint on the target scope:
- If
$ARGUMENTSis empty, lint the full playbook:source ~/.ansible-venv/bin/activate && ansible-lint site.yml - If
$ARGUMENTSspecifies a role name (e.g.,vagrant), lint that role:source ~/.ansible-venv/bin/activate && ansible-lint local-roles/<role_name>/ - If
$ARGUMENTSspecifies a file path, lint that file:source ~/.ansible-venv/bin/activate && ansible-lint <file_path>
- If
-
Report results clearly:
- If both pass: confirm success
- If either fails: show the errors and suggest fixes based on the project's
.ansible-lintconfig (production profile, see skip_list for tolerated rules)
Notes
- The venv is at
~/.ansible-venv - The lint config is in
.ansible-lint(production profile) - External roles in
roles/are excluded from linting - All working paths are relative to the project root
From the file to a first result
The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.
View the source and supporting filesThis download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.
1. Download the file
Download SKILL.mdFrom the root of a test project, save the file as .skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.
Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.
mkdir -p '.skill-downloads/validate-ansible-syntax-mrwak9hv' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/validate-ansible-syntax-mrwak9hv/download' --output '.skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md.part' && mv '.skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md.part' '.skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md'2. Check prerequisites
Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.
Tools declared by the author (check availability in your agent): Bash(source ~/.ansible-venv/bin/activate*), Bash(ansible*), Read, Grep, Glob
No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.
The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.
3. Load the skill
After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.
Claude Code
test -f '.skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md' && test -s '.skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/ansible-validate' && cp -R '.skill-downloads/validate-ansible-syntax-mrwak9hv' '.claude/skills/ansible-validate'OpenSkills
OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.
Official OpenSkills installationopenskills install './.skill-downloads/validate-ansible-syntax-mrwak9hv'openskills read 'validate-ansible-syntax-mrwak9hv'Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.
For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.
openskills syncManual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.
4. Try a first task
Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:
Read .skill-downloads/validate-ansible-syntax-mrwak9hv/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.
Configure a Chat Channel with SecretRefs
DevOps
Set up chat channels using non-interactive commands, with secrets only as SecretRefs. Covers gather, mutate, repair, and prove steps for reliable delivery.
Investigate ClickHouse CI Failures
DevOps
Investigate a ClickHouse CI failure end-to-end from a PR or S3 report URL. Fetches failed tests, classifies flaky vs real regression, and checks for existing issues/fixes.
Ansible PR Review
DevOps
Reviews an Ansible PR following the project's standardized process, including changelog checks, test coverage validation, and feedback tracking.