Skip to content

Commit

Permalink
add
Browse files Browse the repository at this point in the history
Signed-off-by: walnuts1018 <[email protected]>
  • Loading branch information
walnuts1018 committed Nov 2, 2024
1 parent 72734af commit 8c4c91f
Show file tree
Hide file tree
Showing 13 changed files with 141 additions and 164 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions k8s/argocdapps/zitadel/app.json5
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
name: "zitadel",
namespace: "zitadel",
}
12 changes: 12 additions & 0 deletions k8s/argocdapps/zitadel/configmap.jsonnet
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
apiVersion: 'v1',
kind: 'ConfigMap',
metadata: {
name: (import 'app.json5').name + '-config',
namespace: (import 'app.json5').namespace,
labels: (import '../../components/labels.libsonnet') + { appname: (import 'app.json5').name },
},
data: {
'config.yaml': (importstr './config/config.yaml'),
},
}
64 changes: 64 additions & 0 deletions k8s/argocdapps/zitadel/external-secret.jsonnet
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
apiVersion: 'external-secrets.io/v1beta1',
kind: 'ExternalSecret',
metadata: {
name: (import 'app.json5').name,
namespace: (import 'app.json5').namespace,
labels: (import '../../components/labels.libsonnet') + { appname: (import 'app.json5').name },
},
spec: {
secretStoreRef: {
name: 'onepassword',
kind: 'ClusterSecretStore',
},
refreshInterval: '1m',
target: {
name: $.metadata.name,
template: {
engineVersion: 'v2',
type: 'Opaque',
templateFrom: [
{
target: 'Data',
configMap: {
name: (import 'configmap.jsonnet').metadata.name,
items: [
{
key: 'config.yaml',
templateAs: 'Values',
},
],
},
},
],
data: {
masterkey: '{{ .masterkey }}',
postgres: '{{ .postgresdbpassword }}',
},
},
},
data: [
{
secretKey: 'masterkey',
remoteRef: {
key: 'zitadel',
property: 'masterkey',
},
},
{
secretKey: 'postgresdbpassword',
remoteRef: {
key: 'postgres_passwords',
property: 'postgres',
},
},
{
secretKey: 'zitadeldbpassword',
remoteRef: {
key: 'postgres_passwords',
property: 'zitadel',
},
},
],
},
}
37 changes: 0 additions & 37 deletions k8s/argocdapps/zitadel/externalsecret.yaml

This file was deleted.

9 changes: 9 additions & 0 deletions k8s/argocdapps/zitadel/helm.jsonnet
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
(import '../../components/helm.libsonnet') {
name: (import 'app.json5').name,
namespace: (import 'app.json5').namespace,

chart: 'zitadel',
repoURL: 'https://charts.zitadel.com',
targetRevision: '8.5.0',
values: (importstr 'values.yaml'),
}
69 changes: 0 additions & 69 deletions k8s/argocdapps/zitadel/helm.yaml

This file was deleted.

43 changes: 0 additions & 43 deletions k8s/argocdapps/zitadel/image-policy.yaml

This file was deleted.

15 changes: 0 additions & 15 deletions k8s/argocdapps/zitadel/kustomization.yaml

This file was deleted.

52 changes: 52 additions & 0 deletions k8s/argocdapps/zitadel/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
zitadel:
configmapConfig:
ExternalDomain: auth.walnuts.dev
TLS:
Enabled: false
ExternalPort: 443
ExternalSecure: true
masterkeySecretName: "zitadel"
configSecretName: zitadel
configSecretKey: "config.yaml"
replicaCount: 2
ingress:
enabled: true
className: "nginx"
annotations:
nginx.ingress.kubernetes.io/proxy-body-size: "0"
hosts:
- host: auth.walnuts.dev
paths:
- path: /
pathType: Prefix
env:
# - name: ZITADEL_LOG_LEVEL
# value: "debug"
metrics:
enabled: true
serviceMonitor:
enabled: true
resources:
requests:
memory: 128Mi
limits:
memory: 512Mi
affinity:
nodeAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
preference:
matchExpressions:
- key: kubernetes.io/arch
operator: In
values:
- amd64
- weight: 10
preference:
matchExpressions:
- key: kubernetes.io/hostname
operator: NotIn
values:
- donut
# image:
# tag: v2.64.1 # {"$imagepolicy": "zitadel:zitadel:tag"}

0 comments on commit 8c4c91f

Please sign in to comment.