Skip to content

Commit 10b9f66

Browse files
docs: describe adding collection to requirements.yaml (#438)
Signed-off-by: Felix Seifert <[email protected]>
1 parent cd543a6 commit 10b9f66

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,17 @@ It is also recommended that all managed nodes disable firewalls and swap. See [K
3838
$ ansible-galaxy collection install git+https://github.com/k3s-io/k3s-ansible.git
3939
```
4040

41+
Alternatively, add it to the [`requirement.yaml` file of your Ansible project](https://docs.ansible.com/ansible/latest/collections_guide/collections_installing.html#install-multiple-collections-with-a-requirements-file) as follows:
42+
43+
```yaml
44+
collections:
45+
- name: https://github.com/k3s-io/k3s-ansible.git
46+
type: git
47+
version: <comit-ish>
48+
```
49+
50+
As a comit-ish, you can use a branch, a version tag, or a specific commit.
51+
4152
### From source
4253
4354
Alternatively to an installation with `ansible-galaxy`, the `k3s-ansible` repository can simply be cloned from github:

0 commit comments

Comments
 (0)