Skip to content

Instantly share code, notes, and snippets.

@Magisus
Last active September 10, 2018 23:06
Show Gist options
  • Save Magisus/5ee8de463dfd538f55326e55e3244a95 to your computer and use it in GitHub Desktop.
Save Magisus/5ee8de463dfd538f55326e55e3244a95 to your computer and use it in GitHub Desktop.
1) Create self-signed root CA cert
2) Create CSR for intermediate CA cert
3) Sign with root
4) Create CRL for root
5) Create CRL for intermediate
6) Concatenate intermediate cert and root cert into one file (e.g. bundle.pem), intermediate first
7) Concatenate intermediate CRL and root CRL into one file (e.g. crls.pem), intermediate first
To import:
puppetserver ca import --cert-bundle bundle.pem --crl-chain crls.pem --private-key intermediate-key.pem
This will install these files in the correct locations for Puppet Server and generate any additional files (e.g. inventory.txt, master's host cert)
Ruby code that we use in Puppet's specs to create the artifacts for a setup like this: https://github.com/puppetlabs/puppet/blob/master/spec/lib/puppet_spec/ssl.rb
In the real world, the root cert would belong to the customer, e.g. their corporate root.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment