Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add puppet http api support #488

Merged
merged 3 commits into from
Feb 25, 2019
Merged

Add puppet http api support #488

merged 3 commits into from
Feb 25, 2019

Conversation

ekohl
Copy link
Member

@ekohl ekohl commented Feb 19, 2019

No description provided.

@alexjfisher
Copy link
Contributor

Works for me with an RPM of smart-proxy I built earlier. (most recent nightly srpm with https://github.com/theforeman/smart-proxy/pull/615.patch added to spec).

@ekohl ekohl changed the title [WIP] Add puppet http api support Add puppet http api support Feb 22, 2019
@ekohl
Copy link
Member Author

ekohl commented Feb 22, 2019

I've updated this with tests and a major version bump. I've introduced a parameter for the old versions. Also dropped Debian Jessie

Foreman 1.16 was the last release on Jessie and this module is 1.19+.
| 2.x | 1.5 - 1.10 | |
| 1.x | 1.4 and older | |

Starting version 1.22 the Puppet CA configuration is split depending on the provider. When using the module with 1.19 - 1.21, set `puppetca_split_configs` to `false`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It took me a little while to understand what was meant by 'split config'. Looking back and forth between this and at the smart proxy PR before I really understood. I can't think of a better parameter name or wording though!

Some extra confusion might also come from what is a 'ca provider'? You appear to be given a choice of 2 providers.

# valid providers:
#   - puppetca_hostname_whitelisting (verify CSRs based on a hostname whitelist)
#   - puppetca_token_whitelisting (verify CSRs based on a token whitelist)

but then depending on your puppet version you'll automatically either use puppetca_http_api or puppetca_puppet_cert 'providers'.

@@ -202,6 +202,7 @@

# puppetca settings
$puppetca = true
$puppetca_split_configs = true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My eyes! My eyes! If only the parameter was puppetca_split_config (not a serious suggestion) the indentation would be alligned :)

@@ -0,0 +1,4 @@
---
:ssldir: <%= scope.lookupvar("foreman_proxy::ssldir") %>
#:puppetca_use_sudo: true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does having these parameters here commented out serve any purpose? If they're worth including here, they should probably also go in puppetca.yml.erb when split configs is false.

Copy link
Contributor

@alexjfisher alexjfisher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Member

@timogoebel timogoebel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@ekohl ekohl merged commit ffc374b into theforeman:master Feb 25, 2019
@ekohl ekohl deleted the puppetca branch July 2, 2019 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants