{"id":19315214,"url":"https://github.com/lxhunter/ansible-lint-rules","last_synced_at":"2026-05-17T18:12:12.157Z","repository":{"id":57180483,"uuid":"124764605","full_name":"lxhunter/ansible-lint-rules","owner":"lxhunter","description":"ansible-lint ruleset for fantastic roles","archived":false,"fork":false,"pushed_at":"2018-11-20T09:51:20.000Z","size":80,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-05-30T10:18:44.800Z","etag":null,"topics":["ansible","ansible-lint","lint","lint-rules","rules"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lxhunter.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-03-11T14:26:30.000Z","updated_at":"2022-04-29T08:19:42.000Z","dependencies_parsed_at":"2022-09-14T03:32:02.846Z","dependency_job_id":null,"html_url":"https://github.com/lxhunter/ansible-lint-rules","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/lxhunter/ansible-lint-rules","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxhunter%2Fansible-lint-rules","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxhunter%2Fansible-lint-rules/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxhunter%2Fansible-lint-rules/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxhunter%2Fansible-lint-rules/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lxhunter","download_url":"https://codeload.github.com/lxhunter/ansible-lint-rules/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxhunter%2Fansible-lint-rules/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265066118,"owners_count":23706062,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ansible","ansible-lint","lint","lint-rules","rules"],"created_at":"2024-11-10T01:05:18.257Z","updated_at":"2026-05-17T18:12:07.123Z","avatar_url":"https://github.com/lxhunter.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ansible-lint\n\nThis is the rule-set I use for my ansible roles. By linting the roles and playbooks you get an standarized setup and use best practices.\n\n## Setup\n\nYou need to have `ansible-lint` installed:\n\n```bash\n$ pip install ansible-lint\n```\n\nCheck the rules out to a directory of your choice:\n\n```bash\n$ hub clone lxhunter/ansible-lint /usr/local/src/ansible-lint\n# or\n$ git clone https://github.com/lxhunter/ansible-lint.git /usr/local/src/ansible-lint\n```\n\n**Pro-Tip:** I use [fresh](https://freshshell.com) for this:\n\n```bash\n$ fresh lxhunter/ansible-lint . --file=/usr/local/src/ansible-lint\n```\n\n## Usage\n\nNow you can lint your playbooks by doing:\n\n```bash\n# just my rules\n$ ansible-lint -r /usr/local/src/ansible-lint/rules playbook.yml\n# or for the standard rule and mine\n$ ansible-lint -R -r /usr/local/src/ansible-lint/rules playbook.yml\n# geek\n```\n\n## Rules\n\n| **Code** | **Message** |\n| --- |:---|\n| **LX1** | **Playbook** |\n| --- | |\n| **LX2** | **Role** |\n| --- | |\n| **LX3** | **Task** |\n| --- | |\n| **LX4** | **General Module** |\n| LX401 | Specific Modules should have owner, group and mode |\n| --- | |\n| **LX5** | **Specific Module** |\n| LX501| Template Module - Template files should have the extension '.j2' |\n\n## Testing\n\n### Setup:\n\nYou need to have `nodemon` installed:\n\n```bash\n$ npm install\n```\n\n### Usage:\n\nI used node for testing:\n\n```bash\nnodemon LX401\n```\n\n## Credits\n\n* [Initial Idea from Will Thames](https://github.com/willthames/ansible-lint)\n* [Learned a lot from shirou and his rules](https://github.com/shirou)\n\n## Contribute\n\n[Tutorial](http://kbroman.github.io/github_tutorial/pages/fork.html)\n\n## Author\n\nAuthor:: [Alexander Jäger](https://github.com/lxhunter)\n\nCopyright 2018\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flxhunter%2Fansible-lint-rules","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flxhunter%2Fansible-lint-rules","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flxhunter%2Fansible-lint-rules/lists"}