Puppet Client an Server registrieren

Puppet einzig auf einem Client ist kaum brauchbar, weshalb ein Puppet-Server verwendet werden sollte. Da die Kommunikation verschlüsselt per SSL ist, müssen zuvor Zertifikate ausgetauscht werden.

Auf dem Client:

puppet agent -t

Info: Creating a new SSL key for puppet-client.domain.local Info: Caching certificate for ca Info: csr_attributes file loading from /etc/puppetlabs/puppet/csr_attributes.yaml Info: Creating a new SSL certificate request for puppet-client.domain.local Info: Certificate Request fingerprint (SHA256): 1F:C3:A5:48:42:5C:BC:B5:B5:A7:D8:56:F5:33:88:B8:87:0D:EA:EF:9E:8D:E6:FF:78:61:BD:3D:41:26:D6:BD Info: Caching certificate for ca Exiting; no certificate found and waitforcert is disabled

Auf dem Server:

puppet cerpuppet cert list

“puppet-client.domain.local” (SHA256) 1F:C3:A5:48:42:5C:BC:B5:B5:A7:D8:56:F5:33:88:B8:87:0D:EA:EF:9E:8D:E6:FF:78:61:BD:3D:41:26:D6:BD “puppetdb” (SHA256) 8F:E6:04:6E:F8:4F:FA:08:0B:AA:ED:52:F1:00:76:17:BA:CA:AE:BB:FA:0E:FA:A4:E6:11:83:65:67:B9:B6:F6

puppet cert sign puppet-client.domain.local

Signing Certificate Request for: “puppet-client.domain.local” (SHA256) 1F:C3:A5:48:42:5C:BC:B5:B5:A7:D8:56:F5:33:88:B8:87:0D:EA:EF:9E:8D:E6:FF:78:61:BD:3D:41:26:D6:BD Notice: Signed certificate request for puppet-client.domain.local Notice: Removing file Puppet::SSL::CertificateRequest puppet-client.domain.local at ‘/etc/puppetlabs/puppet/ssl/ca/requests/puppet-client.domain.local.pem’

puppet cerpuppet cert list

“puppetdb” (SHA256) 8F:E6:04:6E:F8:4F:FA:08:0B:AA:ED:52:F1:00:76:17:BA:CA:AE:BB:FA:0E:FA:A4:E6:11:83:65:67:B9:B6:F6

Auf dem Client:

puppet agent -t

Info: Caching certificate for puppet-client.domain.local Info: Caching certificate_revocation_list for ca Info: Caching certificate for puppet-client.domain.local Info: Using configured environment ‘production’ Info: Retrieving pluginfacts Info: Retrieving plugin Info: Retrieving locales Info: Caching catalog for puppet-client.domain.local Info: Applying configuration version ‘1553070697’ Notice: Applied catalog in 0.03 seconds

Nun kennen sich die Beiden!