Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
base
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
puppetpublic
base
Commits
8d14785b
Commit
8d14785b
authored
9 years ago
by
Jonathan Lent
Browse files
Options
Downloads
Patches
Plain Diff
[puppetclient] Stripping special treatment for Puppet 2.X hosts
parent
13055c95
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
NEWS
+2
-1
2 additions, 1 deletion
NEWS
manifests/puppetclient/config.pp
+6
-48
6 additions, 48 deletions
manifests/puppetclient/config.pp
with
8 additions
and
49 deletions
NEWS
+
2
−
1
View file @
8d14785b
UNRELEASED
release/004.057 (2016-01-11)
[puppetclient] strip special treatment for Puppet 2.X hosts (jlent)
[pam] Stop overriding common PAM files with Debian jessie. (akkornel)
[ssh] Misc. filter-syslog cleanups. (akkornel)
...
...
This diff is collapsed.
Click to expand it.
manifests/puppetclient/config.pp
+
6
−
48
View file @
8d14785b
...
...
@@ -38,55 +38,13 @@ define base::puppetclient::config(
# The Puppet config file
$puppet_config
=
'/etc/puppet/puppet.conf'
if
(
$::hostname
=~
/jimhenson|frankoz/
)
{
# CASE 1. Puppet 2.x
# The file /etc/puppet/puppet.conf is constructed by first writing
# the ERB template file templates/puppet.conf.template.erb into
# /etc/puppet/puppet.conf.template.
#
# We then convert /etc/puppet/puppet.conf.template into
# /etc/puppet/puppet.conf using generate_conf.
#
# Note that for generate-conf to work we must have the database ini
# file in place.
# Puppet masters need the database credentials file, so download
# the wallet object.
include
base::puppetclient::db_credentials
$template_file
=
'/etc/puppet/puppet.conf.template'
$db_config
=
$puppetclient::db_credentials::puppet_db_ini_file
# 1. Install the template file.
file
{
$template_file
:
content
=>
template
(
'base/puppetclient/puppet.conf.template.erb'
),
mode
=>
'0644'
,
owner
=>
'root'
,
group
=>
'root'
,
}
# 2. Convert the template file into /etc/puppet/puppet.conf.
exec
{
'generate-conf puppet.conf'
:
command
=>
"generate-conf --template
${template_file}
--config
${db_config}
--newfile
${puppet_config}
"
,
refreshonly
=>
true
,
subscribe
=>
[
File
[
$template_file
],
Base
::
Wallet
[
$puppetclient::db_credentials::credentials_wallet_name
],
]
}
}
else
{
# CASE 2. Puppet 3.x
file
{
$puppet_config
:
content
=>
template
(
'base/puppetclient/puppet.conf.template.erb'
),
mode
=>
'0644'
,
owner
=>
'root'
,
group
=>
'root'
,
}
file
{
$puppet_config
:
content
=>
template
(
'base/puppetclient/puppet.conf.template.erb'
),
mode
=>
'0644'
,
owner
=>
'root'
,
group
=>
'root'
,
}
}
else
{
# not $is_master
file
{
$name
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment