feat: adding rke2
- manage rke2 repos - add rke2 module (init, params, install, config, service) - add node_type setting class profiles::rke2::node - exclude setting ips for cilium interfaces
This commit is contained in:
@@ -47,7 +47,7 @@ class profiles::dns::base (
|
||||
$facts['networking']['interfaces'].each | $interface, $data | {
|
||||
|
||||
# exclude those without ipv4 address, lo, docker0 and anycast addresses
|
||||
if $data['ip'] and $interface != 'lo' and $interface != 'docker0' and $interface !~ /^anycast[0-9]$/ {
|
||||
if $data['ip'] and $interface != 'lo' and $interface != 'docker0' and $interface !~ /^anycast[0-9]$/ and $interface !~ /^cilium_/ {
|
||||
|
||||
# use defaults for the primary_interface
|
||||
if $interface == $primary_interface {
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
# manage server/agent nodes
|
||||
class profiles::rke2::node (
|
||||
Array[Stdlib::Fqdn] $servers = [],
|
||||
){
|
||||
|
||||
$node_type = $trusted['certname'] in $servers ? {
|
||||
true => 'server',
|
||||
default => 'agent',
|
||||
}
|
||||
|
||||
class {'rke2':
|
||||
node_type => $node_type,
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user