Skip to content

Commit

Permalink
add pod annotation to gitlab cron job
Browse files Browse the repository at this point in the history
  • Loading branch information
slamdev committed Apr 23, 2023
1 parent 1cf925f commit e97c269
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/gitlab-omnibus/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: gitlab-omnibus
description: |-
Helm chart to deploy [Omnibus Gitlab](https://docs.gitlab.com/omnibus/).
type: application
version: 0.1.2
version: 0.1.3
# https://hub.docker.com/r/gitlab/gitlab-ee/tags
appVersion: "15.2.1-ee.0"
home: https://github.com/slamdev/helm-charts/tree/master/charts/gitlab-omnibus
Expand Down
3 changes: 2 additions & 1 deletion charts/gitlab-omnibus/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# gitlab-omnibus

![Version: 0.1.2](https://img.shields.io/badge/Version-0.1.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 15.2.1-ee.0](https://img.shields.io/badge/AppVersion-15.2.1--ee.0-informational?style=flat-square)
![Version: 0.1.3](https://img.shields.io/badge/Version-0.1.3-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 15.2.1-ee.0](https://img.shields.io/badge/AppVersion-15.2.1--ee.0-informational?style=flat-square)

Helm chart to deploy [Omnibus Gitlab](https://docs.gitlab.com/omnibus/).

Expand All @@ -21,6 +21,7 @@ Helm chart to deploy [Omnibus Gitlab](https://docs.gitlab.com/omnibus/).
| backupCronJob.command | list | `["gitlab-backup","create","SKIP=uploads,builds,artifacts,terraform_state,registry,pages,packages","GZIP_RSYNCABLE=yes","STRATEGY=copy"]` | command to execute in gitlab container |
| backupCronJob.enabled | bool | `true` | enable scheduled backups |
| backupCronJob.image | string | `"daedalusproject/base_kubectl"` | image |
| backupCronJob.podAnnotations | object | `{}` | pod annotations |
| backupCronJob.resources | object | `{"requests":{"cpu":"10m","memory":"32Mi"}}` | custom resource configuration |
| backupCronJob.schedule | string | `"@daily"` | how often to run backaup job |
| containerPorts | list | `[{"containerPort":8005,"name":"http"},{"containerPort":22,"name":"ssh"}]` | ports exposed by the container |
Expand Down
2 changes: 2 additions & 0 deletions charts/gitlab-omnibus/templates/cronjob-backup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ spec:
labels:
{{- include "gitlab.selectorLabels" . | nindent 12 }}
component: 'backup'
annotations:
{{- toYaml .Values.backupCronJob.podAnnotations | nindent 12 }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
Expand Down
2 changes: 2 additions & 0 deletions charts/gitlab-omnibus/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,8 @@ gitlabConf: |-
backupCronJob:
# backupCronJob.enabled -- enable scheduled backups
enabled: true
# backupCronJob.podAnnotations -- pod annotations
podAnnotations: { }
# backupCronJob.schedule -- how often to run backaup job
schedule: "@daily"
# backupCronJob.image -- image
Expand Down

0 comments on commit e97c269

Please sign in to comment.