I'm trying to use a puppetmaster for servers being both on an LAN and outside of a LAN. Here's the setup : I have 3 servers behind a router and a VM on Google Cloud. The puppet agents connect to the master using the "puppet" hostname while the GCP VM has to use the FQDN, and that's where my problems are.
Whenever I try a puppet run on the Google VM I get the following error:
Error: /File[/opt/puppetlabs/puppet/cache/facts.d]: Could not evaluate: Could not retrieve file metadata for puppet:///pluginfacts: Server hostname 'FQDN_OF_MY_LAN' did not match server certificate; expected one of puppet, DNS:puppet
All certificates are signed, even the VM's (which means the initial SSL cert exchange did work properly).
How can I get the VM to pull its catalog while it's expecting another hostname/fqdn from the CA than the one the puppetmaster uses ?