-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsite.pp
86 lines (79 loc) · 2.55 KB
/
site.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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
## site.pp ##
# This file (/etc/puppetlabs/puppet/manifests/site.pp) is the main entry point
# used when an agent connects to a master and asks for an updated configuration.
#
# Global objects like filebuckets and resource defaults should go in this file,
# as should the default node definition. (The default node can be omitted
# if you use the console and don't define any other nodes in site.pp. See
# http://docs.puppetlabs.com/guides/language_guide.html#nodes for more on
# node definitions.)
## Active Configurations ##
# Disable filebucket by default for all File resources:
File { backup => false }
# DEFAULT NODE
# Node definitions in this file are merged with node data from the console. See
# http://docs.puppetlabs.com/guides/language_guide.html#nodes for more on
# node definitions.
# The default node definition matches any node lacking a more specific node
# definition. If there are no other nodes in this file, classes declared here
# will be included in every node's catalog, *in addition* to any classes
# specified in the console for that node.
node /#{KUBERNETES_MASTER}#/ {
class { 'kubernetes':
controller => true,
}
class { 'firewalld': }
firewalld_port { 'etcd-client':
ensure => present,
zone => 'public',
port => 2379,
protocol => 'tcp',
}
firewalld_port { 'etcd-peer':
ensure => present,
zone => 'public',
port => 2380,
protocol => 'tcp',
}
firewalld_port { 'kubelet':
ensure => present,
zone => 'public',
port => 6443,
protocol => 'tcp',
}
firewalld_port { 'kube-proxy':
ensure => present,
zone => 'public',
port => 10250,
protocol => 'tcp',
}
firewalld_port { 'cilium-vxlan-overlay':
ensure => present,
zone => 'public',
port => 8472,
protocol => 'udp',
}
firewalld_port { 'cilium-health-check':
ensure => present,
zone => 'public',
port => 4240,
protocol => 'tcp',
}
}
node /#{KUBERNETES_WORKERS}#/ {
class { 'kubernetes':
worker => true,
}
firewalld_port { 'cilium-vxlan-overlay':
ensure => present,
zone => 'public',
port => 8472,
protocol => 'udp',
}
firewalld_port { 'cilium-health-check':
ensure => present,
zone => 'public',
port => 4240,
protocol => 'tcp',
}
}