Running this script currently does setup the node right now, with the exception of me needing to manually sign the certificate for the agent on the master.
My question is, since we do not want to have to expose the master to every single agent for generating a ticket, can I change the dev-master to dev-satellite in the curl and generate the ticket on the satellite? Or will the master always need to generate the ticket?
Its odd that right now, even through the ticket is generated on the master, I still need to do a icinga2 ca sign on the agent request before it starts working, I thought the ticket process is there to bypass the need of needing to sign requests?
For the environment I’m currently setting up, yes I can access the master. Once I start pulling in other environments, I will not be able to.
I’m trying to automate the process of adding a new host as an agent, so this is why I was trying to see if it would be possible to generate the ticket on a satellite specifically in an env where the master might not be reachable.
Thanks for the detailed answer, Nick!
I already had read the docs and your quote before as well, but I could not clarify how exactly I can validate if the ca-proxy is running / working correctly.
You mean e.g. via icinga2 node setup? icinga2 node setup --cn <agent-hostname> --zone <agent-zonename> --parent_zone <sat-zone-1> --parent_host <sat-zone-1-endpoint-1> --endpoint <sat-zone-1-endpoint-1>–endpoint <sat-zone-1-endpoint-1> --trustedcert /tmp/trusted_<sat-zone-1-endpoint-1>.rhs.zz.crt --accept-commands --disable-confd --accept-config --ticket 99d629aca7bbaa825395925ab43b124784153702
This works as you described in our environment - certificate is auto-signed. Does the agent need the ticket to auto-renew his certificate? If yes, how does it supply it to the master / satellite and where is it located?
Also, you mean e.g. via icinga2 node setup? icinga2 node setup --cn <agent-hostname> --zone <agent-zonename> --parent_zone <sat-zone-1> --parent_host <sat-zone-1-endpoint-1> --endpoint <sat-zone-1-endpoint-1>–endpoint <sat-zone-1-endpoint-1> --trustedcert /tmp/trusted_<sat-zone-1-endpoint-1>.crt --accept-commands --disable-confd --accept-config
This works as you described in our environment - pending certificate is listed via icinga2 ca list on the master and both the sat-zone-1’s satellites / endpoints. I have to manually sign them.1
But I am currently experiencing a strange problem; We have multiple zones, exactly one zone sat-zone-1 has two satellites where the auto-renewing of the agents did not work and the agents were not checkable anymore. In another zone sat-zone-2 with exactly only one satellite, auto-renew worked.
This is the first renewal (we initiated icinga-agent in Q2 2024) so I can not verify
if the satellites of sat-zone-1 are configured incorrectly (in which way ever..) and the sat-zone-2 with a single satellite is configured correctly
or if the installed icinga-agent on the agents where auto-renewal did not work was installed / configured incorrectly. As they were the first to be installed and I tested around with them while building the ansible playbook I can not rule that out.