mirror of
https://gitea.com/gitea/helm-chart.git
synced 2024-06-01 18:01:24 +05:30
Refractored code
This commit is contained in:
parent
e540b53719
commit
d7de52a309
64
README.md
64
README.md
|
@ -45,6 +45,7 @@
|
||||||
- [Persistence](#persistence-1)
|
- [Persistence](#persistence-1)
|
||||||
- [Init](#init)
|
- [Init](#init)
|
||||||
- [Signing](#signing)
|
- [Signing](#signing)
|
||||||
|
- [Gitea Actions](#gitea-actions)
|
||||||
- [Gitea](#gitea)
|
- [Gitea](#gitea)
|
||||||
- [LivenessProbe](#livenessprobe)
|
- [LivenessProbe](#livenessprobe)
|
||||||
- [ReadinessProbe](#readinessprobe)
|
- [ReadinessProbe](#readinessprobe)
|
||||||
|
@ -982,38 +983,37 @@ To comply with the Gitea helm chart definition of the digest parameter, a "custo
|
||||||
|
|
||||||
### Gitea Actions
|
### Gitea Actions
|
||||||
|
|
||||||
| Name | Description | Value |
|
| Name | Description | Value |
|
||||||
| ------------------------------------------ | --------------------------------------------------------------------------- | ------------------ |
|
| ------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------ |
|
||||||
| `actions.enabled` | Create an act runner StatefulSet. | `false` |
|
| `actions.enabled` | Create an act runner StatefulSet. | `false` |
|
||||||
| `actions.statefulset.annotations` | Act runner annotations | `{}` |
|
| `actions.statefulset.annotations` | Act runner annotations | `{}` |
|
||||||
| `actions.statefulset.labels` | Act runner labels | `{}` |
|
| `actions.statefulset.labels` | Act runner labels | `{}` |
|
||||||
| `actions.statefulset.resources` | Act runner resources | `{}` |
|
| `actions.statefulset.resources` | Act runner resources | `{}` |
|
||||||
| `actions.statefulset.nodeSelector` | NodeSelector for the statefulset | `{}` |
|
| `actions.statefulset.nodeSelector` | NodeSelector for the statefulset | `{}` |
|
||||||
| `actions.statefulset.tolerations` | Tolerations for the statefulset | `[]` |
|
| `actions.statefulset.tolerations` | Tolerations for the statefulset | `[]` |
|
||||||
| `actions.statefulset.affinity` | Affinity for the statefulset | `{}` |
|
| `actions.statefulset.affinity` | Affinity for the statefulset | `{}` |
|
||||||
| `actions.statefulset.config` | Act runner custom configuration. | `""` |
|
| `actions.statefulset.actRunner.repository` | The Gitea act runner image | `gitea/act_runner` |
|
||||||
| `actions.statefulset.runnerLabels` | Act runner labels. | `""` |
|
| `actions.statefulset.actRunner.tag` | The Gitea act runner tag | `0.2.6` |
|
||||||
| `actions.statefulset.actRunner.repository` | The Gitea act runner image | `gitea/act_runner` |
|
| `actions.statefulset.actRunner.pullPolicy` | The Gitea act runner pullPolicy | `IfNotPresent` |
|
||||||
| `actions.statefulset.actRunner.tag` | The Gitea act runner tag | `0.2.6` |
|
| `actions.statefulset.actRunner.config` | Act runner custom configuration. See [Act Runner documentation](https://docs.gitea.com/usage/actions/act-runner#configuration) for details. | `Too complex. See values.yaml` |
|
||||||
| `actions.statefulset.actRunner.pullPolicy` | The Gitea act runner pullPolicy | `IfNotPresent` |
|
| `actions.statefulset.dind.repository` | The Docker-in-Docker image | `docker` |
|
||||||
| `actions.statefulset.dind.repository` | The Docker-in-Docker image | `docker` |
|
| `actions.statefulset.dind.tag` | The Docker-in-Docker image tag | `25.0.2-dind` |
|
||||||
| `actions.statefulset.dind.tag` | The Docker-in-Docker image tag | `25.0.2-dind` |
|
| `actions.statefulset.dind.pullPolicy` | The Docker-in-Docker pullPolicy | `IfNotPresent` |
|
||||||
| `actions.statefulset.dind.pullPolicy` | The Docker-in-Docker pullPolicy | `IfNotPresent` |
|
| `actions.provisioning.enabled` | Create a job that will create and save the token in a Kubernetes Secret | `false` |
|
||||||
| `actions.job.enabled` | Create a job that will create and save the token in a Kubernetes Secret | `false` |
|
| `actions.provisioning.annotations` | Job's annotations | `{}` |
|
||||||
| `actions.job.annotations` | Job's annotations | `{}` |
|
| `actions.provisioning.labels` | Job's labels | `{}` |
|
||||||
| `actions.job.labels` | Job's labels | `{}` |
|
| `actions.provisioning.resources` | Job's resources | `{}` |
|
||||||
| `actions.job.resources` | Job's resources | `{}` |
|
| `actions.provisioning.nodeSelector` | NodeSelector for the job | `{}` |
|
||||||
| `actions.job.nodeSelector` | NodeSelector for the job | `{}` |
|
| `actions.provisioning.tolerations` | Tolerations for the job | `[]` |
|
||||||
| `actions.job.tolerations` | Tolerations for the job | `[]` |
|
| `actions.provisioning.affinity` | Affinity for the job | `{}` |
|
||||||
| `actions.job.affinity` | Affinity for the job | `{}` |
|
| `actions.provisioning.token.repository` | The image that can create a token via `gitea actions generate-runner-token` | `gitea/gitea` |
|
||||||
| `actions.job.token.repository` | The image that can create a token via `gitea actions generate-runner-token` | `gitea/gitea` |
|
| `actions.provisioning.token.tag` | The token image tag that can create a token | `""` |
|
||||||
| `actions.job.token.tag` | The token image tag that can create a token | `""` |
|
| `actions.provisioning.token.pullPolicy` | The token image pullPolicy that can create a token | `IfNotPresent` |
|
||||||
| `actions.job.token.pullPolicy` | The token image pullPolicy that can create a token | `IfNotPresent` |
|
| `actions.provisioning.publish.repository` | The image that can create the secret via kubectl | `bitnami/kubectl` |
|
||||||
| `actions.job.publish.repository` | The image that can create the secret via kubectl | `bitnami/kubectl` |
|
| `actions.provisioning.publish.tag` | The publish image tag that can create the secret | `1.29.0` |
|
||||||
| `actions.job.publish.tag` | The publish image tag that can create the secret | `1.29.0` |
|
| `actions.provisioning.publish.pullPolicy` | The publish image pullPolicy that can create the secret | `IfNotPresent` |
|
||||||
| `actions.job.publish.pullPolicy` | The publish image pullPolicy that can create the secret | `IfNotPresent` |
|
| `actions.existingSecret` | Secret that contains the token | `""` |
|
||||||
| `actions.existingSecret` | Secret that contains the token | `""` |
|
| `actions.existingSecretKey` | Secret key | `""` |
|
||||||
| `actions.existingSecretKey` | Secret key | `""` |
|
|
||||||
|
|
||||||
### Gitea
|
### Gitea
|
||||||
|
|
||||||
|
|
|
@ -296,6 +296,9 @@ https
|
||||||
{{- if not (hasKey .Values.gitea.config "indexer") -}}
|
{{- if not (hasKey .Values.gitea.config "indexer") -}}
|
||||||
{{- $_ := set .Values.gitea.config "indexer" dict -}}
|
{{- $_ := set .Values.gitea.config "indexer" dict -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
{{- if not (hasKey .Values.gitea.config "actions") -}}
|
||||||
|
{{- $_ := set .Values.gitea.config "actions" dict -}}
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- define "gitea.inline_configuration.defaults" -}}
|
{{- define "gitea.inline_configuration.defaults" -}}
|
||||||
|
@ -342,6 +345,15 @@ https
|
||||||
{{- if not .Values.gitea.config.indexer.ISSUE_INDEXER_TYPE -}}
|
{{- if not .Values.gitea.config.indexer.ISSUE_INDEXER_TYPE -}}
|
||||||
{{- $_ := set .Values.gitea.config.indexer "ISSUE_INDEXER_TYPE" "db" -}}
|
{{- $_ := set .Values.gitea.config.indexer "ISSUE_INDEXER_TYPE" "db" -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
{{- if not .Values.gitea.config.actions.GITEA__ACTIONS__ENABLED -}}
|
||||||
|
{{- $_ := set .Values.gitea.config.actions "GITEA__ACTIONS__ENABLED" "true" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- if not .Values.gitea.config.actions.GITEA__SERVER__LOCAL_ROOT_URL -}}
|
||||||
|
{{- $_ := set .Values.gitea.config.actions "GITEA__SERVER__LOCAL_ROOT_URL" (printf "http://%s-http:%.0f" (include "gitea.fullname" .) .Values.service.http.port) -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- if not .Values.gitea.config.actions.GITEA__INSTANCE__URL -}}
|
||||||
|
{{- $_ := set .Values.gitea.config.actions "GITEA__INSTANCE__URL" (printf "http://%s-http:%.0f" (include "gitea.fullname" .) .Values.service.http.port) -}}
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- define "gitea.inline_configuration.defaults.server" -}}
|
{{- define "gitea.inline_configuration.defaults.server" -}}
|
||||||
|
|
|
@ -7,16 +7,8 @@ metadata:
|
||||||
labels:
|
labels:
|
||||||
{{- include "gitea.labels" . | nindent 4 }}
|
{{- include "gitea.labels" . | nindent 4 }}
|
||||||
data:
|
data:
|
||||||
{{- if .Values.actions.statefulset.config }}
|
|
||||||
config.yaml: |
|
config.yaml: |
|
||||||
{{- with .Values.actions.statefulset.config -}}
|
{{- with .Values.actions.statefulset.actRunner.config -}}
|
||||||
{{ . | nindent 4}}
|
{{ . | nindent 4}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- else }}
|
|
||||||
config.yaml: |
|
|
||||||
log:
|
|
||||||
level: debug
|
|
||||||
cache:
|
|
||||||
enabled: false
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
---
|
---
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: ConfigMap
|
kind: ConfigMap
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
{{- if .Values.actions.existingSecret }}
|
{{- if .Values.actions.existingSecret }}
|
||||||
{{- fail "Can't specify both actions.job.enabled and actions.existingSecret" }}
|
{{- fail "Can't specify both actions.provisioning.enabled and actions.existingSecret" }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
||||||
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
||||||
|
@ -11,12 +11,12 @@ metadata:
|
||||||
name: {{ $name }}
|
name: {{ $name }}
|
||||||
labels:
|
labels:
|
||||||
{{- include "gitea.labels" . | nindent 4 }}
|
{{- include "gitea.labels" . | nindent 4 }}
|
||||||
{{- with .Values.actions.job.labels }}
|
{{- with .Values.actions.provisioning.labels }}
|
||||||
{{- toYaml . | nindent 4 }}
|
{{- toYaml . | nindent 4 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
app.kubernetes.io/component: token-job
|
app.kubernetes.io/component: token-job
|
||||||
annotations:
|
annotations:
|
||||||
{{- with .Values.actions.job.annotations }}
|
{{- with .Values.actions.provisioning.annotations }}
|
||||||
{{- toYaml . | nindent 4 }}
|
{{- toYaml . | nindent 4 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
spec:
|
spec:
|
||||||
|
@ -25,7 +25,7 @@ spec:
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
labels:
|
||||||
{{- include "gitea.labels" . | nindent 8 }}
|
{{- include "gitea.labels" . | nindent 8 }}
|
||||||
{{- with .Values.actions.job.labels }}
|
{{- with .Values.actions.provisioning.labels }}
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
app.kubernetes.io/component: token-job
|
app.kubernetes.io/component: token-job
|
||||||
|
@ -42,8 +42,8 @@ spec:
|
||||||
done
|
done
|
||||||
containers:
|
containers:
|
||||||
- name: actions-token-create
|
- name: actions-token-create
|
||||||
image: "{{ .Values.actions.job.token.repository }}:{{ .Values.actions.job.token.tag | default (printf "%s-rootless" .Chart.AppVersion) }}"
|
image: "{{ .Values.actions.provisioning.token.repository }}:{{ .Values.actions.provisioning.token.tag | default (printf "%s-rootless" .Chart.AppVersion) }}"
|
||||||
imagePullPolicy: {{ .Values.actions.job.token.pullPolicy }}
|
imagePullPolicy: {{ .Values.actions.provisioning.token.pullPolicy }}
|
||||||
env:
|
env:
|
||||||
- name: GITEA_APP_INI
|
- name: GITEA_APP_INI
|
||||||
value: /data/gitea/conf/app.ini
|
value: /data/gitea/conf/app.ini
|
||||||
|
@ -55,7 +55,7 @@ spec:
|
||||||
mkdir -p /data/actions/
|
mkdir -p /data/actions/
|
||||||
gitea actions generate-runner-token | grep -E '^.{40}$' | tr -d '\n' > /data/actions/token
|
gitea actions generate-runner-token | grep -E '^.{40}$' | tr -d '\n' > /data/actions/token
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.actions.job.resources | nindent 12 }}
|
{{- toYaml .Values.actions.provisioning.resources | nindent 12 }}
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: data
|
- name: data
|
||||||
mountPath: /data
|
mountPath: /data
|
||||||
|
@ -63,8 +63,8 @@ spec:
|
||||||
subPath: {{ .Values.persistence.subPath }}
|
subPath: {{ .Values.persistence.subPath }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
- name: actions-token-upload
|
- name: actions-token-upload
|
||||||
image: "{{ .Values.actions.job.publish.repository }}:{{ .Values.actions.job.publish.tag }}"
|
image: "{{ .Values.actions.provisioning.publish.repository }}:{{ .Values.actions.provisioning.publish.tag }}"
|
||||||
imagePullPolicy: {{ .Values.actions.job.publish.pullPolicy }}
|
imagePullPolicy: {{ .Values.actions.provisioning.publish.pullPolicy }}
|
||||||
env:
|
env:
|
||||||
- name: SECRET_NAME
|
- name: SECRET_NAME
|
||||||
value: {{ $secretName }}
|
value: {{ $secretName }}
|
||||||
|
@ -76,7 +76,7 @@ spec:
|
||||||
kubectl auth can-i update secret/${SECRET_NAME}
|
kubectl auth can-i update secret/${SECRET_NAME}
|
||||||
/scripts/token.sh
|
/scripts/token.sh
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.actions.job.resources | nindent 12 }}
|
{{- toYaml .Values.actions.provisioning.resources | nindent 12 }}
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- mountPath: /scripts
|
- mountPath: /scripts
|
||||||
name: scripts
|
name: scripts
|
||||||
|
@ -87,15 +87,15 @@ spec:
|
||||||
{{- if .Values.persistence.subPath }}
|
{{- if .Values.persistence.subPath }}
|
||||||
subPath: {{ .Values.persistence.subPath }}
|
subPath: {{ .Values.persistence.subPath }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.actions.job.nodeSelector }}
|
{{- with .Values.actions.provisioning.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.actions.job.affinity }}
|
{{- with .Values.actions.provisioning.affinity }}
|
||||||
affinity:
|
affinity:
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.actions.job.tolerations }}
|
{{- with .Values.actions.provisioning.tolerations }}
|
||||||
tolerations:
|
tolerations:
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
||||||
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
||||||
---
|
---
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
||||||
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
||||||
---
|
---
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
||||||
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
{{- $secretName := include "gitea.workername" (dict "global" . "worker" "actions-token") }}
|
||||||
---
|
---
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{{- if and (and .Values.actions.job.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
{{- if and (and .Values.actions.provisioning.enabled .Values.persistence.enabled) .Values.persistence.mount }}
|
||||||
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
{{- $name := include "gitea.workername" (dict "global" . "worker" "actions-token-job") }}
|
||||||
---
|
---
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
|
|
|
@ -55,8 +55,6 @@ spec:
|
||||||
key: "{{ .Values.actions.existingSecretKey | default "token" }}"
|
key: "{{ .Values.actions.existingSecretKey | default "token" }}"
|
||||||
- name: GITEA_INSTANCE_URL
|
- name: GITEA_INSTANCE_URL
|
||||||
value: "http://{{ include "gitea.fullname" . }}-http:{{ .Values.service.http.port }}"
|
value: "http://{{ include "gitea.fullname" . }}-http:{{ .Values.service.http.port }}"
|
||||||
- name: GITEA_RUNNER_LABELS
|
|
||||||
value: "{{ .Values.actions.statefulset.runnerLabels | default "ubuntu-latest" }}"
|
|
||||||
- name: CONFIG_FILE
|
- name: CONFIG_FILE
|
||||||
value: /actrunner/config.yaml
|
value: /actrunner/config.yaml
|
||||||
resources:
|
resources:
|
||||||
|
@ -80,7 +78,6 @@ spec:
|
||||||
- name: DOCKER_CERT_PATH
|
- name: DOCKER_CERT_PATH
|
||||||
value: /certs/server
|
value: /certs/server
|
||||||
securityContext:
|
securityContext:
|
||||||
# allowPrivilegeEscalation: true
|
|
||||||
privileged: true
|
privileged: true
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.actions.statefulset.resources | nindent 12 }}
|
{{- toYaml .Values.actions.statefulset.resources | nindent 12 }}
|
||||||
|
|
|
@ -68,6 +68,12 @@ spec:
|
||||||
value: /data
|
value: /data
|
||||||
- name: GITEA_TEMP
|
- name: GITEA_TEMP
|
||||||
value: /tmp/gitea
|
value: /tmp/gitea
|
||||||
|
{{- if .Values.actions.enabled }}
|
||||||
|
- name: GITEA__ACTIONS__ENABLED
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__ACTIONS__ENABLED | quote }}
|
||||||
|
- name: GITEA__SERVER__LOCAL_ROOT_URL
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__SERVER__LOCAL_ROOT_URL | quote }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.deployment.env }}
|
{{- if .Values.deployment.env }}
|
||||||
{{- toYaml .Values.deployment.env | nindent 12 }}
|
{{- toYaml .Values.deployment.env | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -103,6 +109,12 @@ spec:
|
||||||
value: /data
|
value: /data
|
||||||
- name: GITEA_TEMP
|
- name: GITEA_TEMP
|
||||||
value: /tmp/gitea
|
value: /tmp/gitea
|
||||||
|
{{- if .Values.actions.enabled }}
|
||||||
|
- name: GITEA__ACTIONS__ENABLED
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__ACTIONS__ENABLED | quote }}
|
||||||
|
- name: GITEA__SERVER__LOCAL_ROOT_URL
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__SERVER__LOCAL_ROOT_URL | quote }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.deployment.env }}
|
{{- if .Values.deployment.env }}
|
||||||
{{- toYaml .Values.deployment.env | nindent 12 }}
|
{{- toYaml .Values.deployment.env | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -240,6 +252,12 @@ spec:
|
||||||
- name: GITEA_ADMIN_PASSWORD
|
- name: GITEA_ADMIN_PASSWORD
|
||||||
value: {{ .Values.gitea.admin.password | quote }}
|
value: {{ .Values.gitea.admin.password | quote }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.actions.enabled }}
|
||||||
|
- name: GITEA__ACTIONS__ENABLED
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__ACTIONS__ENABLED | quote }}
|
||||||
|
- name: GITEA__SERVER__LOCAL_ROOT_URL
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__SERVER__LOCAL_ROOT_URL | quote }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.deployment.env }}
|
{{- if .Values.deployment.env }}
|
||||||
{{- toYaml .Values.deployment.env | nindent 12 }}
|
{{- toYaml .Values.deployment.env | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -289,6 +307,12 @@ spec:
|
||||||
- name: GNUPGHOME
|
- name: GNUPGHOME
|
||||||
value: {{ .Values.signing.gpgHome }}
|
value: {{ .Values.signing.gpgHome }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.actions.enabled }}
|
||||||
|
- name: GITEA__ACTIONS__ENABLED
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__ACTIONS__ENABLED | quote }}
|
||||||
|
- name: GITEA__SERVER__LOCAL_ROOT_URL
|
||||||
|
value: {{ .Values.gitea.config.actions.GITEA__SERVER__LOCAL_ROOT_URL | quote }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.deployment.env }}
|
{{- if .Values.deployment.env }}
|
||||||
{{- toYaml .Values.deployment.env | nindent 12 }}
|
{{- toYaml .Values.deployment.env | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/config-scripts.yaml
|
template: templates/gitea/act_runner/config-scripts.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/job.yaml
|
template: templates/gitea/act_runner/job.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/role-job.yaml
|
template: templates/gitea/act_runner/role-job.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/rolebinding-job.yaml
|
template: templates/gitea/act_runner/rolebinding-job.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/secret-token.yaml
|
template: templates/gitea/act_runner/secret-token.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
|
@ -9,7 +9,7 @@ tests:
|
||||||
template: templates/gitea/act_runner/serviceaccount-job.yaml
|
template: templates/gitea/act_runner/serviceaccount-job.yaml
|
||||||
set:
|
set:
|
||||||
actions:
|
actions:
|
||||||
job:
|
provisioning:
|
||||||
enabled: true
|
enabled: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
44
values.yaml
44
values.yaml
|
@ -333,7 +333,6 @@ signing:
|
||||||
|
|
||||||
# Configure Gitea Actions
|
# Configure Gitea Actions
|
||||||
# - must enable persistence if the job is enabled
|
# - must enable persistence if the job is enabled
|
||||||
# - must define deployment.env.GITEA__ACTIONS__ENABLED and GITEA__SERVER__LOCAL_ROOT_URL
|
|
||||||
## @section Gitea Actions
|
## @section Gitea Actions
|
||||||
#
|
#
|
||||||
## @param actions.enabled Create an act runner StatefulSet.
|
## @param actions.enabled Create an act runner StatefulSet.
|
||||||
|
@ -343,27 +342,26 @@ signing:
|
||||||
## @param actions.statefulset.nodeSelector NodeSelector for the statefulset
|
## @param actions.statefulset.nodeSelector NodeSelector for the statefulset
|
||||||
## @param actions.statefulset.tolerations Tolerations for the statefulset
|
## @param actions.statefulset.tolerations Tolerations for the statefulset
|
||||||
## @param actions.statefulset.affinity Affinity for the statefulset
|
## @param actions.statefulset.affinity Affinity for the statefulset
|
||||||
## @param actions.statefulset.config Act runner custom configuration.
|
|
||||||
## @param actions.statefulset.runnerLabels Act runner labels.
|
|
||||||
## @param actions.statefulset.actRunner.repository The Gitea act runner image
|
## @param actions.statefulset.actRunner.repository The Gitea act runner image
|
||||||
## @param actions.statefulset.actRunner.tag The Gitea act runner tag
|
## @param actions.statefulset.actRunner.tag The Gitea act runner tag
|
||||||
## @param actions.statefulset.actRunner.pullPolicy The Gitea act runner pullPolicy
|
## @param actions.statefulset.actRunner.pullPolicy The Gitea act runner pullPolicy
|
||||||
|
## @param actions.statefulset.actRunner.config [default: Too complex. See values.yaml] Act runner custom configuration. See [Act Runner documentation](https://docs.gitea.com/usage/actions/act-runner#configuration) for details.
|
||||||
## @param actions.statefulset.dind.repository The Docker-in-Docker image
|
## @param actions.statefulset.dind.repository The Docker-in-Docker image
|
||||||
## @param actions.statefulset.dind.tag The Docker-in-Docker image tag
|
## @param actions.statefulset.dind.tag The Docker-in-Docker image tag
|
||||||
## @param actions.statefulset.dind.pullPolicy The Docker-in-Docker pullPolicy
|
## @param actions.statefulset.dind.pullPolicy The Docker-in-Docker pullPolicy
|
||||||
## @param actions.job.enabled Create a job that will create and save the token in a Kubernetes Secret
|
## @param actions.provisioning.enabled Create a job that will create and save the token in a Kubernetes Secret
|
||||||
## @param actions.job.annotations Job's annotations
|
## @param actions.provisioning.annotations Job's annotations
|
||||||
## @param actions.job.labels Job's labels
|
## @param actions.provisioning.labels Job's labels
|
||||||
## @param actions.job.resources Job's resources
|
## @param actions.provisioning.resources Job's resources
|
||||||
## @param actions.job.nodeSelector NodeSelector for the job
|
## @param actions.provisioning.nodeSelector NodeSelector for the job
|
||||||
## @param actions.job.tolerations Tolerations for the job
|
## @param actions.provisioning.tolerations Tolerations for the job
|
||||||
## @param actions.job.affinity Affinity for the job
|
## @param actions.provisioning.affinity Affinity for the job
|
||||||
## @param actions.job.token.repository The image that can create a token via `gitea actions generate-runner-token`
|
## @param actions.provisioning.token.repository The image that can create a token via `gitea actions generate-runner-token`
|
||||||
## @param actions.job.token.tag The token image tag that can create a token
|
## @param actions.provisioning.token.tag The token image tag that can create a token
|
||||||
## @param actions.job.token.pullPolicy The token image pullPolicy that can create a token
|
## @param actions.provisioning.token.pullPolicy The token image pullPolicy that can create a token
|
||||||
## @param actions.job.publish.repository The image that can create the secret via kubectl
|
## @param actions.provisioning.publish.repository The image that can create the secret via kubectl
|
||||||
## @param actions.job.publish.tag The publish image tag that can create the secret
|
## @param actions.provisioning.publish.tag The publish image tag that can create the secret
|
||||||
## @param actions.job.publish.pullPolicy The publish image pullPolicy that can create the secret
|
## @param actions.provisioning.publish.pullPolicy The publish image pullPolicy that can create the secret
|
||||||
## @param actions.existingSecret Secret that contains the token
|
## @param actions.existingSecret Secret that contains the token
|
||||||
## @param actions.existingSecretKey Secret key
|
## @param actions.existingSecretKey Secret key
|
||||||
actions:
|
actions:
|
||||||
|
@ -376,20 +374,26 @@ actions:
|
||||||
tolerations: []
|
tolerations: []
|
||||||
affinity: {}
|
affinity: {}
|
||||||
|
|
||||||
config: ""
|
|
||||||
runnerLabels: ""
|
|
||||||
|
|
||||||
actRunner:
|
actRunner:
|
||||||
repository: gitea/act_runner
|
repository: gitea/act_runner
|
||||||
tag: 0.2.6
|
tag: 0.2.6
|
||||||
pullPolicy: IfNotPresent
|
pullPolicy: IfNotPresent
|
||||||
|
|
||||||
|
config: |
|
||||||
|
log:
|
||||||
|
level: debug
|
||||||
|
cache:
|
||||||
|
enabled: false
|
||||||
|
runner:
|
||||||
|
labels:
|
||||||
|
- "ubuntu-latest"
|
||||||
|
|
||||||
dind:
|
dind:
|
||||||
repository: docker
|
repository: docker
|
||||||
tag: 25.0.2-dind
|
tag: 25.0.2-dind
|
||||||
pullPolicy: IfNotPresent
|
pullPolicy: IfNotPresent
|
||||||
|
|
||||||
job:
|
provisioning:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
annotations: {}
|
annotations: {}
|
||||||
|
|
Loading…
Reference in a new issue