Skip to content

Commit

Permalink
duplicate firewall exported resources
Browse files Browse the repository at this point in the history
Add a duplicate of every @@Firewall resource with 'firewall6-*' prefix
to prepare for upgrading firewall module.
  • Loading branch information
rrotter committed Nov 4, 2024
1 parent 39bda2f commit 0aed542
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 0 deletions.
9 changes: 9 additions & 0 deletions manifests/profile/haproxy.pp
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,15 @@
tag => 'haproxy'
}

@@firewall { "200 HTTP firewall6: HAProxy ${::hostname}":
proto => 'tcp',
dport => [80, 443],
source => $::ipaddress,
state => 'NEW',
action => 'accept',
tag => 'firewall6-haproxy'
}

# HAProxy should listen for kubernetes connections.
nebula::exposed_port { '200 kubectl':
port => 6443,
Expand Down
10 changes: 10 additions & 0 deletions manifests/profile/prometheus.pp
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,16 @@
tag => "${::datacenter}_prometheus_public_ipmi_exporter",
dport => 9290,
;

"010 prometheus public node exporter firewall6 ${::hostname} ${address}":
tag => "firewall6-${::datacenter}_prometheus_public_node_exporter",
dport => 9100,
;

"010 prometheus public ipmi exporter firewall6 ${::hostname} ${address}":
tag => "firewall6-${::datacenter}_prometheus_public_ipmi_exporter",
dport => 9290,
;
}
}

Expand Down
9 changes: 9 additions & 0 deletions manifests/profile/prometheus/exporter/node.pp
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,15 @@
state => 'NEW',
action => 'accept',
}

@@firewall { "300 pushgateway firewall6 ${::hostname} ${address}":
tag => "firewall6-${monitoring_datacenter}_pushgateway_node",
proto => 'tcp',
dport => 9091,
source => $address,
state => 'NEW',
action => 'accept',
}
}

ensure_packages(['curl', 'jq'])
Expand Down
8 changes: 8 additions & 0 deletions manifests/unison/client.pp
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,12 @@
tag => "unison-client-${title}"
}

@@firewall { "200 Unison firewall6: ${title} ${::hostname}":
proto => 'tcp',
dport => [$port],
source => $::ipaddress,
state => 'NEW',
action => 'accept',
tag => "firewall6-unison-client-${title}"
}
}

0 comments on commit 0aed542

Please sign in to comment.