Executing the icinga2-ansible-no-ui task fails with:
TASK [icinga2-ansible-no-ui : Get Icinga2 Apt Repos for Debian OS family] *****************************
failed: [$host] (item={u'repo': u'deb https://packages.icinga.org/ubuntu icinga-xenial main'}) => changed=false
item:
repo: deb https://packages.icinga.org/ubuntu icinga-xenial main
module_stderr: |-
Shared connection to $host closed.
module_stdout: |-
Traceback (most recent call last):
File "/tmp/ansible_xNVZfR/ansible_module_apt_repository.py", line 550, in <module>
main()
File "/tmp/ansible_xNVZfR/ansible_module_apt_repository.py", line 542, in main
cache.update()
File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 454, in update
raise FetchFailedException(e)
apt.cache.FetchFailedException: W:The repository 'https://packages.icinga.org/ubuntu icinga-xenial Release' does not have a Release file., W:Data from such a repository can't be authenticated and is therefore potentially dangerous to use., W:See apt-secure(8) manpage for repository creation and user configuration details., E:Failed to fetch https://packages.icinga.org/ubuntu/dists/icinga-xenial/main/source/Sources server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none, E:Some index files failed to download. They have been ignored, or old ones used instead.
msg: MODULE FAILURE
rc: 1
failed: [$host] (item={u'repo': u'deb-src https://packages.icinga.org/ubuntu icinga-xenial main'}) => changed=false
item:
repo: deb-src https://packages.icinga.org/ubuntu icinga-xenial main
module_stderr: |-
Shared connection to $host closed.
module_stdout: |-
Traceback (most recent call last):
File "/tmp/ansible_AfqkSq/ansible_module_apt_repository.py", line 550, in <module>
main()
File "/tmp/ansible_AfqkSq/ansible_module_apt_repository.py", line 542, in main
cache.update()
File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 454, in update
raise FetchFailedException(e)
apt.cache.FetchFailedException: W:The repository 'https://packages.icinga.org/ubuntu icinga-xenial Release' does not have a Release file., W:Data from such a repository can't be authenticated and is therefore potentially dangerous to use., W:See apt-secure(8) manpage for repository creation and user configuration details., E:Failed to fetch https://packages.icinga.org/ubuntu/dists/icinga-xenial/main/source/Sources server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none, E:Some index files failed to download. They have been ignored, or old ones used instead.
msg: MODULE FAILURE
rc: 1
This is because the TLS certificate for packages.icinga.org is expired:
$ curl -I https://packages.icinga.org/ubuntu/dists/icinga-xenial/main/source/Sources
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html
curl performs SSL certificate verification by default, using a "bundle"
of Certificate Authority (CA) public keys (CA certs). If the default
bundle file isn't adequate, you can specify an alternate file
using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
the bundle, the certificate verification probably failed due to a
problem with the certificate (it might be expired, or the name might
not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
the -k (or --insecure) option.
Also, the server redirects to packages.icinga.com:
Executing the
icinga2-ansible-no-ui
task fails with:This is because the TLS certificate for
packages.icinga.org
is expired:Also, the server redirects to
packages.icinga.com
:A PR fixing this in the works.