modules: fix examples to use FQCN (#644)

* modules: fix examples to use FQCN

* fix

* fix

* fix
This commit is contained in:
Andrew Klychkov 2020-07-13 22:50:31 +03:00 committed by GitHub
commit 41cfdda6a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
533 changed files with 2130 additions and 2130 deletions

View file

@ -140,32 +140,32 @@ options:
EXAMPLES = '''
- name: Register nginx service with the local consul agent
consul:
community.general.consul:
service_name: nginx
service_port: 80
- name: Register nginx service with curl check
consul:
community.general.consul:
service_name: nginx
service_port: 80
script: curl http://localhost
interval: 60s
- name: Register nginx with an http check
consul:
community.general.consul:
service_name: nginx
service_port: 80
interval: 60s
http: http://localhost:80/status
- name: Register external service nginx available at 10.1.5.23
consul:
community.general.consul:
service_name: nginx
service_port: 80
service_address: 10.1.5.23
- name: Register nginx with some service tags
consul:
community.general.consul:
service_name: nginx
service_port: 80
tags:
@ -173,26 +173,26 @@ EXAMPLES = '''
- webservers
- name: Remove nginx service
consul:
community.general.consul:
service_name: nginx
state: absent
- name: Register celery worker service
consul:
community.general.consul:
service_name: celery-worker
tags:
- prod
- worker
- name: Create a node level check to test disk usage
consul:
community.general.consul:
check_name: Disk usage
check_id: disk_usage
script: /opt/disk_usage.py
interval: 5m
- name: Register an http check against a service that's already registered
consul:
community.general.consul:
check_name: nginx-check2
check_id: nginx-check2
service_id: nginx

View file

@ -77,7 +77,7 @@ requirements:
EXAMPLES = """
- name: Create an ACL with rules
consul_acl:
community.general.consul_acl:
host: consul1.example.com
mgmt_token: some_management_acl
name: Foo access
@ -88,7 +88,7 @@ EXAMPLES = """
policy: deny
- name: Create an ACL with a specific token
consul_acl:
community.general.consul_acl:
host: consul1.example.com
mgmt_token: some_management_acl
name: Foo access
@ -98,7 +98,7 @@ EXAMPLES = """
policy: read
- name: Update the rules associated to an ACL token
consul_acl:
community.general.consul_acl:
host: consul1.example.com
mgmt_token: some_management_acl
name: Foo access
@ -122,7 +122,7 @@ EXAMPLES = """
policy: write
- name: Remove a token
consul_acl:
community.general.consul_acl:
host: consul1.example.com
mgmt_token: some_management_acl
token: 172bd5c8-9fe9-11e4-b1b0-3c15c2c9fd5e

View file

@ -110,27 +110,27 @@ EXAMPLES = '''
# If the key does not exist, the value associated to the "data" property in `retrieved_key` will be `None`
# If the key value is empty string, `retrieved_key["data"]["Value"]` will be `None`
- name: Retrieve a value from the key/value store
consul_kv:
community.general.consul_kv:
key: somekey
register: retrieved_key
- name: Add or update the value associated with a key in the key/value store
consul_kv:
community.general.consul_kv:
key: somekey
value: somevalue
- name: Remove a key from the store
consul_kv:
community.general.consul_kv:
key: somekey
state: absent
- name: Add a node to an arbitrary group via consul inventory (see consul.ini)
consul_kv:
community.general.consul_kv:
key: ansible/groups/dc1/somenode
value: top_secret
- name: Register a key/value pair with an associated session
consul_kv:
community.general.consul_kv:
key: stg/node/server_birthday
value: 20160509
session: "{{ sessionid }}"

View file

@ -98,27 +98,27 @@ options:
EXAMPLES = '''
- name: Register basic session with consul
consul_session:
community.general.consul_session:
name: session1
- name: Register a session with an existing check
consul_session:
community.general.consul_session:
name: session_with_check
checks:
- existing_check_name
- name: Register a session with lock_delay
consul_session:
community.general.consul_session:
name: session_with_delay
delay: 20s
- name: Retrieve info about session by id
consul_session:
community.general.consul_session:
id: session_id
state: info
- name: Retrieve active sessions
consul_session:
community.general.consul_session:
state: list
'''