mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
openssl_csr: Update example (#41677)
Update example of Subject Alternative Name with dynamic list. Fixes: #33676 Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
This commit is contained in:
committed by
ansibot
parent
b5c18ea2bd
commit
671babd9aa
@@ -208,6 +208,16 @@ EXAMPLES = '''
|
||||
privatekey_path: /etc/ssl/private/ansible.com.pem
|
||||
subject_alt_name: 'DNS:www.ansible.com,DNS:m.ansible.com'
|
||||
|
||||
# Generate an OpenSSL CSR with subjectAltName extension with dynamic list
|
||||
- openssl_csr:
|
||||
path: /etc/ssl/csr/www.ansible.com.csr
|
||||
privatekey_path: /etc/ssl/private/ansible.com.pem
|
||||
subject_alt_name: "{{ item.value | map('regex_replace', '^', 'DNS:') | list }}"
|
||||
with_dict:
|
||||
dns_server:
|
||||
- www.ansible.com
|
||||
- m.ansible.com
|
||||
|
||||
# Force re-generate an OpenSSL Certificate Signing Request
|
||||
- openssl_csr:
|
||||
path: /etc/ssl/csr/www.ansible.com.csr
|
||||
|
||||
Reference in New Issue
Block a user