ncsa / xcat-tools

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

Update custom/puppet_configure post script for enhanced puppet server support #45

Closed billglick closed 2 years ago

billglick commented 2 years ago

Currently if the Puppet server hostname is not in DNS (e.g. private IP space and/or served from an alternate/private DNS server) provisioned nodes cannot connect to the puppet server. We want to allow for the custom/puppet_configure post script to be able to add and /etc/hosts entry for the Puppet server.

Here is the initial idea to address this...

Update custom/puppet_configure to:

  1. Set the server from an optional command line flag, e.g. --host mf-pup01.local
  2. If no --host flag is passed, default to using $puppetmaster from site table (the current approach in the script). This keeps current setups working as expected.
  3. If an --ip flag is specified with an IP address (e.g. --ip 10.1.30.93), then add the supplied IP (and hostname from above) to /etc/hosts

The other advantage to this is that eventually we could point specific nodes or groups to differing Puppet servers. e.g. As we grow in scale we may need to have various parts of a cluster use unique Puppet servers.