-
Notifications
You must be signed in to change notification settings - Fork 0
/
devnet.pp
62 lines (54 loc) · 1.73 KB
/
devnet.pp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
service { 'firewalld.service':
ensure => 'stopped',
enable => false,
}
service { 'pe-puppetserver':
ensure => 'running',
enable => true,
hasrestart => true,
restart => 'service pe-puppetserver reload',
}
file { '/root/.bash_profile':
ensure => file,
owner => 'root',
group => 'root',
mode => '0644',
content => file(inline_template("<%= File.expand_path(File.dirname(__FILE__)) + '/bash_profile' %>")),
}
file_line { 'autosign':
path => '/etc/puppetlabs/puppet/autosign.conf',
line => '*',
}
file { '/etc/puppetlabs/code/environments/production/manifests/site.pp':
ensure => file,
owner => 'pe-puppet',
group => 'pe-puppet',
mode => '0640',
content => file(inline_template("<%= File.expand_path(File.dirname(__FILE__)) + '/site.pp' %>")),
}
package { 'puppet-bolt':
ensure => 'present',
source => 'http://yum.puppetlabs.com/puppet6/el/7/x86_64/puppet-bolt-1.21.0-1.el7.x86_64.rpm',
provider => 'rpm',
}
file { '/etc/puppetlabs/code/environments/production/data/nodes':
ensure => directory,
owner => 'pe-puppet',
group => 'pe-puppet',
mode => '0644',
}
file { '/etc/puppetlabs/code/environments/production/data/common.yaml':
ensure => file,
owner => 'pe-puppet',
group => 'pe-puppet',
mode => '0640',
content => file(inline_template("<%= File.expand_path(File.dirname(__FILE__)) + '/common.yaml' %>")),
}
file { '/etc/puppetlabs/code/environments/production/data/nodes/csr1kv.yaml':
ensure => file,
owner => 'pe-puppet',
group => 'pe-puppet',
mode => '0640',
content => file(inline_template("<%= File.expand_path(File.dirname(__FILE__)) + '/csr1kv.yaml' %>")),
require => File['/etc/puppetlabs/code/environments/production/data/nodes'],
}