Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use multiple YAML documents for inventory plugin examples #146

Merged
merged 2 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions plugins/inventory/robot.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,14 @@
"""

EXAMPLES = r"""
---
# Fetch all hosts in Hetzner Robot
plugin: community.hrobot.robot
# Filters all servers in ready state
filters:
status: ready

---
# Example showing encrypted credentials and using filters
# (This assumes that Mozilla sops was used to encrypt keys/hetzner.sops.yaml, which contains two values
# hetzner_username and hetzner_password. Needs the community.sops collection to decode that file.)
Expand All @@ -73,6 +75,7 @@
# Exclude all servers that did not match any of the above filters
- exclude: true

---
# Example using constructed features to create groups
plugin: community.hrobot.robot
simple_filters:
Expand Down
8 changes: 0 additions & 8 deletions tests/sanity/ignore-2.10.txt

This file was deleted.

3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.10.txt.license

This file was deleted.

7 changes: 0 additions & 7 deletions tests/sanity/ignore-2.11.txt

This file was deleted.

3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.11.txt.license

This file was deleted.

7 changes: 0 additions & 7 deletions tests/sanity/ignore-2.12.txt

This file was deleted.

3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.12.txt.license

This file was deleted.

1 change: 0 additions & 1 deletion tests/sanity/ignore-2.13.txt

This file was deleted.

3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.13.txt.license

This file was deleted.

1 change: 1 addition & 0 deletions tests/sanity/ignore-2.14.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
plugins/inventory/robot.py yamllint:unparsable-with-libyaml
tests/ee/roles/smoke/library/smoke_ipaddress.py shebang
1 change: 1 addition & 0 deletions tests/sanity/ignore-2.15.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
plugins/inventory/robot.py yamllint:unparsable-with-libyaml
plugins/modules/storagebox_snapshot_plan.py pylint:unbalanced-dict-unpacking # only seems to be a problem with pylint included in ansible-core 2.15
tests/ee/roles/smoke/library/smoke_ipaddress.py shebang
1 change: 1 addition & 0 deletions tests/sanity/ignore-2.16.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
plugins/inventory/robot.py yamllint:unparsable-with-libyaml
tests/ee/roles/smoke/library/smoke_ipaddress.py shebang
3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.9.txt

This file was deleted.

3 changes: 0 additions & 3 deletions tests/sanity/ignore-2.9.txt.license

This file was deleted.

Loading