Puppet Function: kubeinstall::service_ports
- Defined in:
-
functions/service_ports.pp
- Function type:
- Puppet Language
Overview
kubeinstall::service_ports(Array[Kubeinstall::ServicePort] $ports, Struct[{
type => Kubeinstall::ServiceType,
cluster_ip => Optional[Kubeinstall::ClusterIP],
}] $options) ⇒ Array
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
# File 'functions/service_ports.pp', line 1
function kubeinstall::service_ports(
Array[Kubeinstall::ServicePort] $ports,
Struct[{
type => Kubeinstall::ServiceType,
cluster_ip => Optional[Kubeinstall::ClusterIP],
}] $options
) >> Array {
$ports.map |$port| {
kubeinstall::service_port_name($ports, $port) +
{ 'port' => $port['port'] } +
kubeinstall::service_port_protocol($port) +
kubeinstall::service_port_nodeport($port, $options['type']) +
kubeinstall::service_port_targetport($port, $options['cluster_ip']) +
kubeinstall::service_port_appprotocol($port)
}
}
|