1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Adjust booleans in net tools, web infrastructure, and clustering modules. (#5159)

This commit is contained in:
Felix Fontein 2022-08-24 20:00:11 +02:00 committed by GitHub
parent 675bdef190
commit 7533f9ac26
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 72 additions and 72 deletions

View file

@ -70,7 +70,7 @@ options:
description: description:
- whether to verify the TLS certificate of the consul agent - whether to verify the TLS certificate of the consul agent
type: bool type: bool
default: 'yes' default: true
notes: notes:
type: str type: str
description: description:

View file

@ -46,7 +46,7 @@ options:
description: description:
- The key at which the value should be stored. - The key at which the value should be stored.
type: str type: str
required: yes required: true
value: value:
description: description:
- The value should be associated with the given key, required if C(state) - The value should be associated with the given key, required if C(state)
@ -55,7 +55,7 @@ options:
recurse: recurse:
description: description:
- If the key represents a prefix, each entry with the prefix can be - If the key represents a prefix, each entry with the prefix can be
retrieved by setting this to C(yes). retrieved by setting this to C(true).
type: bool type: bool
retrieve: retrieve:
description: description:
@ -103,7 +103,7 @@ options:
description: description:
- Whether to verify the tls certificate of the consul agent. - Whether to verify the tls certificate of the consul agent.
type: bool type: bool
default: 'yes' default: true
''' '''

View file

@ -37,13 +37,13 @@ options:
description: description:
- Force the change of the cluster state - Force the change of the cluster state
type: bool type: bool
default: 'yes' default: true
''' '''
EXAMPLES = ''' EXAMPLES = '''
--- ---
- name: Set cluster Online - name: Set cluster Online
hosts: localhost hosts: localhost
gather_facts: no gather_facts: false
tasks: tasks:
- name: Get cluster state - name: Get cluster state
community.general.pacemaker_cluster: community.general.pacemaker_cluster:

View file

@ -48,7 +48,7 @@ options:
description: description:
- Recursively delete node and all its children. - Recursively delete node and all its children.
type: bool type: bool
default: 'no' default: false
requirements: requirements:
- kazoo >= 2.1 - kazoo >= 2.1
- python >= 2.6 - python >= 2.6

View file

@ -84,7 +84,7 @@ options:
description: description:
- Proxy through Cloudflare network or just use DNS. - Proxy through Cloudflare network or just use DNS.
type: bool type: bool
default: no default: false
record: record:
description: description:
- Record to add. - Record to add.
@ -206,7 +206,7 @@ EXAMPLES = r'''
zone: example.net zone: example.net
type: CNAME type: CNAME
value: example.com value: example.com
proxied: yes proxied: true
account_email: test@example.com account_email: test@example.com
account_api_key: dummyapitoken account_api_key: dummyapitoken
state: present state: present

View file

@ -72,14 +72,14 @@ options:
- Whether the record should be the only one for that record type and record name. - Whether the record should be the only one for that record type and record name.
- Only use with C(state) is set to C(present) on a record. - Only use with C(state) is set to C(present) on a record.
type: 'bool' type: 'bool'
default: no default: false
sandbox: sandbox:
description: description:
- Use the DNSimple sandbox environment. - Use the DNSimple sandbox environment.
- Requires a dedicated account in the dnsimple sandbox environment. - Requires a dedicated account in the dnsimple sandbox environment.
- Check U(https://developer.dnsimple.com/sandbox/) for more information. - Check U(https://developer.dnsimple.com/sandbox/) for more information.
type: 'bool' type: 'bool'
default: no default: false
version_added: 3.5.0 version_added: 3.5.0
requirements: requirements:
- "dnsimple >= 2.0.0" - "dnsimple >= 2.0.0"

View file

@ -41,7 +41,7 @@ options:
description: description:
- Decides if the sandbox API should be used. Otherwise (default) the production API of DNS Made Easy is used. - Decides if the sandbox API should be used. Otherwise (default) the production API of DNS Made Easy is used.
type: bool type: bool
default: 'no' default: false
record_name: record_name:
description: description:
@ -80,16 +80,16 @@ options:
validate_certs: validate_certs:
description: description:
- If C(no), SSL certificates will not be validated. This should only be used - If C(false), SSL certificates will not be validated. This should only be used
on personally controlled sites using self-signed certificates. on personally controlled sites using self-signed certificates.
type: bool type: bool
default: 'yes' default: true
monitor: monitor:
description: description:
- If C(yes), add or change the monitor. This is applicable only for A records. - If C(true), add or change the monitor. This is applicable only for A records.
type: bool type: bool
default: 'no' default: false
systemDescription: systemDescription:
description: description:
@ -147,16 +147,16 @@ options:
failover: failover:
description: description:
- If C(yes), add or change the failover. This is applicable only for A records. - If C(true), add or change the failover. This is applicable only for A records.
type: bool type: bool
default: 'no' default: false
autoFailover: autoFailover:
description: description:
- If true, fallback to the primary IP address is manual after a failover. - If true, fallback to the primary IP address is manual after a failover.
- If false, fallback to the primary IP address is automatic after a failover. - If false, fallback to the primary IP address is automatic after a failover.
type: bool type: bool
default: 'no' default: false
ip1: ip1:
description: description:
@ -283,7 +283,7 @@ EXAMPLES = '''
record_name: test record_name: test
record_type: A record_type: A
record_value: 127.0.0.1 record_value: 127.0.0.1
monitor: yes monitor: true
ip1: 127.0.0.2 ip1: 127.0.0.2
protocol: HTTP # default protocol: HTTP # default
port: 80 # default port: 80 # default
@ -300,7 +300,7 @@ EXAMPLES = '''
record_name: test record_name: test
record_type: A record_type: A
record_value: 127.0.0.1 record_value: 127.0.0.1
monitor: yes monitor: true
ip1: 127.0.0.2 ip1: 127.0.0.2
protocol: HTTP # default protocol: HTTP # default
port: 80 # default port: 80 # default
@ -323,7 +323,7 @@ EXAMPLES = '''
failover: True failover: True
ip1: 127.0.0.2 ip1: 127.0.0.2
ip2: 127.0.0.3 ip2: 127.0.0.3
monitor: yes monitor: true
protocol: HTTPS protocol: HTTPS
port: 443 port: 443
maxEmails: 1 maxEmails: 1
@ -339,7 +339,7 @@ EXAMPLES = '''
record_name: test record_name: test
record_type: A record_type: A
record_value: 127.0.0.1 record_value: 127.0.0.1
failover: no failover: false
- name: Remove a monitor - name: Remove a monitor
community.general.dnsmadeeasy: community.general.dnsmadeeasy:
@ -350,7 +350,7 @@ EXAMPLES = '''
record_name: test record_name: test
record_type: A record_type: A
record_value: 127.0.0.1 record_value: 127.0.0.1
monitor: no monitor: false
''' '''
# ============================================ # ============================================

View file

@ -49,7 +49,7 @@ options:
- This can be used to terminate long-running sessions after a server is put - This can be used to terminate long-running sessions after a server is put
into maintenance mode. Overridden by the drain option. into maintenance mode. Overridden by the drain option.
type: bool type: bool
default: no default: false
socket: socket:
description: description:
- Path to the HAProxy socket file. - Path to the HAProxy socket file.
@ -68,25 +68,25 @@ options:
description: description:
- Disable/enable agent checks (depending on I(state) value). - Disable/enable agent checks (depending on I(state) value).
type: bool type: bool
default: no default: false
version_added: 1.0.0 version_added: 1.0.0
health: health:
description: description:
- Disable/enable health checks (depending on I(state) value). - Disable/enable health checks (depending on I(state) value).
type: bool type: bool
default: no default: false
version_added: "1.0.0" version_added: "1.0.0"
fail_on_not_found: fail_on_not_found:
description: description:
- Fail whenever trying to enable/disable a backend host that does not exist - Fail whenever trying to enable/disable a backend host that does not exist
type: bool type: bool
default: no default: false
wait: wait:
description: description:
- Wait until the server reports a status of 'UP' when C(state=enabled), - Wait until the server reports a status of 'UP' when C(state=enabled),
status of 'MAINT' when C(state=disabled) or status of 'DRAIN' when C(state=drain) status of 'MAINT' when C(state=disabled) or status of 'DRAIN' when C(state=drain)
type: bool type: bool
default: no default: false
wait_interval: wait_interval:
description: description:
- Number of seconds to wait between retries. - Number of seconds to wait between retries.
@ -118,8 +118,8 @@ EXAMPLES = r'''
community.general.haproxy: community.general.haproxy:
state: disabled state: disabled
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
health: yes health: true
agent: yes agent: true
- name: Disable server without backend pool name (apply to all available backend pool) - name: Disable server without backend pool name (apply to all available backend pool)
community.general.haproxy: community.general.haproxy:
@ -139,7 +139,7 @@ EXAMPLES = r'''
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
socket: /var/run/haproxy.sock socket: /var/run/haproxy.sock
backend: www backend: www
wait: yes wait: true
# Place server in drain mode, providing a socket file. Then check the server's # Place server in drain mode, providing a socket file. Then check the server's
# status every minute to see if it changes to maintenance mode, continuing if it # status every minute to see if it changes to maintenance mode, continuing if it
@ -149,8 +149,8 @@ EXAMPLES = r'''
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
socket: /var/run/haproxy.sock socket: /var/run/haproxy.sock
backend: www backend: www
wait: yes wait: true
drain: yes drain: true
wait_interval: 60 wait_interval: 60
wait_retries: 60 wait_retries: 60
@ -160,13 +160,13 @@ EXAMPLES = r'''
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
backend: www backend: www
socket: /var/run/haproxy.sock socket: /var/run/haproxy.sock
shutdown_sessions: yes shutdown_sessions: true
- name: Disable server without backend pool name (apply to all available backend pool) but fail when the backend host is not found - name: Disable server without backend pool name (apply to all available backend pool) but fail when the backend host is not found
community.general.haproxy: community.general.haproxy:
state: disabled state: disabled
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
fail_on_not_found: yes fail_on_not_found: true
- name: Enable server in 'www' backend pool - name: Enable server in 'www' backend pool
community.general.haproxy: community.general.haproxy:
@ -179,14 +179,14 @@ EXAMPLES = r'''
state: enabled state: enabled
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
backend: www backend: www
wait: yes wait: true
- name: Enable server in 'www' backend pool wait until healthy. Retry 10 times with intervals of 5 seconds to retrieve the health - name: Enable server in 'www' backend pool wait until healthy. Retry 10 times with intervals of 5 seconds to retrieve the health
community.general.haproxy: community.general.haproxy:
state: enabled state: enabled
host: '{{ inventory_hostname }}' host: '{{ inventory_hostname }}'
backend: www backend: www
wait: yes wait: true
wait_retries: 10 wait_retries: 10
wait_interval: 5 wait_interval: 5

View file

@ -33,7 +33,7 @@ options:
description: description:
- When set to C(NO), SSL certificates will not be validated. - When set to C(NO), SSL certificates will not be validated.
type: bool type: bool
default: yes default: true
notes: notes:
- Visit https://www.ipify.org to get more information. - Visit https://www.ipify.org to get more information.
''' '''

View file

@ -62,9 +62,9 @@ options:
ordered: ordered:
required: false required: false
type: bool type: bool
default: 'no' default: false
description: description:
- If C(yes), prepend list values with X-ORDERED index numbers in all - If C(true), prepend list values with X-ORDERED index numbers in all
attributes specified in the current task. This is useful mostly with attributes specified in the current task. This is useful mostly with
I(olcAccess) attribute to easily manage LDAP Access Control Lists. I(olcAccess) attribute to easily manage LDAP Access Control Lists.
extends_documentation_fragment: extends_documentation_fragment:
@ -115,7 +115,7 @@ EXAMPLES = r'''
to dn.base="dc=example,dc=com" to dn.base="dc=example,dc=com"
by dn="cn=admin,dc=example,dc=com" write by dn="cn=admin,dc=example,dc=com" write
by * read by * read
ordered: yes ordered: true
state: exact state: exact
- name: Declare some indexes - name: Declare some indexes

View file

@ -35,7 +35,7 @@ options:
- Whether the connection should start on boot. - Whether the connection should start on boot.
- Whether the connection profile can be automatically activated - Whether the connection profile can be automatically activated
type: bool type: bool
default: yes default: true
conn_name: conn_name:
description: description:
- The name used to call the connection. Pattern is <type>[-<ifname>][-<num>]. - The name used to call the connection. Pattern is <type>[-<ifname>][-<num>].
@ -155,7 +155,7 @@ options:
- Set as default route. - Set as default route.
- This parameter is mutually_exclusive with gw4 parameter. - This parameter is mutually_exclusive with gw4 parameter.
type: bool type: bool
default: no default: false
version_added: 2.0.0 version_added: 2.0.0
dns4: dns4:
description: description:
@ -331,7 +331,7 @@ options:
description: description:
- This is only used with bridge and controls whether Spanning Tree Protocol (STP) is enabled for this bridge. - This is only used with bridge and controls whether Spanning Tree Protocol (STP) is enabled for this bridge.
type: bool type: bool
default: yes default: true
priority: priority:
description: description:
- This is only used with 'bridge' - sets STP priority. - This is only used with 'bridge' - sets STP priority.
@ -1183,7 +1183,7 @@ EXAMPLES = r'''
ip4: 192.0.2.100/24 ip4: 192.0.2.100/24
gw4: 192.0.2.1 gw4: 192.0.2.1
state: present state: present
autoconnect: yes autoconnect: true
- name: Optionally, at the same time specify IPv6 addresses for the device - name: Optionally, at the same time specify IPv6 addresses for the device
community.general.nmcli: community.general.nmcli:

View file

@ -70,7 +70,7 @@ options:
description: description:
- Enable dynamic DNS updates for this host. - Enable dynamic DNS updates for this host.
type: bool type: bool
default: no default: false
''' '''
EXAMPLES = r''' EXAMPLES = r'''
@ -82,7 +82,7 @@ EXAMPLES = r'''
macaddr: 44:dd:ab:dd:11:44 macaddr: 44:dd:ab:dd:11:44
name: server01 name: server01
ip: 192.168.88.99 ip: 192.168.88.99
ddns: yes ddns: true
statements: statements:
- filename "pxelinux.0" - filename "pxelinux.0"
- next-server 1.1.1.1 - next-server 1.1.1.1

View file

@ -108,7 +108,7 @@ EXAMPLES = """
organization: MyOrg organization: MyOrg
user_name: Foo user_name: Foo
user_email: foo@bar.com user_email: foo@bar.com
user_disabled: yes user_disabled: true
- name: Make sure the user Foo is not part of MyOrg anymore - name: Make sure the user Foo is not part of MyOrg anymore
community.general.pritunl_user: community.general.pritunl_user:

View file

@ -50,12 +50,12 @@ options:
description: description:
- Use https to access balancer management page. - Use https to access balancer management page.
type: bool type: bool
default: 'no' default: false
validate_certs: validate_certs:
description: description:
- Validate ssl/tls certificates. - Validate ssl/tls certificates.
type: bool type: bool
default: 'yes' default: true
''' '''
EXAMPLES = ''' EXAMPLES = '''

View file

@ -94,7 +94,7 @@ options:
description: description:
- Whether to run the clean procedure in case of C(state=finalize). - Whether to run the clean procedure in case of C(state=finalize).
type: bool type: bool
default: 'yes' default: true
keep_releases: keep_releases:
type: int type: int

View file

@ -65,7 +65,7 @@ options:
- Clear the existing files before trying to copy or link the original file. - Clear the existing files before trying to copy or link the original file.
- Used only with the C(collectstatic) command. The C(--noinput) argument will be added automatically. - Used only with the C(collectstatic) command. The C(--noinput) argument will be added automatically.
required: false required: false
default: no default: false
type: bool type: bool
database: database:
description: description:

View file

@ -54,10 +54,10 @@ options:
create: create:
required: false required: false
type: bool type: bool
default: "yes" default: true
description: description:
- Used with C(state=present). If specified, the file will be created - Used with C(state=present). If specified, the file will be created
if it does not already exist. If set to "no", will fail if the if it does not already exist. If set to C(false), will fail if the
file does not exist file does not exist
notes: notes:
- "This module depends on the I(passlib) Python library, which needs to be installed on all target systems." - "This module depends on the I(passlib) Python library, which needs to be installed on all target systems."

View file

@ -68,10 +68,10 @@ options:
required: false required: false
validate_certs: validate_certs:
type: bool type: bool
default: yes default: true
description: description:
- If set to C(no), the SSL certificates will not be validated. - If set to C(false), the SSL certificates will not be validated.
This should only set to C(no) used on personally controlled sites This should only set to C(false) used on personally controlled sites
using self-signed certificates as it avoids verifying the source site. using self-signed certificates as it avoids verifying the source site.
- The C(python-jenkins) library only handles this by using the environment variable C(PYTHONHTTPSVERIFY). - The C(python-jenkins) library only handles this by using the environment variable C(PYTHONHTTPSVERIFY).
version_added: 2.3.0 version_added: 2.3.0

View file

@ -37,7 +37,7 @@ options:
type: str type: str
description: description:
- Plugin name. - Plugin name.
required: yes required: true
owner: owner:
type: str type: str
description: description:
@ -114,7 +114,7 @@ options:
- Defines whether to install plugin dependencies. - Defines whether to install plugin dependencies.
- This option takes effect only if the I(version) is not defined. - This option takes effect only if the I(version) is not defined.
type: bool type: bool
default: yes default: true
notes: notes:
- Plugin installation should be run under root or the same user which owns - Plugin installation should be run under root or the same user which owns
@ -141,7 +141,7 @@ EXAMPLES = '''
- name: Install plugin without its dependencies - name: Install plugin without its dependencies
community.general.jenkins_plugin: community.general.jenkins_plugin:
name: build-pipeline-plugin name: build-pipeline-plugin
with_dependencies: no with_dependencies: false
- name: Make sure the plugin is always up-to-date - name: Make sure the plugin is always up-to-date
community.general.jenkins_plugin: community.general.jenkins_plugin:
@ -196,11 +196,11 @@ EXAMPLES = '''
vars: vars:
my_jenkins_plugins: my_jenkins_plugins:
token-macro: token-macro:
enabled: yes enabled: true
build-pipeline-plugin: build-pipeline-plugin:
version: "1.4.9" version: "1.4.9"
pinned: no pinned: false
enabled: yes enabled: true
tasks: tasks:
- name: Install plugins without a specific version - name: Install plugins without a specific version
community.general.jenkins_plugin: community.general.jenkins_plugin:
@ -221,17 +221,17 @@ EXAMPLES = '''
- name: Initiate the fact - name: Initiate the fact
ansible.builtin.set_fact: ansible.builtin.set_fact:
jenkins_restart_required: no jenkins_restart_required: false
- name: Check if restart is required by any of the versioned plugins - name: Check if restart is required by any of the versioned plugins
ansible.builtin.set_fact: ansible.builtin.set_fact:
jenkins_restart_required: yes jenkins_restart_required: true
when: item.changed when: item.changed
with_items: "{{ my_jenkins_plugin_versioned.results }}" with_items: "{{ my_jenkins_plugin_versioned.results }}"
- name: Check if restart is required by any of the unversioned plugins - name: Check if restart is required by any of the unversioned plugins
ansible.builtin.set_fact: ansible.builtin.set_fact:
jenkins_restart_required: yes jenkins_restart_required: true
when: item.changed when: item.changed
with_items: "{{ my_jenkins_plugin_unversioned.results }}" with_items: "{{ my_jenkins_plugin_unversioned.results }}"
@ -257,7 +257,7 @@ EXAMPLES = '''
- name: Reset the fact - name: Reset the fact
ansible.builtin.set_fact: ansible.builtin.set_fact:
jenkins_restart_required: no jenkins_restart_required: false
when: jenkins_restart_required when: jenkins_restart_required
- name: Plugin pinning - name: Plugin pinning

View file

@ -33,11 +33,11 @@ options:
default: http://localhost:8080 default: http://localhost:8080
validate_certs: validate_certs:
description: description:
- If set to C(no), the SSL certificates will not be validated. - If set to C(false), the SSL certificates will not be validated.
This should only set to C(no) used on personally controlled sites This should only set to C(false) used on personally controlled sites
using self-signed certificates as it avoids verifying the source site. using self-signed certificates as it avoids verifying the source site.
type: bool type: bool
default: 'yes' default: true
user: user:
type: str type: str
description: description:
@ -90,7 +90,7 @@ EXAMPLES = '''
user: admin user: admin
password: admin password: admin
url: https://localhost url: https://localhost
validate_certs: no validate_certs: false
''' '''
RETURN = ''' RETURN = '''