From 69b6c581958cb8a2e537546bbc4a710ec152f370 Mon Sep 17 00:00:00 2001 From: Shatakshi Mishra Date: Mon, 6 May 2024 16:37:31 +0530 Subject: [PATCH] Document valid locations for requirements.yml in the docs (#4134) --- src/ansiblelint/rules/syntax_check.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/ansiblelint/rules/syntax_check.md b/src/ansiblelint/rules/syntax_check.md index 4afcfa03c2..566fa334e7 100644 --- a/src/ansiblelint/rules/syntax_check.md +++ b/src/ansiblelint/rules/syntax_check.md @@ -36,6 +36,17 @@ installed. You must ensure that all collections and roles used inside your repository are listed inside a [`requirements.yml`](https://docs.ansible.com/ansible/latest/galaxy/user_guide.html#installing-roles-and-collections-from-the-same-requirements-yml-file) file, so the linter can install them when they are missing. +Valid location for `requirements.yml` are: + +- `requirements.yml` +- `roles/requirements.yml` +- `collections/requirements.yml` +- `tests/requirements.yml` +- `tests/integration/requirements.yml` +- `tests/unit/requirements.yml` + +Note: If requirements are test related then they should be inside `tests/`. + ## Problematic code ```yaml