Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions charts/contour-crds/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
update-crds.sh
17 changes: 17 additions & 0 deletions charts/contour-crds/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
annotations:
category: Infrastructure
licenses: Apache-2.0
apiVersion: v2
appVersion: 1.32.0
description: Contour is an open source Kubernetes ingress controller that works by deploying the Envoy proxy as a reverse proxy and load balancer.
home: https://projectcontour.io/
keywords:
- ingress
- envoy
- contour
maintainers:
- name: Contour Team
name: contour-crds
sources:
- https://github.com/projectcontour/helm-charts/tree/main/charts/contour-crds
version: 0.1.0
14,974 changes: 14,974 additions & 0 deletions charts/contour-crds/src/raw-gateway-api-crds.yaml

Large diffs are not rendered by default.

8,799 changes: 8,799 additions & 0 deletions charts/contour-crds/templates/contour-crds.yaml

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions charts/contour-crds/templates/gateway-api-crds.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{{- if .Values.enableGatewayCRDs }}
{{- $.Files.Get "src/raw-gateway-api-crds.yaml" -}}
{{- end }}
8 changes: 8 additions & 0 deletions charts/contour-crds/update-crds.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/usr/bin/env sh

here="$(cd -- "$(dirname "$0")" > /dev/null 2>&1 || exit; pwd -P)"
# replace this with `yq .appVersion "${here}/Chart.yaml"` if yq is reliably available
version="$(grep 'appVersion:' "${here}/Chart.yaml" | cut -d':' -f2 | tr -d ' ' | cut -d'"' -f2 | cut -d"'" -f2)"

curl -L -o "${here}/src/raw-gateway-crds.yaml" "https://raw.githubusercontent.com/projectcontour/contour/v${version}/examples/gateway/00-crds.yaml"
curl -L -o "${here}/templates/contour-crds.yaml" "https://raw.githubusercontent.com/projectcontour/contour/v${version}/examples/contour/01-crds.yaml"
2 changes: 2 additions & 0 deletions charts/contour-crds/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
enableGatewayCRDs: true

22 changes: 22 additions & 0 deletions charts/contour-gateway-provisioner/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
annotations:
category: Infrastructure
licenses: Apache-2.0
apiVersion: v2
appVersion: 1.32.1
description: Contour is an open source Kubernetes ingress controller that works by deploying the Envoy proxy as a reverse proxy and load balancer.
home: https://projectcontour.io/
keywords:
- ingress
- envoy
- contour
maintainers:
- name: Contour Team
name: contour-gateway-provisioner
sources:
- https://github.com/projectcontour/helm-charts/tree/main/charts/contour-gateway-provisioner
version: 0.1.0
dependencies:
- name: contour-crds
repository: https://projectcontour.github.io/helm-charts
version: 0.1.0
condition: contour-crds.enabled
62 changes: 62 additions & 0 deletions charts/contour-gateway-provisioner/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "contour-gateway-provisioner.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 "contour-gateway-provisioner.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 "contour-gateway-provisioner.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Common labels
*/}}
{{- define "contour-gateway-provisioner.labels" -}}
helm.sh/chart: {{ include "contour-gateway-provisioner.chart" . }}
{{ include "contour-gateway-provisioner.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}

{{/*
Selector labels
*/}}
{{- define "contour-gateway-provisioner.selectorLabels" -}}
app.kubernetes.io/name: {{ include "contour-gateway-provisioner.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Create the name of the service account to use
*/}}
{{- define "contour-gateway-provisioner.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "contour-gateway-provisioner.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}
76 changes: 76 additions & 0 deletions charts/contour-gateway-provisioner/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "contour-gateway-provisioner.fullname" . }}
labels:
{{- include "contour-gateway-provisioner.labels" . | nindent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
{{- include "contour-gateway-provisioner.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
annotations:
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "contour-gateway-provisioner.labels" . | nindent 8 }}
{{- with .Values.podLabels }}
{{- toYaml . | nindent 8 }}
{{- end }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
serviceAccountName: {{ include "contour-gateway-provisioner.serviceAccountName" . }}
{{- with .Values.podSecurityContext }}
securityContext:
{{- toYaml . | nindent 8 }}
{{- end }}
terminationGracePeriodSeconds: 10
containers:
- name: {{ .Chart.Name }}
{{- with .Values.securityContext }}
securityContext:
{{- toYaml . | nindent 12 }}
{{- end }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default (print "v" .Chart.AppVersion) }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: CONTOUR_PROVISIONER_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
command: ["contour"]
args:
- gateway-provisioner
- --metrics-addr=127.0.0.1:8080
- --enable-leader-election
{{- with .Values.resources }}
resources:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumeMounts }}
volumeMounts:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumes }}
volumes:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
Loading