From 49cb72055d5fa0860ce2421ca176ec8b74b67049 Mon Sep 17 00:00:00 2001 From: skalp Date: Thu, 14 Feb 2019 15:27:33 +0100 Subject: [PATCH] [stable/jenkins]: #10131 (#11411) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Pascal Le Métayer --- stable/jenkins/Chart.yaml | 2 +- stable/jenkins/README.md | 7 +++++++ stable/jenkins/templates/config.yaml | 14 +++++++++----- stable/jenkins/values.yaml | 12 ++++++++++++ 4 files changed, 29 insertions(+), 6 deletions(-) diff --git a/stable/jenkins/Chart.yaml b/stable/jenkins/Chart.yaml index 77fc8a77f8..c0fea54e68 100755 --- a/stable/jenkins/Chart.yaml +++ b/stable/jenkins/Chart.yaml @@ -1,6 +1,6 @@ name: jenkins home: https://jenkins.io/ -version: 0.32.2 +version: 0.32.3 appVersion: lts description: Open source continuous integration server. It supports multiple SCM tools including CVS, Subversion and Git. It can execute Apache Ant and Apache Maven-based diff --git a/stable/jenkins/README.md b/stable/jenkins/README.md index a9e1dcc63d..4086c3bbba 100644 --- a/stable/jenkins/README.md +++ b/stable/jenkins/README.md @@ -114,6 +114,13 @@ Some third-party systems, e.g. GitHub, use HTML-formatted data in their payload | `Agent.resources` | Resources allocation (Requests and Limits) | `{requests: {cpu: 200m, memory: 256Mi}, limits: {cpu: 200m, memory: 256Mi}}`| | `Agent.volumes` | Additional volumes | `nil` | | `Agent.envVars | Environment variables for the slave Pod | Not set | +| `Agent.Command | Executed command when side container starts | Not set | +| `Agent.Args | Arguments passed to executed command | Not set | +| `Agent.SideContainerName | Side container name in agent | jnlp | +| `Agent.TTYEnabled | Allocate pseudo tty to the side container | false | +| `Agent.ContainerCap | Maximum number of agent | 10 | +| `Agent.PodName | slave Pod base name | Not set | + Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. diff --git a/stable/jenkins/templates/config.yaml b/stable/jenkins/templates/config.yaml index 0be426866a..1c4f2ce71e 100644 --- a/stable/jenkins/templates/config.yaml +++ b/stable/jenkins/templates/config.yaml @@ -46,7 +46,7 @@ data: {{- if .Values.Agent.Enabled }} - default + {{ .Values.Agent.PodName }} 2147483647 0 @@ -69,7 +69,7 @@ data: - jnlp + {{ .Values.Agent.SideContainerName }} {{ .Values.Agent.Image }}:{{ .Values.Agent.ImageTag }} {{- if .Values.Agent.Privileged }} true @@ -78,9 +78,13 @@ data: {{- end }} {{ .Values.Agent.AlwaysPullImage }} /home/jenkins - + {{ .Values.Agent.Command }} +{{- if .Values.Agent.Args }} + {{ .Values.Agent.Args }} +{{- else }} ${computer.jnlpmac} ${computer.name} - false +{{- end }} + {{ .Values.Agent.TTYEnabled }} # Resources configuration is a little hacky. This was to prevent breaking # changes, and should be cleanned up in the future once everybody had # enough time to migrate. @@ -133,7 +137,7 @@ data: http://{{ template "jenkins.fullname" . }}:{{.Values.Master.ServicePort}}{{ default "" .Values.Master.JenkinsUriPrefix }} {{ template "jenkins.fullname" . }}-agent:{{ .Values.Master.SlaveListenerPort }} {{- end }} - 10 + {{ .Values.Agent.ContainerCap }} 5 0 0 diff --git a/stable/jenkins/values.yaml b/stable/jenkins/values.yaml index 187d27451d..c5b537a948 100644 --- a/stable/jenkins/values.yaml +++ b/stable/jenkins/values.yaml @@ -291,6 +291,18 @@ Agent: # Key Value selectors. Ex: # jenkins-agent: v1 + # Executed command when side container gets started + Command: + Args: + # Side container name + SideContainerName: jnlp + # Doesn't allocate pseudo TTY by default + TTYEnabled: false + # Max number of spawned agent + ContainerCap: 10 + # Pod name + PodName: default + Persistence: Enabled: true ## A manually managed Persistent Volume and Claim