add woodpecker

This commit is contained in:
Morten Olsen
2025-12-21 19:48:34 +01:00
parent 2ab1db7122
commit c4fe4ffefb
4 changed files with 76 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
apiVersion: homelab.mortenolsen.pro/v1
kind: ExternalHttpService
metadata:
name: "{{ .Release.Name }}-woodpecker"
spec:
environment: '{{ .Values.globals.environment }}'
subdomain: 'woodpecker'
destination:
host: 'woodpecker-server.{{ .Release.Namespace }}.svc.cluster.local'
port:
number: 80

View File

@@ -0,0 +1,9 @@
apiVersion: homelab.mortenolsen.pro/v1
kind: GenerateSecret
metadata:
name: "{{ .Release.Name }}-woodpecker-secret"
spec:
fields:
- name: WOODPECKER_AGENT_SECRET
encoding: hex
length: 64

View File

@@ -0,0 +1,53 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: "{{ .Release.Name }}-woodpecker"
namespace: argocd
spec:
project: apps
source:
repoURL: https://woodpecker-ci.org/
chart: woodpecker
targetRevision: 3.4.2
helm:
releaseName: woodpecker
values: |
server:
extraSecretNamesForEnvFrom:
- {{ .Release.Name }}-woodpecker-secret
env:
WOODPECKER_HOST: "https://woodpecker.{{ .Values.globals.domain }}"
WOODPECKER_FORGEJO: "true"
WOODPECKER_FORGEJO_URL: "https://{{ .Values.subdomain }}.{{ .Values.globals.domain }}"
WOODPECKER_FORGEJO_CLIENT: "b3b42b15-3a60-4683-b548-b78fb3d82869"
WOODPECKER_FORGEJO_SECRET: "gto_xinhg5w3awf3moi64a4mqwzsbzv6mbnvb3ibyo6s7oo6d7j4n7da"
WOODPECKER_ADMIN: morten-olsen
WOODPECKER_BACKEND_K8S_STORAGE_CLASS: "{{ .Values.globals.environment }}"
WOODPECKER_BACKEND_K8S_STORAGE_RWX: "false"
WOODPECKER_PLUGINS_PRIVILEGED: plugins/docker
ingress:
enabled: false
persistentVolume:
enabled: true
accessModes:
- ReadWriteOnce
size: 10Gi
storageClass: "prod"
agent:
extraSecretNamesForEnvFrom:
- {{ .Release.Name }}-woodpecker-secret
env:
WOODPECKER_SERVER: "woodpecker-server:9000"
persistence:
storageClass: "{{ .Values.globals.environment }}"
destination:
server: https://kubernetes.default.svc
namespace: {{ .Release.Namespace }}
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
- ServerSideApply=true

View File

@@ -3,3 +3,5 @@ image:
tag: 13@sha256:88858e7f592f82d4f650713c7bed8c0cd792d7f71475a7467c5650a31cd2eda9 tag: 13@sha256:88858e7f592f82d4f650713c7bed8c0cd792d7f71475a7467c5650a31cd2eda9
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
subdomain: code subdomain: code
globals:
environment: prod