Skip to content

Latest commit

 

History

History
243 lines (210 loc) · 8.33 KB

community.missing_collection.etcd3_lease_module.rst

File metadata and controls

243 lines (210 loc) · 8.33 KB

community.missing_collection.etcd3_lease

Manage Lease in ETCD Cluster.

Version added: 0.4.0

The below requirements are needed on the host that executes this module.

  • etcd3
Parameter Choices/Defaults Comments
host
string
Default:
"localhost"
host/ip of etcd node.
id
integer
id of lease.
password
string
Default:
"None"
password for etcd node if authentication is enabled.
port
integer / required
Default:
2379
port number for etcd node.
state
string
    Choices:
  • present ←
  • absent
do you want to create or delete the lease?
ttl
integer
Default:
1000
number of seconds for lease.
user
string
Default:
"None"
username for etcd node if authentication is enabled.

- name: create lease in etcd for 1000 seconds
  community.missing_collection.etcd3_lease:
    host: "localhost"
    port: 2379
    ttl: 1000
    state: "present"
  register: __

- name: revoke lease in etcd
  community.missing_collection.etcd3_lease:
    host: "localhost"
    port: 2379
    id: "{{ __.id }}"
    state: "absent"

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
hex_id
string
when ttl is defined and state == "present".
hex id of lease.

Sample:
694d7c6a37d09c24
id
integer
when ttl is defined and state == "present".
id of lease.

Sample:
7587857742833949726


Authors