mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-26 14:41:23 -07:00
ACME: rename acme_account_facts -> acme_account_info (#54082)
* Rename acme_account_facts -> acme_account_info. * Add changelog fragment.
This commit is contained in:
parent
7a24ecde86
commit
05bca95ab1
9 changed files with 16 additions and 9 deletions
|
@ -0,0 +1,2 @@
|
||||||
|
minor_changes:
|
||||||
|
- The ``acme_account_facts`` module has been renamed to ``acme_account_info``.
|
1
lib/ansible/modules/crypto/acme/_acme_account_facts.py
Symbolic link
1
lib/ansible/modules/crypto/acme/_acme_account_facts.py
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
acme_account_info.py
|
|
@ -33,7 +33,7 @@ seealso:
|
||||||
- name: Automatic Certificate Management Environment (ACME)
|
- name: Automatic Certificate Management Environment (ACME)
|
||||||
description: The specification of the ACME protocol (RFC 8555).
|
description: The specification of the ACME protocol (RFC 8555).
|
||||||
link: https://tools.ietf.org/html/rfc8555
|
link: https://tools.ietf.org/html/rfc8555
|
||||||
- module: acme_account_facts
|
- module: acme_account_info
|
||||||
description: Retrieves facts about an ACME account.
|
description: Retrieves facts about an ACME account.
|
||||||
- module: openssl_privatekey
|
- module: openssl_privatekey
|
||||||
description: Can be used to create a private account key.
|
description: Can be used to create a private account key.
|
||||||
|
|
|
@ -15,7 +15,7 @@ ANSIBLE_METADATA = {'metadata_version': '1.1',
|
||||||
|
|
||||||
DOCUMENTATION = '''
|
DOCUMENTATION = '''
|
||||||
---
|
---
|
||||||
module: acme_account_facts
|
module: acme_account_info
|
||||||
author: "Felix Fontein (@felixfontein)"
|
author: "Felix Fontein (@felixfontein)"
|
||||||
version_added: "2.7"
|
version_added: "2.7"
|
||||||
short_description: Retrieves information on ACME accounts
|
short_description: Retrieves information on ACME accounts
|
||||||
|
@ -26,6 +26,8 @@ description:
|
||||||
- "This module only works with the ACME v2 protocol."
|
- "This module only works with the ACME v2 protocol."
|
||||||
notes:
|
notes:
|
||||||
- "The M(acme_account) module allows to modify, create and delete ACME accounts."
|
- "The M(acme_account) module allows to modify, create and delete ACME accounts."
|
||||||
|
- "This module was called C(acme_account_facts) before Ansible 2.8. The usage
|
||||||
|
did not change."
|
||||||
seealso:
|
seealso:
|
||||||
- module: acme_account
|
- module: acme_account
|
||||||
description: Allows to create, modify or delete an ACME account.
|
description: Allows to create, modify or delete an ACME account.
|
||||||
|
@ -35,7 +37,7 @@ extends_documentation_fragment:
|
||||||
|
|
||||||
EXAMPLES = '''
|
EXAMPLES = '''
|
||||||
- name: Check whether an account with the given account key exists
|
- name: Check whether an account with the given account key exists
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
account_key_src: /etc/pki/cert/private/account.key
|
account_key_src: /etc/pki/cert/private/account.key
|
||||||
register: account_data
|
register: account_data
|
||||||
- name: Verify that account exists
|
- name: Verify that account exists
|
||||||
|
@ -48,7 +50,7 @@ EXAMPLES = '''
|
||||||
debug: var=account_data.account.contact
|
debug: var=account_data.account.contact
|
||||||
|
|
||||||
- name: Check whether the account exists and is accessible with the given account key
|
- name: Check whether the account exists and is accessible with the given account key
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
account_key_content: "{{ acme_account_key }}"
|
account_key_content: "{{ acme_account_key }}"
|
||||||
account_uri: "{{ acme_account_uri }}"
|
account_uri: "{{ acme_account_uri }}"
|
||||||
register: account_data
|
register: account_data
|
||||||
|
@ -125,6 +127,8 @@ def main():
|
||||||
),
|
),
|
||||||
supports_check_mode=True,
|
supports_check_mode=True,
|
||||||
)
|
)
|
||||||
|
if module._name == 'acme_account_facts':
|
||||||
|
module.deprecate("The 'acme_account_facts' module has been renamed to 'acme_account_info'", version='2.12')
|
||||||
set_crypto_backend(module)
|
set_crypto_backend(module)
|
||||||
|
|
||||||
if not module.params.get('validate_certs'):
|
if not module.params.get('validate_certs'):
|
|
@ -9,7 +9,7 @@
|
||||||
command: openssl ec -in {{ output_dir }}/accountkey.pem -noout -text
|
command: openssl ec -in {{ output_dir }}/accountkey.pem -noout -text
|
||||||
|
|
||||||
- name: Check that account does not exist
|
- name: Check that account does not exist
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
select_crypto_backend: "{{ select_crypto_backend }}"
|
select_crypto_backend: "{{ select_crypto_backend }}"
|
||||||
account_key_src: "{{ output_dir }}/accountkey.pem"
|
account_key_src: "{{ output_dir }}/accountkey.pem"
|
||||||
acme_version: 2
|
acme_version: 2
|
||||||
|
@ -31,7 +31,7 @@
|
||||||
- mailto:example@example.org
|
- mailto:example@example.org
|
||||||
|
|
||||||
- name: Check that account exists
|
- name: Check that account exists
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
select_crypto_backend: "{{ select_crypto_backend }}"
|
select_crypto_backend: "{{ select_crypto_backend }}"
|
||||||
account_key_src: "{{ output_dir }}/accountkey.pem"
|
account_key_src: "{{ output_dir }}/accountkey.pem"
|
||||||
acme_version: 2
|
acme_version: 2
|
||||||
|
@ -51,7 +51,7 @@
|
||||||
contact: []
|
contact: []
|
||||||
|
|
||||||
- name: Check that account was modified
|
- name: Check that account was modified
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
select_crypto_backend: "{{ select_crypto_backend }}"
|
select_crypto_backend: "{{ select_crypto_backend }}"
|
||||||
account_key_src: "{{ output_dir }}/accountkey.pem"
|
account_key_src: "{{ output_dir }}/accountkey.pem"
|
||||||
acme_version: 2
|
acme_version: 2
|
||||||
|
@ -61,7 +61,7 @@
|
||||||
register: account_modified
|
register: account_modified
|
||||||
|
|
||||||
- name: Check with wrong account URI
|
- name: Check with wrong account URI
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
select_crypto_backend: "{{ select_crypto_backend }}"
|
select_crypto_backend: "{{ select_crypto_backend }}"
|
||||||
account_key_src: "{{ output_dir }}/accountkey.pem"
|
account_key_src: "{{ output_dir }}/accountkey.pem"
|
||||||
acme_version: 2
|
acme_version: 2
|
||||||
|
@ -71,7 +71,7 @@
|
||||||
register: account_not_exist
|
register: account_not_exist
|
||||||
|
|
||||||
- name: Check with wrong account key
|
- name: Check with wrong account key
|
||||||
acme_account_facts:
|
acme_account_info:
|
||||||
select_crypto_backend: "{{ select_crypto_backend }}"
|
select_crypto_backend: "{{ select_crypto_backend }}"
|
||||||
account_key_src: "{{ output_dir }}/accountkey2.pem"
|
account_key_src: "{{ output_dir }}/accountkey2.pem"
|
||||||
acme_version: 2
|
acme_version: 2
|
Loading…
Add table
Add a link
Reference in a new issue