-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release FortiADCIngressController: 2.0.1
Signed-off-by: FTNT-HQCM <[email protected]>
- Loading branch information
Showing
13 changed files
with
330 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
apiVersion: v2 | ||
name: fadc-k8s-ctrl | ||
version: 2.0.1 | ||
kubeVersion: ">= 1.19.8-0, <= 1.28-0" | ||
description: A Helm chart for FortiADC Ingress Controller | ||
type: application | ||
appVersion: "2.0.1" |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{{/* | ||
Expand the name of the chart. | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.name" -}} | ||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create a default fully qualified app name. | ||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). | ||
If release name contains chart name it will be used as a full name. | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.fullname" -}} | ||
{{- if .Values.fullnameOverride }} | ||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} | ||
{{- else }} | ||
{{- $name := default .Chart.Name .Values.nameOverride }} | ||
{{- if contains $name .Release.Name }} | ||
{{- .Release.Name | trunc 63 | trimSuffix "-" }} | ||
{{- else }} | ||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create chart name and version as used by the chart label. | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.chart" -}} | ||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
|
||
{{/* | ||
Common labels | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.labels" -}} | ||
helm.sh/chart: {{ include "fadc-k8s-ctrl.chart" . }} | ||
{{ include "fadc-k8s-ctrl.selectorLabels" . }} | ||
{{- if .Chart.AppVersion }} | ||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} | ||
{{- end }} | ||
app.kubernetes.io/managed-by: {{ .Release.Service }} | ||
{{- end }} | ||
|
||
{{/* | ||
Selector labels | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.selectorLabels" -}} | ||
app.kubernetes.io/name: {{ include "fadc-k8s-ctrl.name" . }} | ||
app.kubernetes.io/instance: {{ .Release.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the name of the service account to use | ||
*/}} | ||
{{- define "fadc-k8s-ctrl.serviceAccountName" -}} | ||
{{- if .Values.serviceAccount.create }} | ||
{{- default (include "fadc-k8s-ctrl.fullname" .) .Values.serviceAccount.name }} | ||
{{- else }} | ||
{{- default "default" .Values.serviceAccount.name }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: {{ include "fadc-k8s-ctrl.fullname" . }} | ||
labels: | ||
{{- include "fadc-k8s-ctrl.labels" . | nindent 4 }} | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
{{- include "fadc-k8s-ctrl.selectorLabels" . | nindent 6 }} | ||
template: | ||
metadata: | ||
{{- with .Values.podAnnotations }} | ||
annotations: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
labels: | ||
{{- include "fadc-k8s-ctrl.selectorLabels" . | nindent 8 }} | ||
spec: | ||
serviceAccountName: {{ .Values.serviceAccount.name }} | ||
securityContext: | ||
{{- toYaml .Values.podSecurityContext | nindent 8 }} | ||
containers: | ||
- name: {{ .Chart.Name }} | ||
securityContext: | ||
{{- toYaml .Values.securityContext | nindent 12 }} | ||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" | ||
imagePullPolicy: {{ .Values.image.pullPolicy }} | ||
{{- if eq .Values.parameters.openshiftRouteSupport "yes" }} | ||
securityContext: | ||
allowPrivilegeEscalation: false | ||
runAsNonRoot: true | ||
seccompProfile: | ||
type: RuntimeDefault | ||
capabilities: | ||
drop: ["ALL"] | ||
{{- end }} | ||
env: | ||
- name: VirtualServerNatSrcPool | ||
value: {{ .Values.parameters.virtualServerNatSrcPool }} | ||
- name: VirtualServerWafProfile | ||
value: {{ .Values.parameters.virtualServerWafProfile }} | ||
- name: VirtualServerAvProfile | ||
value: {{ .Values.parameters.virtualServerAvProfile }} | ||
- name: VirtualServerDosProfile | ||
value: {{ .Values.parameters.virtualServerDosProfile }} | ||
- name: VirtualServerCaptchaProfile | ||
value: {{ .Values.parameters.virtualServerCaptchaProfile }} | ||
- name: VirtualServerPersistence | ||
value: {{ .Values.parameters.virtualServerPersistence }} | ||
- name: VirtualServerFortiGSLB | ||
value: {{ .Values.parameters.virtualServerFortiGSLB }} | ||
- name: OpenShiftRouteSupport | ||
value: "{{ .Values.parameters.openshiftRouteSupport }}" | ||
|
||
{{- with .Values.nodeSelector }} | ||
nodeSelector: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- with .Values.affinity }} | ||
affinity: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- with .Values.tolerations }} | ||
tolerations: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{{- if .Values.controller.ingressClassResource.enabled -}} | ||
# We don't support namespaced ingressClass yet | ||
# So a ClusterRole and a ClusterRoleBinding is required | ||
apiVersion: networking.k8s.io/v1 | ||
kind: IngressClass | ||
metadata: | ||
name: {{ .Values.controller.ingressClassResource.name }} | ||
{{- if .Values.controller.ingressClassResource.default }} | ||
annotations: | ||
ingressclass.kubernetes.io/is-default-class: "true" | ||
{{- end }} | ||
spec: | ||
controller: {{ .Values.controller.ingressClassResource.controllerValue }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
kind: ClusterRole | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
name: {{ include "fadc-k8s-ctrl.serviceAccountName" . }} | ||
rules: | ||
- apiGroups: [""] | ||
resources: ["pods", "services", "nodes", "endpoints", "secrets"] | ||
verbs: ["get", "watch", "list", "update"] | ||
- apiGroups: | ||
- networking.k8s.io | ||
resources: | ||
- ingresses | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
- apiGroups: | ||
- networking.k8s.io | ||
resources: | ||
- ingressclasses | ||
verbs: | ||
- get | ||
- list | ||
- apiGroups: | ||
- networking.k8s.io | ||
resources: | ||
- ingresses/status | ||
verbs: | ||
- update | ||
- apiGroups: | ||
- extensions | ||
resources: | ||
- ingresses/status | ||
verbs: | ||
- update | ||
{{- if eq .Values.parameters.openshiftRouteSupport "yes" }} | ||
- apiGroups: | ||
- route.openshift.io | ||
resources: | ||
- routes | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
- apiGroups: | ||
- route.openshift.io | ||
resources: | ||
- routes/status | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
- update | ||
{{- end }} | ||
|
||
--- | ||
kind: ClusterRoleBinding | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
name: {{ include "fadc-k8s-ctrl.serviceAccountName" . }} | ||
subjects: | ||
- kind: ServiceAccount | ||
name: {{ include "fadc-k8s-ctrl.serviceAccountName" . }} | ||
namespace: {{ .Release.Namespace }} | ||
roleRef: | ||
kind: ClusterRole | ||
name: {{ include "fadc-k8s-ctrl.serviceAccountName" . }} | ||
apiGroup: rbac.authorization.k8s.io |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{{- if .Values.serviceAccount.create -}} | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: {{ include "fadc-k8s-ctrl.serviceAccountName" . }} | ||
#namespace: kube-system | ||
namespace: {{ .Release.Namespace }} | ||
labels: | ||
{{- include "fadc-k8s-ctrl.labels" . | nindent 4 }} | ||
{{- with .Values.serviceAccount.annotations }} | ||
annotations: | ||
{{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Default values for fadc-k8s-ctrl. | ||
# This is a YAML-formatted file. | ||
# Declare variables to be passed into your templates. | ||
# FortiADC Ingress Controller image from Dockerhub.com | ||
image: | ||
repository: fortinet/fortiadc-ingress | ||
pullPolicy: IfNotPresent | ||
tag: "2.0.1" | ||
|
||
nameOverride: "" | ||
fullnameOverride: "" | ||
|
||
serviceAccount: | ||
create: true | ||
annotations: {} | ||
name: "fortiadc-ingress" | ||
|
||
podAnnotations: {} | ||
|
||
podSecurityContext: {} | ||
|
||
securityContext: {} | ||
# capabilities: | ||
# drop: | ||
# - ALL | ||
# readOnlyRootFilesystem: true | ||
# runAsNonRoot: true | ||
# runAsUser: 1000 | ||
|
||
nodeSelector: {} | ||
|
||
tolerations: | ||
- effect: "NoExecute" | ||
key: "node.kubernetes.io/not-ready" | ||
operator: "Exists" | ||
tolerationSeconds: 30 | ||
- effect: "NoExecute" | ||
key: "node.kubernetes.io/unreachable" | ||
operator: "Exists" | ||
tolerationSeconds: 30 | ||
|
||
affinity: {} | ||
|
||
# Define Ingress Class for FortiADC Ingress Controller | ||
controller: | ||
ingressClassResource: | ||
name: "fadc-ingress-controller" | ||
enabled: true | ||
default: true | ||
controllerValue: "fortinet.com/fadc-ingress-controller" | ||
# You can decide parameters defined in annotation of Ingress to be optional or mandatory. | ||
# FortiADC Ingress Controller will check the parameter if it marks mandatory. | ||
parameters: | ||
virtualServerNatSrcPool : "optional" | ||
virtualServerWafProfile : "optional" | ||
virtualServerAvProfile : "optional" | ||
virtualServerDosProfile : "optional" | ||
virtualServerCaptchaProfile : "optional" | ||
virtualServerPersistence : "optional" | ||
virtualServerFortiGSLB : "optional" | ||
openshiftRouteSupport: "no" |
Binary file not shown.
Binary file not shown.
Oops, something went wrong.