Skip to content

Commit

Permalink
fixed examples
Browse files Browse the repository at this point in the history
  • Loading branch information
unasra committed Dec 11, 2024
1 parent 8a73463 commit 1bfc8a7
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 2 deletions.
23 changes: 21 additions & 2 deletions plugins/modules/infra_host.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

__metaclass__ = type

import time

DOCUMENTATION = r"""
---
module: infra_host
Expand Down Expand Up @@ -68,6 +66,27 @@
- infoblox.bloxone.common
""" # noqa: E501

EXAMPLES = r"""
- name: Create a host
infoblox.bloxone.infra_host:
display_name: "example_host"
state: "present"
- name: Create a host with Additional Fields
infoblox.bloxone.infra_host:
name: "example_host"
description: "Example Infra Host"
maintenance_mode: enabled
state: "present"
tags:
location: "my-location"
- name: Delete the host
infoblox.bloxone.infra_host:
display_name: "example_host"
state: "absent"
"""

RETURN = r"""
id:
description:
Expand Down
20 changes: 20 additions & 0 deletions plugins/modules/infra_host_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,26 @@
- infoblox.bloxone.common
""" # noqa: E501

EXAMPLES = r"""
- name: Get Host information by ID
infoblox.bloxone.infra_host_info:
id: "{{ host_id }}"
- name: Get Host information by filters (e.g. display name)
infoblox.bloxone.infra_host_info:
filters:
display_name: "example_host"
- name: Get Host information by raw filter query
infoblox.bloxone.infra_host_info:
filter_query: "display_name=='example_host'"
- name: Get Host information by tag filters
infoblox.bloxone.infra_host_info:
tag_filters:
location: "site-1"
"""

RETURN = r"""
id:
description:
Expand Down

0 comments on commit 1bfc8a7

Please sign in to comment.