Compare commits
23 Commits
661abbce61
...
keycloak-v
| Author | SHA1 | Date | |
|---|---|---|---|
| d11b156f15 | |||
| 854f936c13 | |||
| 88e49484bb | |||
| d72e29ff16 | |||
| 3bbb2f8240 | |||
| c84b0cd754 | |||
| b0b300073f | |||
| 4c8e4fdda8 | |||
| 33ae8790bc | |||
| ef882de1d8 | |||
| 975319c401 | |||
| 08359d4642 | |||
| 7924303a33 | |||
| 4092438f95 | |||
| 180b147897 | |||
| beaf854645 | |||
| c06b8bf2f3 | |||
| 71d8aa9fc5 | |||
| b648b0fc49 | |||
| 5ffcfa4039 | |||
| d083169e65 | |||
| 529ebc8095 | |||
| 70118e5aeb |
@@ -2,5 +2,5 @@ apiVersion: v2
|
|||||||
name: immich-argocd-apps
|
name: immich-argocd-apps
|
||||||
description: A Helm chart for deploying Immich as an ArgoCD app
|
description: A Helm chart for deploying Immich as an ArgoCD app
|
||||||
type: application
|
type: application
|
||||||
version: 0.1.4
|
version: 0.3.0
|
||||||
appVersion: v1.120.2
|
appVersion: v1.123.0
|
||||||
|
|||||||
@@ -2,4 +2,4 @@ apiVersion: v2
|
|||||||
name: keycloak-argocd-apps
|
name: keycloak-argocd-apps
|
||||||
description: A Helm chart for deploying the different argocd apps to deploy Keycloak
|
description: A Helm chart for deploying the different argocd apps to deploy Keycloak
|
||||||
type: application
|
type: application
|
||||||
version: 0.1.0
|
version: 0.2.1
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
apiVersion: argoproj.io/v1alpha1
|
apiVersion: argoproj.io/v1alpha1
|
||||||
kind: Application
|
kind: Application
|
||||||
metadata:
|
metadata:
|
||||||
name: keycloak-deployment
|
name: {{ .Values.argocd.prefix }}keycloak-deployment
|
||||||
namespace: {{ .Values.argocd.namespace }}
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
annotations:
|
annotations:
|
||||||
argocd.argoproj.io/sync-wave: "0"
|
argocd.argoproj.io/sync-wave: "0"
|
||||||
@@ -10,14 +10,26 @@ spec:
|
|||||||
project: {{ .Values.argocd.project }}
|
project: {{ .Values.argocd.project }}
|
||||||
source:
|
source:
|
||||||
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
||||||
targetRevision: HEAD
|
targetRevision: {{ .Values.keycloakDeployment.targetRevision }}
|
||||||
path: keycloak-deployment
|
path: keycloak-deployment
|
||||||
helm:
|
helm:
|
||||||
releaseName: keycloak-deployment
|
releaseName: keycloak-deployment
|
||||||
valuesObject:
|
valuesObject:
|
||||||
|
prefix: {{ .Values.argocd.prefix }}
|
||||||
keycloakDeployment:
|
keycloakDeployment:
|
||||||
|
deploymentName: {{ .Values.keycloakDeployment.deploymentName }}
|
||||||
numInstances: {{ .Values.keycloakDeployment.numInstances }}
|
numInstances: {{ .Values.keycloakDeployment.numInstances }}
|
||||||
hostname: {{ .Values.keycloakDeployment.hostname }}
|
hostname: {{ .Values.keycloakDeployment.hostname }}
|
||||||
|
vendor: {{ .Values.keycloakDeployment.vendor }}
|
||||||
|
dbHost: {{ .Values.keycloakDeployment.dbHost }}
|
||||||
|
dbPort: {{ .Values.keycloakDeployment.dbPort }}
|
||||||
|
usernameSecret:
|
||||||
|
name: {{ .Values.keycloakDeployment.usernameSecret.name }}
|
||||||
|
key: {{ .Values.keycloakDeployment.usernameSecret.key }}
|
||||||
|
passwordSecret:
|
||||||
|
name: {{ .Values.keycloakDeployment.passwordSecret.name }}
|
||||||
|
key: {{ .Values.keycloakDeployment.passwordSecret.key }}
|
||||||
|
database: {{ .Values.keycloakDeployment.database }}
|
||||||
destination:
|
destination:
|
||||||
server: {{ .Values.mainDestination }}
|
server: {{ .Values.mainDestination }}
|
||||||
namespace: {{ .Values.mainNamespace }}
|
namespace: {{ .Values.mainNamespace }}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
apiVersion: argoproj.io/v1alpha1
|
apiVersion: argoproj.io/v1alpha1
|
||||||
kind: Application
|
kind: Application
|
||||||
metadata:
|
metadata:
|
||||||
name: keycloak-postinstall
|
name: {{ .Values.argocd.prefix }}keycloak-postinstall
|
||||||
namespace: {{ .Values.argocd.namespace }}
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
annotations:
|
annotations:
|
||||||
argocd.argoproj.io/sync-wave: "1"
|
argocd.argoproj.io/sync-wave: "1"
|
||||||
@@ -10,11 +10,12 @@ spec:
|
|||||||
project: {{ .Values.argocd.project }}
|
project: {{ .Values.argocd.project }}
|
||||||
source:
|
source:
|
||||||
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
||||||
targetRevision: HEAD
|
targetRevision: {{ .Values.keycloakDeployment.targetRevision }}
|
||||||
path: keycloak-postinstall
|
path: keycloak-postinstall
|
||||||
helm:
|
helm:
|
||||||
releaseName: keycloak-postinstall
|
releaseName: keycloak-postinstall
|
||||||
valuesObject:
|
valuesObject:
|
||||||
|
prefix: {{ .Values.argocd.prefix }}
|
||||||
tailscaleIngresses:
|
tailscaleIngresses:
|
||||||
keycloakHostname: {{ .Values.tailscaleIngresses.keycloakHostname }}
|
keycloakHostname: {{ .Values.tailscaleIngresses.keycloakHostname }}
|
||||||
destination:
|
destination:
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
|
{{- if .Values.dbCluster.enable -}}
|
||||||
apiVersion: argoproj.io/v1alpha1
|
apiVersion: argoproj.io/v1alpha1
|
||||||
kind: Application
|
kind: Application
|
||||||
metadata:
|
metadata:
|
||||||
name: keycloak-requirements
|
name: {{ .Values.argocd.prefix }}keycloak-requirements
|
||||||
namespace: {{ .Values.argocd.namespace }}
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
annotations:
|
annotations:
|
||||||
argocd.argoproj.io/sync-wave: "-1"
|
argocd.argoproj.io/sync-wave: "-1"
|
||||||
@@ -15,6 +16,7 @@ spec:
|
|||||||
helm:
|
helm:
|
||||||
releaseName: keycloak-requirements
|
releaseName: keycloak-requirements
|
||||||
valuesObject:
|
valuesObject:
|
||||||
|
prefix: {{ .Values.argocd.prefix }}
|
||||||
dbCluster:
|
dbCluster:
|
||||||
size: {{ .Values.dbCluster.size }}
|
size: {{ .Values.dbCluster.size }}
|
||||||
numInstances: {{ .Values.dbCluster.numInstances }}
|
numInstances: {{ .Values.dbCluster.numInstances }}
|
||||||
@@ -29,3 +31,4 @@ spec:
|
|||||||
- ApplyOutOfSyncOnly=true
|
- ApplyOutOfSyncOnly=true
|
||||||
- ServerSideApply=true
|
- ServerSideApply=true
|
||||||
- CreateNamespace=true
|
- CreateNamespace=true
|
||||||
|
{{- end }}
|
||||||
@@ -1,13 +1,26 @@
|
|||||||
argocd:
|
argocd:
|
||||||
namespace: argocd
|
namespace: argocd
|
||||||
project: default
|
project: default
|
||||||
|
prefix: null
|
||||||
dbCluster:
|
dbCluster:
|
||||||
size: 1Gi
|
enable: true
|
||||||
|
size: 10Gi
|
||||||
numInstances: 3
|
numInstances: 3
|
||||||
mainNamespace: keycloak
|
mainNamespace: keycloak
|
||||||
mainDestination: https://kubernetes.default.svc
|
mainDestination: https://kubernetes.default.svc
|
||||||
keycloakDeployment:
|
keycloakDeployment:
|
||||||
|
targetRevision: HEAD
|
||||||
numInstances: 1
|
numInstances: 1
|
||||||
hostname: sso.domain.net
|
hostname: sso.domain.net
|
||||||
|
vendor: postgres
|
||||||
|
dbHost: keycloak-db-rw
|
||||||
|
dbPort: 5432
|
||||||
|
usernameSecret:
|
||||||
|
name: keycloak-db-app
|
||||||
|
key: user
|
||||||
|
passwordSecret:
|
||||||
|
name: keycloak-db-app
|
||||||
|
key: password
|
||||||
|
database: app
|
||||||
tailscaleIngresses:
|
tailscaleIngresses:
|
||||||
keycloakHostname: sso
|
keycloakHostname: sso
|
||||||
@@ -2,4 +2,4 @@ apiVersion: v2
|
|||||||
name: keycloak-deployment
|
name: keycloak-deployment
|
||||||
description: A Helm chart for deploying the actual keycloak pod through the keycloak operator
|
description: A Helm chart for deploying the actual keycloak pod through the keycloak operator
|
||||||
type: application
|
type: application
|
||||||
version: 0.1.0
|
version: 0.2.1
|
||||||
@@ -1,19 +1,20 @@
|
|||||||
apiVersion: k8s.keycloak.org/v2alpha1
|
apiVersion: k8s.keycloak.org/v2alpha1
|
||||||
kind: Keycloak
|
kind: Keycloak
|
||||||
metadata:
|
metadata:
|
||||||
name: linode-keycloak
|
name: {{ .Values.prefix }}keycloak
|
||||||
spec:
|
spec:
|
||||||
instances: {{ .Values.keycloakDeployment.numInstances }}
|
instances: {{ .Values.keycloakDeployment.numInstances }}
|
||||||
db:
|
db:
|
||||||
vendor: postgres
|
vendor: {{ .Values.keycloakDeployment.vendor }}
|
||||||
host: keycloak-db-rw
|
host: {{ .Values.keycloakDeployment.dbHost }}
|
||||||
|
port: {{ .Values.keycloakDeployment.dbPort }}
|
||||||
usernameSecret:
|
usernameSecret:
|
||||||
name: keycloak-db-app
|
name: {{ .Values.keycloakDeployment.usernameSecret.name }}
|
||||||
key: user
|
key: {{ .Values.keycloakDeployment.usernameSecret.key }}
|
||||||
passwordSecret:
|
passwordSecret:
|
||||||
name: keycloak-db-app
|
name: {{ .Values.keycloakDeployment.passwordSecret.name }}
|
||||||
key: password
|
key: {{ .Values.keycloakDeployment.passwordSecret.key }}
|
||||||
database: app
|
database: {{ .Values.keycloakDeployment.database }}
|
||||||
ingress:
|
ingress:
|
||||||
enabled: false
|
enabled: false
|
||||||
http:
|
http:
|
||||||
|
|||||||
@@ -1,3 +1,14 @@
|
|||||||
|
prefix: null
|
||||||
keycloakDeployment:
|
keycloakDeployment:
|
||||||
numInstances: 1
|
numInstances: 1
|
||||||
hostname: sso.domain.net
|
hostname: sso.domain.net
|
||||||
|
vendor: postgres
|
||||||
|
dbHost: keycloak-db-rw
|
||||||
|
dbPort: 5432
|
||||||
|
usernameSecret:
|
||||||
|
name: keycloak-db-app
|
||||||
|
key: user
|
||||||
|
passwordSecret:
|
||||||
|
name: keycloak-db-app
|
||||||
|
key: password
|
||||||
|
database: app
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
metadata:
|
metadata:
|
||||||
name: ts-keycloak
|
name: {{ .Values.prefix }}ts-keycloak
|
||||||
annotations:
|
annotations:
|
||||||
tailscale.com/funnel: "true"
|
tailscale.com/funnel: "true"
|
||||||
spec:
|
spec:
|
||||||
|
|||||||
@@ -1,2 +1,3 @@
|
|||||||
|
prefix: null
|
||||||
tailscaleIngresses:
|
tailscaleIngresses:
|
||||||
keycloakHostname: sso
|
keycloakHostname: sso
|
||||||
@@ -2,4 +2,4 @@ apiVersion: v2
|
|||||||
name: keycloak-requirements
|
name: keycloak-requirements
|
||||||
description: A Helm chart for deploying the DB used by keycloak
|
description: A Helm chart for deploying the DB used by keycloak
|
||||||
type: application
|
type: application
|
||||||
version: 0.1.0
|
version: 0.1.1
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
apiVersion: postgresql.cnpg.io/v1
|
apiVersion: postgresql.cnpg.io/v1
|
||||||
kind: Cluster
|
kind: Cluster
|
||||||
metadata:
|
metadata:
|
||||||
name: keycloak-db
|
name: {{ .Values.prefix }}keycloak-db
|
||||||
spec:
|
spec:
|
||||||
instances: {{ .Values.dbCluster.numInstances }}
|
instances: {{ .Values.dbCluster.numInstances }}
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
|
prefix: null
|
||||||
dbCluster:
|
dbCluster:
|
||||||
size: 1Gi
|
size: 1Gi
|
||||||
numInstances: 3
|
numInstances: 3
|
||||||
|
|
||||||
|
|||||||
23
vaultwarden-argocd-apps/.helmignore
Normal file
23
vaultwarden-argocd-apps/.helmignore
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
# Patterns to ignore when building packages.
|
||||||
|
# This supports shell glob matching, relative path matching, and
|
||||||
|
# negation (prefixed with !). Only one pattern per line.
|
||||||
|
.DS_Store
|
||||||
|
# Common VCS dirs
|
||||||
|
.git/
|
||||||
|
.gitignore
|
||||||
|
.bzr/
|
||||||
|
.bzrignore
|
||||||
|
.hg/
|
||||||
|
.hgignore
|
||||||
|
.svn/
|
||||||
|
# Common backup files
|
||||||
|
*.swp
|
||||||
|
*.bak
|
||||||
|
*.tmp
|
||||||
|
*.orig
|
||||||
|
*~
|
||||||
|
# Various IDEs
|
||||||
|
.project
|
||||||
|
.idea/
|
||||||
|
*.tmproj
|
||||||
|
.vscode/
|
||||||
5
vaultwarden-argocd-apps/Chart.yaml
Normal file
5
vaultwarden-argocd-apps/Chart.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
apiVersion: v2
|
||||||
|
name: vaultwarden-argocd-apps
|
||||||
|
description: A Helm chart for Kubernetes
|
||||||
|
type: application
|
||||||
|
version: 0.1.0
|
||||||
62
vaultwarden-argocd-apps/templates/_helpers.tpl
Normal file
62
vaultwarden-argocd-apps/templates/_helpers.tpl
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride }}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||||
|
{{- if contains $name .Release.Name }}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "vaultwarden-argocd-apps.chart" . }}
|
||||||
|
{{ include "vaultwarden-argocd-apps.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "vaultwarden-argocd-apps.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-argocd-apps.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create }}
|
||||||
|
{{- default (include "vaultwarden-argocd-apps.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else }}
|
||||||
|
{{- default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
48
vaultwarden-argocd-apps/templates/vaultwarden-chart.yaml
Normal file
48
vaultwarden-argocd-apps/templates/vaultwarden-chart.yaml
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden
|
||||||
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "0"
|
||||||
|
notifications.argoproj.io/subscribe.on-sync-succeeded.telegram: "-1002270587578"
|
||||||
|
spec:
|
||||||
|
project: {{ .Values.argocd.project }}
|
||||||
|
source:
|
||||||
|
repoURL: "https://guerzon.github.io/vaultwarden"
|
||||||
|
chart: vaultwarden
|
||||||
|
targetRevision: v0.29.x
|
||||||
|
helm:
|
||||||
|
releaseName: vaultwarden
|
||||||
|
valuesObject:
|
||||||
|
domain: {{ .Values.vaultwarden.domain }}
|
||||||
|
timeZone: {{ .Values.vaultwarden.timeZone }}
|
||||||
|
adminToken:
|
||||||
|
value: {{ .Values.vaultwarden.adminToken.value }}
|
||||||
|
database:
|
||||||
|
type: postgresql
|
||||||
|
existingSecret: {{ .Values.vaultwarden.dbCluster.secretName }}
|
||||||
|
existingSecretKey: uri
|
||||||
|
data:
|
||||||
|
name: {{ .Values.vaultwarden.dataPvc.name }}
|
||||||
|
size: {{ .Values.vaultwarden.dataPvc.size }}
|
||||||
|
class: {{ .Values.vaultwarden.dataPvc.storageClassName }}
|
||||||
|
accessMode: {{ .Values.vaultwarden.dataPvc.accessMode }}
|
||||||
|
attachments:
|
||||||
|
name: {{ .Values.vaultwarden.attachmentPvc.name }}
|
||||||
|
size: {{ .Values.vaultwarden.attachmentPvc.size }}
|
||||||
|
class: {{ .Values.vaultwarden.attachmentPvc.storageClassName }}
|
||||||
|
accessMode: {{ .Values.vaultwarden.attachmentPvc.accessMode }}
|
||||||
|
ingress:
|
||||||
|
enabled: false
|
||||||
|
destination:
|
||||||
|
server: {{ .Values.destination.server }}
|
||||||
|
namespace: {{ .Values.destination.namespace }}
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true # Automatically remove resources no longer in the repo
|
||||||
|
selfHeal: true # Automatically self-heal when drift is detected
|
||||||
|
syncOptions:
|
||||||
|
- ApplyOutOfSyncOnly=true
|
||||||
|
- ServerSideApply=true
|
||||||
|
- CreateNamespace=true
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-postinstall
|
||||||
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "1"
|
||||||
|
notifications.argoproj.io/subscribe.on-sync-succeeded.telegram: "-1002270587578"
|
||||||
|
spec:
|
||||||
|
project: {{ .Values.argocd.project }}
|
||||||
|
source:
|
||||||
|
repoURL: {{ .Values.argocd.postinstall.repoURL }}
|
||||||
|
targetRevision: {{ .Values.argocd.postinstall.targetRevision }}
|
||||||
|
path: {{ .Values.argocd.postinstall.path }}
|
||||||
|
helm:
|
||||||
|
releaseName: vaultwarden-postinstall
|
||||||
|
valuesObject:
|
||||||
|
tailscaleIngresses:
|
||||||
|
vaultwardenHostname: {{ .Values.tailscaleIngresses.vaultwardenHostname }}
|
||||||
|
destination:
|
||||||
|
server: {{ .Values.destination.server }}
|
||||||
|
namespace: {{ .Values.destination.namespace }}
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true # Automatically remove resources no longer in the repo
|
||||||
|
selfHeal: true # Automatically self-heal when drift is detected
|
||||||
|
syncOptions:
|
||||||
|
- ApplyOutOfSyncOnly=true
|
||||||
|
- ServerSideApply=true
|
||||||
|
- CreateNamespace=true
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-requirements
|
||||||
|
namespace: {{ .Values.argocd.namespace }}
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "-1"
|
||||||
|
notifications.argoproj.io/subscribe.on-sync-succeeded.telegram: "-1002270587578"
|
||||||
|
spec:
|
||||||
|
project: {{ .Values.argocd.project }}
|
||||||
|
source:
|
||||||
|
repoURL: {{ .Values.argocd.requirements.repoURL }}
|
||||||
|
targetRevision: {{ .Values.argocd.requirements.targetRevision }}
|
||||||
|
path: {{ .Values.argocd.requirements.path }}
|
||||||
|
helm:
|
||||||
|
releaseName: vaultwarden-requirements
|
||||||
|
valuesObject:
|
||||||
|
vaultwarden:
|
||||||
|
dbCluster:
|
||||||
|
numInstances: {{ .Values.vaultwarden.dbCluster.numInstances }}
|
||||||
|
size: {{ .Values.vaultwarden.dbCluster.size }}
|
||||||
|
dataPvc:
|
||||||
|
name: {{ .Values.vaultwarden.dataPvc.name }}
|
||||||
|
storageClassName: {{ .Values.vaultwarden.dataPvc.storageClassName }}
|
||||||
|
size: {{ .Values.vaultwarden.dataPvc.size }}
|
||||||
|
mainNamespace: {{ .Values.destination.namespace }}
|
||||||
|
destination:
|
||||||
|
server: {{ .Values.destination.server }}
|
||||||
|
namespace: {{ .Values.destination.namespace }}
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true # Automatically remove resources no longer in the repo
|
||||||
|
selfHeal: true # Automatically self-heal when drift is detected
|
||||||
|
syncOptions:
|
||||||
|
- ApplyOutOfSyncOnly=true
|
||||||
|
- ServerSideApply=true
|
||||||
|
- CreateNamespace=true
|
||||||
38
vaultwarden-argocd-apps/values.yaml
Normal file
38
vaultwarden-argocd-apps/values.yaml
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
argocd:
|
||||||
|
namespace: argocd
|
||||||
|
project: default
|
||||||
|
requirements:
|
||||||
|
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: vaultwarden-requirements
|
||||||
|
postinstall:
|
||||||
|
repoURL: "https://git.blarre.net/thomas/helm-charts.git"
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: vaultwarden-postinstall
|
||||||
|
|
||||||
|
destination:
|
||||||
|
server: "https://kubernetes.default.svc"
|
||||||
|
namespace: vaultwarden
|
||||||
|
|
||||||
|
vaultwarden:
|
||||||
|
dbCluster:
|
||||||
|
numInstances: 3
|
||||||
|
size: 10Gi
|
||||||
|
secretName: vaultwarden-db-app
|
||||||
|
dataPvc:
|
||||||
|
name: vaultwarden-data
|
||||||
|
storageClassName: ''
|
||||||
|
size: 10Gi
|
||||||
|
accessMode: "ReadWriteOnce"
|
||||||
|
attachmentPvc:
|
||||||
|
name: vaultwarden-attachments
|
||||||
|
storageClassName: 'linode-block-storage-retain-luks-vw'
|
||||||
|
size: 10Gi
|
||||||
|
accessMode: "ReadWriteOnce"
|
||||||
|
domain: "https://vaultwarden.domain.net"
|
||||||
|
timeZone: "Europe/Lisbon"
|
||||||
|
adminToken:
|
||||||
|
value:
|
||||||
|
|
||||||
|
tailscaleIngresses:
|
||||||
|
vaultwardenHostname: vaultwarden
|
||||||
23
vaultwarden-postinstall/.helmignore
Normal file
23
vaultwarden-postinstall/.helmignore
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
# Patterns to ignore when building packages.
|
||||||
|
# This supports shell glob matching, relative path matching, and
|
||||||
|
# negation (prefixed with !). Only one pattern per line.
|
||||||
|
.DS_Store
|
||||||
|
# Common VCS dirs
|
||||||
|
.git/
|
||||||
|
.gitignore
|
||||||
|
.bzr/
|
||||||
|
.bzrignore
|
||||||
|
.hg/
|
||||||
|
.hgignore
|
||||||
|
.svn/
|
||||||
|
# Common backup files
|
||||||
|
*.swp
|
||||||
|
*.bak
|
||||||
|
*.tmp
|
||||||
|
*.orig
|
||||||
|
*~
|
||||||
|
# Various IDEs
|
||||||
|
.project
|
||||||
|
.idea/
|
||||||
|
*.tmproj
|
||||||
|
.vscode/
|
||||||
5
vaultwarden-postinstall/Chart.yaml
Normal file
5
vaultwarden-postinstall/Chart.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
apiVersion: v2
|
||||||
|
name: vaultwarden-postinstall
|
||||||
|
description: A Helm chart for deploynig vaultwarden's ingress
|
||||||
|
type: application
|
||||||
|
version: 0.1.0
|
||||||
62
vaultwarden-postinstall/templates/_helpers.tpl
Normal file
62
vaultwarden-postinstall/templates/_helpers.tpl
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride }}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||||
|
{{- if contains $name .Release.Name }}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "vaultwarden-postinstall.chart" . }}
|
||||||
|
{{ include "vaultwarden-postinstall.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "vaultwarden-postinstall.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-postinstall.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create }}
|
||||||
|
{{- default (include "vaultwarden-postinstall.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else }}
|
||||||
|
{{- default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
16
vaultwarden-postinstall/templates/vaultwarden-ingress.yaml
Normal file
16
vaultwarden-postinstall/templates/vaultwarden-ingress.yaml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: ts-vaultwarden
|
||||||
|
annotations:
|
||||||
|
tailscale.com/funnel: "true"
|
||||||
|
spec:
|
||||||
|
defaultBackend:
|
||||||
|
service:
|
||||||
|
name: vaultwarden
|
||||||
|
port:
|
||||||
|
name: http
|
||||||
|
ingressClassName: tailscale
|
||||||
|
tls:
|
||||||
|
- hosts:
|
||||||
|
- {{ .Values.tailscaleIngresses.vaultwardenHostname }}
|
||||||
2
vaultwarden-postinstall/values.yaml
Normal file
2
vaultwarden-postinstall/values.yaml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
tailscaleIngresses:
|
||||||
|
vaultwardenHostname: vaultwarden
|
||||||
23
vaultwarden-requirements/.helmignore
Normal file
23
vaultwarden-requirements/.helmignore
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
# Patterns to ignore when building packages.
|
||||||
|
# This supports shell glob matching, relative path matching, and
|
||||||
|
# negation (prefixed with !). Only one pattern per line.
|
||||||
|
.DS_Store
|
||||||
|
# Common VCS dirs
|
||||||
|
.git/
|
||||||
|
.gitignore
|
||||||
|
.bzr/
|
||||||
|
.bzrignore
|
||||||
|
.hg/
|
||||||
|
.hgignore
|
||||||
|
.svn/
|
||||||
|
# Common backup files
|
||||||
|
*.swp
|
||||||
|
*.bak
|
||||||
|
*.tmp
|
||||||
|
*.orig
|
||||||
|
*~
|
||||||
|
# Various IDEs
|
||||||
|
.project
|
||||||
|
.idea/
|
||||||
|
*.tmproj
|
||||||
|
.vscode/
|
||||||
5
vaultwarden-requirements/Chart.yaml
Normal file
5
vaultwarden-requirements/Chart.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
apiVersion: v2
|
||||||
|
name: vaultwarden-requirements
|
||||||
|
description: A Helm chart for deploying the dbcluster and pvc for vaultwarden
|
||||||
|
type: application
|
||||||
|
version: 0.1.0
|
||||||
62
vaultwarden-requirements/templates/_helpers.tpl
Normal file
62
vaultwarden-requirements/templates/_helpers.tpl
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride }}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||||
|
{{- if contains $name .Release.Name }}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- else }}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "vaultwarden-requirements.chart" . }}
|
||||||
|
{{ include "vaultwarden-requirements.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "vaultwarden-requirements.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "vaultwarden-requirements.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create }}
|
||||||
|
{{- default (include "vaultwarden-requirements.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else }}
|
||||||
|
{{- default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
8
vaultwarden-requirements/templates/db-cluster.yaml
Normal file
8
vaultwarden-requirements/templates/db-cluster.yaml
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
apiVersion: postgresql.cnpg.io/v1
|
||||||
|
kind: Cluster
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-db
|
||||||
|
spec:
|
||||||
|
instances: {{ .Values.vaultwarden.dbCluster.numInstances }}
|
||||||
|
storage:
|
||||||
|
size: {{ .Values.vaultwarden.dbCluster.size }}
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
allowVolumeExpansion: true
|
||||||
|
apiVersion: storage.k8s.io/v1
|
||||||
|
kind: StorageClass
|
||||||
|
metadata:
|
||||||
|
name: linode-block-storage-retain-luks-vw
|
||||||
|
namespace: kube-system
|
||||||
|
provisioner: linodebs.csi.linode.com
|
||||||
|
reclaimPolicy: Retain
|
||||||
|
parameters:
|
||||||
|
linodebs.csi.linode.com/luks-encrypted: "true"
|
||||||
|
linodebs.csi.linode.com/luks-cipher: "aes-xts-plain64"
|
||||||
|
linodebs.csi.linode.com/luks-key-size: "512"
|
||||||
|
csi.storage.k8s.io/node-stage-secret-namespace: {{ .Values.mainNamespace }}
|
||||||
|
csi.storage.k8s.io/node-stage-secret-name: vw-data-luks-key
|
||||||
9
vaultwarden-requirements/values.yaml
Normal file
9
vaultwarden-requirements/values.yaml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
vaultwarden:
|
||||||
|
dbCluster:
|
||||||
|
numInstances: 3
|
||||||
|
size: 10Gi
|
||||||
|
dataPvc:
|
||||||
|
name: vaultwarden-data
|
||||||
|
storageClassName: ''
|
||||||
|
size: 10Gi
|
||||||
|
mainNamespace: vaultwarden
|
||||||
Reference in New Issue
Block a user