Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Nest
Puppet
Commits
f8cd876c
Commit
f8cd876c
authored
Dec 01, 2020
by
James T. Lee
Browse files
puppet: Let r10k deploy private repo with rugged
parent
654e6aaf
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
63 additions
and
19 deletions
+63
-19
.gitignore
.gitignore
+1
-0
data/node/puppet.yaml
data/node/puppet.yaml
+4
-0
data/private
data/private
+1
-0
files/puppet/hiera.yaml
files/puppet/hiera.yaml
+18
-6
files/puppet/r10k.yaml
files/puppet/r10k.yaml
+6
-1
manifests/node/puppet.pp
manifests/node/puppet.pp
+33
-12
No files found.
.gitignore
View file @
f8cd876c
.bundle/
.bundle/
Gemfile.lock
Gemfile.lock
vendor/
vendor/
modules/nest_private
data/node/puppet.yaml
View file @
f8cd876c
...
@@ -22,3 +22,7 @@ nest::package_keywords:
...
@@ -22,3 +22,7 @@ nest::package_keywords:
dev-ruby/puppet_forge
:
{}
dev-ruby/puppet_forge
:
{}
dev-ruby/rash_alt
:
{}
dev-ruby/rash_alt
:
{}
dev-ruby/simple_oauth
:
{}
dev-ruby/simple_oauth
:
{}
# For rugged
dev-libs/libgit2
:
version
:
'
~1.1.0'
data/private
0 → 120000
View file @
f8cd876c
../modules/nest_private/data
\ No newline at end of file
files/puppet/hiera.yaml
View file @
f8cd876c
...
@@ -10,14 +10,26 @@ defaults:
...
@@ -10,14 +10,26 @@ defaults:
hierarchy
:
hierarchy
:
-
name
:
'
Nodes'
-
name
:
'
Nodes'
path
:
"
node/%{::trusted.certname}.yaml"
paths
:
-
"
private/node/%{::trusted.certname}.yaml"
-
"
node/%{::trusted.certname}.yaml"
-
name
:
'
Roles'
-
name
:
'
Roles'
path
:
"
role/%{::role}.yaml"
paths
:
-
"
private/role/%{::role}.yaml"
-
"
role/%{::role}.yaml"
-
name
:
'
Platforms'
-
name
:
'
Platforms'
path
:
"
platform/%{::platform}.yaml"
paths
:
-
"
private/platform/%{::platform}.yaml"
-
"
platform/%{::platform}.yaml"
-
name
:
'
Architectures'
-
name
:
'
Architectures'
path
:
"
arch/%{::architecture}.yaml"
paths
:
-
"
private/arch/%{::architecture}.yaml"
-
"
arch/%{::architecture}.yaml"
-
name
:
'
Operating
Systems'
-
name
:
'
Operating
Systems'
path
:
"
os/%{::facts.osfamily}.yaml"
paths
:
-
"
private/os/%{::facts.osfamily}.yaml"
-
"
os/%{::facts.osfamily}.yaml"
-
name
:
'
Common'
-
name
:
'
Common'
path
:
'
common.yaml'
paths
:
-
'
private/common.yaml'
-
'
common.yaml'
files/puppet/r10k.yaml
View file @
f8cd876c
---
---
cachedir
:
'
/var/cache/r10k'
cachedir
:
'
/var/cache/r10k'
git
:
provider
:
'
rugged'
private_key
:
'
/etc/puppetlabs/r10k/id_rsa'
sources
:
sources
:
main
:
nest
:
remote
:
'
https://gitlab.james.tl/nest/puppet-nest.git'
remote
:
'
https://gitlab.james.tl/nest/puppet-nest.git'
basedir
:
'
/etc/puppetlabs/code/environments'
basedir
:
'
/etc/puppetlabs/code/environments'
manifests/node/puppet.pp
View file @
f8cd876c
class
nest::node::puppet
{
class
nest::node::puppet
(
String
[
1
]
$r10k_deploy_key
,
)
{
nest::lib::srv
{
'puppetserver'
:
}
nest::lib::srv
{
'puppetserver'
:
}
file
{
'/srv/puppetserver/hiera.yaml'
:
file
{
'/srv/puppetserver/hiera.yaml'
:
...
@@ -6,22 +8,41 @@ class nest::node::puppet {
...
@@ -6,22 +8,41 @@ class nest::node::puppet {
require
=>
Nest
::
Lib
::
Srv
[
'puppetserver'
],
require
=>
Nest
::
Lib
::
Srv
[
'puppetserver'
],
}
}
package
{
'
r10k
'
:
package
{
'
libgit2
'
:
ensure
=>
installed
,
ensure
=>
installed
,
}
}
file
{
'/etc/puppetlabs/r10k
'
:
package
{
'rugged
'
:
ensure
=>
directory
,
ensure
=>
installed
,
mode
=>
'0755'
,
install_options
=>
[
'--use-system-libraries'
]
,
owner
=>
'root'
,
provider
=>
gem
,
group
=>
'root'
,
require
=>
Package
[
'libgit2'
]
,
}
}
file
{
'/etc/puppetlabs/r10k/r10k.yaml'
:
package
{
'r10k'
:
mode
=>
'0644'
,
ensure
=>
installed
,
owner
=>
'root'
,
}
group
=>
'root'
,
source
=>
'puppet:///modules/nest/puppet/r10k.yaml'
,
file
{
default
:
owner
=>
'root'
,
group
=>
'root'
,
;
'/etc/puppetlabs/r10k'
:
mode
=>
'0755'
,
ensure
=>
directory
,
;
'/etc/puppetlabs/r10k/r10k.yaml'
:
mode
=>
'0644'
,
source
=>
'puppet:///modules/nest/puppet/r10k.yaml'
,
;
'/etc/puppetlabs/r10k/id_rsa'
:
mode
=>
'0600'
,
content
=>
$r10k_deploy_key
,
;
}
}
file
{
'/etc/eyaml'
:
file
{
'/etc/eyaml'
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment