ncsa / xcat-tools

Useful tools for xCAT
BSD 3-Clause "New" or "Revised" License
8 stars 0 forks source link

SVCPLAN-4826: Add certname to puppet config file so consistent... #58

Closed billglick closed 6 months ago

billglick commented 6 months ago

…even if hostname changes later.

I’ve been messing with the custom/puppet_configure postscript and added functionality to set the Puppet agent certname based on the hostname configured in xCAT. This is to prevent e.g. a login host from switching to use its public hostname instead of its management hostname for Puppet certs.

The certname would be the FQDN of the puppet agent host from xCAT’s perspective. It sets the certname to $NODE.$DOMAIN according to xCAT of the default management interface. e.g.

But it does not change the certname if finds that one is already configured.

I also changed up the logic of how the puppet server is decided to be set. Basically if either of these settings are already set, it does not update them.