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 compile_mode parameter to puppetserver.conf #574

Merged
merged 1 commit into from
Jan 11, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -527,6 +527,8 @@
# $server_puppetserver_trusted_agents:: Certificate names of puppet agents that are allowed to fetch *all* catalogs
# Defaults to [] and all agents are only allowed to fetch their own catalogs.
#
# $server_compile_mode:: Used to control JRuby's "CompileMode", which may improve performance.
# Defaults to undef (off).
# === Usage:
#
# * Simple usage:
Expand Down Expand Up @@ -725,6 +727,7 @@
Optional[Array] $server_metrics_allowed = $::puppet::params::server_metrics_allowed,
Boolean $server_puppetserver_experimental = $puppet::params::server_puppetserver_experimental,
Array[String] $server_puppetserver_trusted_agents = $puppet::params::server_puppetserver_trusted_agents,
Optional[Enum['off', 'jit', 'force']] $server_compile_mode = $puppet::params::server_compile_mode,
) inherits puppet::params {
include ::puppet::config
Class['puppet::config'] -> Class['puppet']
Expand Down
1 change: 1 addition & 0 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
$server_crl_enable = undef
$prerun_command = undef
$postrun_command = undef
$server_compile_mode = undef
$dns_alt_names = []
$use_srv_records = false

Expand Down
1 change: 1 addition & 0 deletions manifests/server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,7 @@
Variant[Undef, Array] $metrics_allowed = $::puppet::server_metrics_allowed,
Boolean $puppetserver_experimental = $::puppet::server_puppetserver_experimental,
Array[String] $puppetserver_trusted_agents = $::puppet::server_puppetserver_trusted_agents,
Optional[Enum['off', 'jit', 'force']] $compile_mode = $::puppet::server_compile_mode,
) {
if $implementation == 'master' and $ip != $puppet::params::ip {
notify {
Expand Down
1 change: 1 addition & 0 deletions manifests/server/puppetserver.pp
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@
$server_experimental = $::puppet::server::puppetserver_experimental,
$server_trusted_agents = $::puppet::server::puppetserver_trusted_agents,
$allow_header_cert_info = $::puppet::server::allow_header_cert_info,
$compile_mode = $::puppet::server::compile_mode,
) {
include ::puppet::server

Expand Down
1 change: 1 addition & 0 deletions spec/classes/puppet_server_puppetserver_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
:server_crl_enable => true,
:server_trusted_agents => [],
:allow_header_cert_info => false,
:compile_mode => 'off', # In reality defaults to undef
} end

describe 'with default parameters' do
Expand Down
3 changes: 3 additions & 0 deletions templates/server/puppetserver/conf.d/puppetserver.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ jruby-puppet: {
# (optional) enable or disable environment class cache
environment-class-cache-enabled: <%= @server_environment_class_cache_enabled %>
<%- end -%>
<%- if @compile_mode %>
compile-mode: <%= @compile_mode %>
<%- end -%>
}

# settings related to HTTP client requests made by Puppet Server
Expand Down