Skip to content

Commit c4ad23c

Browse files
oolflooFlorian
andauthored
Enable to only backup job folder (#209)
* enable to only backup job folder Signed-off-by: Florian <florian.polin@bawagpsk.com> * fix alignment in values-common.yaml Signed-off-by: Florian <florian.polin@bawagpsk.com> Co-authored-by: Florian <florian.polin@bawagpsk.com>
1 parent e929024 commit c4ad23c

5 files changed

Lines changed: 12 additions & 1 deletion

File tree

charts/jenkins/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ Use the following links to reference issues, PRs, and commits prior to v2.6.0.
1212
The change log until v1.5.7 was auto-generated based on git commits.
1313
Those entries include a reference to the git commit to be able to get more details.
1414

15+
## 3.0.14
16+
17+
Enable to only backup job folder instead of whole jenkins
18+
1519
## 3.0.13
1620

1721
Improve Documentation around JCasc and Custom Image

charts/jenkins/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: v2
22
name: jenkins
33
home: https://jenkins.io/
4-
version: 3.0.13
4+
version: 3.0.14
55
appVersion: 2.263.1
66
description: Jenkins - Build great things at any scale! The leading open source automation server, Jenkins provides hundreds of plugins to support building, deploying and automating any project.
77
sources:

charts/jenkins/VALUES_SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -336,3 +336,4 @@ The following tables list the configurable parameters of the Jenkins chart and t
336336
| `backup.env` | Backup environment variables | `[]` |
337337
| `backup.resources` | Backup CPU/Memory resource requests/limits | Memory: `1Gi`, CPU: `1` |
338338
| `backup.destination` | Destination to store backup artifacts | `s3://jenkins-data/backup` |
339+
| `backup.onlyJobs` | Only backup the job folder | `false` |

charts/jenkins/templates/jenkins-backup-cronjob.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,11 @@ spec:
6060
- --container
6161
- jenkins
6262
- --path
63+
{{- if .Values.backup.onlyJobs }}
64+
- {{ .Values.controller.jenkinsHome }}/jobs
65+
{{- else}}
6366
- {{ .Values.controller.jenkinsHome }}
67+
{{- end}}
6468
- --dst
6569
- {{ .Values.backup.destination }}
6670
{{- with .Values.backup.extraArgs }}

charts/jenkins/values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -746,6 +746,8 @@ backup:
746746
# Additional support can added. Visit this repository for details
747747
# Ref: https://github.com/maorfr/skbn
748748
destination: "s3://jenkins-data/backup"
749+
# By enabling only the jenkins_home/jobs folder gets backed up, not the whole jenkins instance
750+
onlyJobs: false
749751
# Enable backup pod security context (must be `true` if runAsUser or fsGroup are set)
750752
usePodSecurityContext: true
751753
# When setting runAsUser to a different value than 0 also set fsGroup to the same value:

0 commit comments

Comments
 (0)