feat (common): Readd external-interfaces as expert option (#1698)
This commit is contained in:
parent
65f396adb6
commit
9abf8aa990
|
@ -15,4 +15,4 @@ maintainers:
|
|||
name: common
|
||||
sources: null
|
||||
type: library
|
||||
version: 8.10.6
|
||||
version: 8.11.0
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
Secondary entrypoint and primary loader for the common chart
|
||||
*/}}
|
||||
{{- define "common.postSetup" -}}
|
||||
{{- /* Render the externalInterfaces */ -}}
|
||||
{{ include "common.classes.externalInterfaces" . | nindent 0 }}
|
||||
|
||||
{{- /* Enable code-server add-on if required */ -}}
|
||||
{{- if .Values.addons.codeserver.enabled }}
|
||||
{{- include "common.addon.codeserver" . }}
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
{{/*
|
||||
This template serves as a blueprint for External Interface objects that are created
|
||||
using the SCALE GUI.
|
||||
*/}}
|
||||
{{- define "common.classes.externalInterfaces" -}}
|
||||
{{- range $index, $iface := .Values.ixExternalInterfacesConfiguration }}
|
||||
---
|
||||
apiVersion: "k8s.cni.cncf.io/v1"
|
||||
kind: NetworkAttachmentDefinition
|
||||
metadata:
|
||||
name: ix-{{ $.Release.Name }}-{{ $index }}
|
||||
spec:
|
||||
config: '{{ $iface }}'
|
||||
{{- end }}
|
||||
{{- end -}}
|
|
@ -212,6 +212,22 @@ networkPolicy:
|
|||
# -- add or remove egress policies
|
||||
ingress: []
|
||||
|
||||
# -- Use this directly attach a pod to a SCALE interface.
|
||||
# Please be aware: This bypasses k8s services
|
||||
externalInterfaces: []
|
||||
# - hostInterface: "ens3"
|
||||
# ipam:
|
||||
# type: "dhcp"
|
||||
# - hostInterface: "br0"
|
||||
# ipam:
|
||||
# type: "static"
|
||||
# staticIPConfigurations:
|
||||
# - "192.168.0.120/24"
|
||||
# staticRoutes:
|
||||
# - destination: "0.0.0.0/0"
|
||||
# gateway: "192.168.0.1"
|
||||
|
||||
|
||||
# -- Use this to populate a secret with the values you specify.
|
||||
# Be aware that these values are not encrypted by default, and could therefore visible
|
||||
# to anybody with access to the values.yaml file.
|
||||
|
|
|
@ -1,3 +1,79 @@
|
|||
- variable: externalInterfaces
|
||||
description: "Add External Interfaces"
|
||||
label: "Add external Interfaces"
|
||||
group: "Networking"
|
||||
schema:
|
||||
type: list
|
||||
items:
|
||||
- variable: interfaceConfiguration
|
||||
description: "Interface Configuration"
|
||||
label: "Interface Configuration"
|
||||
schema:
|
||||
type: dict
|
||||
$ref:
|
||||
- "normalize/interfaceConfiguration"
|
||||
attrs:
|
||||
- variable: hostInterface
|
||||
description: "Please specify host interface"
|
||||
label: "Host Interface"
|
||||
schema:
|
||||
type: string
|
||||
required: true
|
||||
$ref:
|
||||
- "definitions/interface"
|
||||
- variable: ipam
|
||||
description: "Define how IP Address will be managed"
|
||||
label: "IP Address Management"
|
||||
schema:
|
||||
type: dict
|
||||
required: true
|
||||
attrs:
|
||||
- variable: type
|
||||
description: "Specify type for IPAM"
|
||||
label: "IPAM Type"
|
||||
schema:
|
||||
type: string
|
||||
required: true
|
||||
enum:
|
||||
- value: "dhcp"
|
||||
description: "Use DHCP"
|
||||
- value: "static"
|
||||
description: "Use static IP"
|
||||
show_subquestions_if: "static"
|
||||
subquestions:
|
||||
- variable: staticIPConfigurations
|
||||
label: "Static IP Addresses"
|
||||
schema:
|
||||
type: list
|
||||
items:
|
||||
- variable: staticIP
|
||||
label: "Static IP"
|
||||
schema:
|
||||
type: ipaddr
|
||||
cidr: true
|
||||
- variable: staticRoutes
|
||||
label: "Static Routes"
|
||||
schema:
|
||||
type: list
|
||||
items:
|
||||
- variable: staticRouteConfiguration
|
||||
label: "Static Route Configuration"
|
||||
schema:
|
||||
type: dict
|
||||
attrs:
|
||||
- variable: destination
|
||||
label: "Destination"
|
||||
schema:
|
||||
type: ipaddr
|
||||
cidr: true
|
||||
required: true
|
||||
- variable: gateway
|
||||
label: "Gateway"
|
||||
schema:
|
||||
type: ipaddr
|
||||
cidr: false
|
||||
required: true
|
||||
|
||||
- variable: dnsPolicy
|
||||
group: "Networking and Services"
|
||||
label: "dnsPolicy"
|
||||
|
|
Loading…
Reference in New Issue