feat: add optional ingress for jenkins-agents

This commit is contained in:
Stefan Reimer 2022-04-28 11:17:49 +02:00
parent 5a04ac78d5
commit eafd8a8429
3 changed files with 27 additions and 2 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
name: kubezero-ci
description: KubeZero umbrella chart for all things CI
type: application
version: 0.4.45
version: 0.4.46
home: https://kubezero.com
icon: https://cdn.zero-downtime.net/assets/kubezero/logo-small-64.png
keywords:
@ -26,7 +26,7 @@ dependencies:
repository: https://dl.gitea.io/charts/
condition: gitea.enabled
- name: jenkins
version: 3.11.10
version: 3.12.0
repository: https://charts.jenkins.io
condition: jenkins.enabled
- name: trivy

View File

@ -44,4 +44,23 @@ spec:
method:
exact: "POST"
{{- end }}
{{- if .Values.jenkins.istio.agent.enabled }}
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ template "kubezero-lib.fullname" (merge (dict "subchart" "jenkins") .) }}-agent
namespace: {{ template "jenkins.namespace" . }}
spec:
hosts:
- {{ .Values.jenkins.istio.agent.url }}
gateways:
- {{ .Values.jenkins.istio.agent.gateway }}
http:
- route:
- destination:
host: {{ template "kubezero-lib.fullname" (merge (dict "subchart" "jenkins") .) }}
port:
number: 50000
{{- end }}
{{- end }}

View File

@ -194,6 +194,12 @@ jenkins:
gateway: istio-ingress/ingressgateway
url: jenkins-webhook.example.com
# Remote Agents
agent:
enabled: false
gateway: istio-ingress/private-ingressgateway
url: jenkins-agent.example.com
trivy:
enabled: false
persistence: