A self-signed TLS certificate is generated by an Ansible task running the required OpenSSL command. A certificate needs a common name, which should match the requested domain name.
Currently this common name is gathered from the hostname command, like this:
|
-subj "/C=US/ST=Oregon/L=Portland/O=IT/CN=${hostname --fqdn}" |
But this "fails" and just generates a certificate with the literal text: ${hostname --fqdn}
I changed it to use an Ansible fact gathered beforehand, like: {{ ansible_facts["fqdn"] }}
WIth the help of that change the self signed certificate generation works fine and the common name matches the configured hostname.
This task would mostly be used for quick demos to spin Nextcloud and not need to worry about the TLS certificates yet. So this a minor detail. I hope it helped!
A self-signed TLS certificate is generated by an Ansible task running the required OpenSSL command. A certificate needs a common name, which should match the requested domain name.
Currently this common name is gathered from the hostname command, like this:
ansible-collection-nextcloud-admin/roles/install_nextcloud/tasks/tls_selfsigned.yml
Line 13 in a03c570
But this "fails" and just generates a certificate with the literal text:
${hostname --fqdn}I changed it to use an Ansible fact gathered beforehand, like:
{{ ansible_facts["fqdn"] }}WIth the help of that change the self signed certificate generation works fine and the common name matches the configured hostname.
This task would mostly be used for quick demos to spin Nextcloud and not need to worry about the TLS certificates yet. So this a minor detail. I hope it helped!