Compare commits
24 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 115d5fe394 | |||
| 2afe27bfd4 | |||
| 36eb9495ef | |||
| 8e2c4f54c4 | |||
| 7a0c536ecc | |||
| 9c1eba2ad0 | |||
| b9b8463ebf | |||
| 9fe1df4c1a | |||
| e62e0c34d7 | |||
| 04bd29701e | |||
| e8638f6813 | |||
| 3e00c60c75 | |||
| fb17d6fd58 | |||
| af2545f20d | |||
| bd08eb6caf | |||
| ae12c14450 | |||
| 85d4a03eeb | |||
| 841e661627 | |||
| 2ef2952093 | |||
| 53420017d4 | |||
| 527686c11f | |||
| 1154b133e6 | |||
| ef5199102e | |||
| 88f0f328d5 |
@@ -17,6 +17,8 @@ ArgoCD homelab project
|
|||||||
| **cert-manager** | [](https://ag.hexor.cy/applications/argocd/cert-manager) |
|
| **cert-manager** | [](https://ag.hexor.cy/applications/argocd/cert-manager) |
|
||||||
| **external-secrets** | [](https://ag.hexor.cy/applications/argocd/external-secrets) |
|
| **external-secrets** | [](https://ag.hexor.cy/applications/argocd/external-secrets) |
|
||||||
| **gpu** | [](https://ag.hexor.cy/applications/argocd/gpu) |
|
| **gpu** | [](https://ag.hexor.cy/applications/argocd/gpu) |
|
||||||
|
| **kanidm** | [](https://ag.hexor.cy/applications/argocd/kanidm) |
|
||||||
|
| **keycloak** | [](https://ag.hexor.cy/applications/argocd/keycloak) |
|
||||||
| **kube-system-custom** | [](https://ag.hexor.cy/applications/argocd/kube-system-custom) |
|
| **kube-system-custom** | [](https://ag.hexor.cy/applications/argocd/kube-system-custom) |
|
||||||
| **kubernetes-dashboard** | [](https://ag.hexor.cy/applications/argocd/kubernetes-dashboard) |
|
| **kubernetes-dashboard** | [](https://ag.hexor.cy/applications/argocd/kubernetes-dashboard) |
|
||||||
| **longhorn** | [](https://ag.hexor.cy/applications/argocd/longhorn) |
|
| **longhorn** | [](https://ag.hexor.cy/applications/argocd/longhorn) |
|
||||||
@@ -62,9 +64,12 @@ ArgoCD homelab project
|
|||||||
| **sonarr-stack** | [](https://ag.hexor.cy/applications/argocd/sonarr-stack) |
|
| **sonarr-stack** | [](https://ag.hexor.cy/applications/argocd/sonarr-stack) |
|
||||||
| **stirling-pdf** | [](https://ag.hexor.cy/applications/argocd/stirling-pdf) |
|
| **stirling-pdf** | [](https://ag.hexor.cy/applications/argocd/stirling-pdf) |
|
||||||
| **syncthing** | [](https://ag.hexor.cy/applications/argocd/syncthing) |
|
| **syncthing** | [](https://ag.hexor.cy/applications/argocd/syncthing) |
|
||||||
|
| **teamspeak** | [](https://ag.hexor.cy/applications/argocd/teamspeak) |
|
||||||
| **tg-bots** | [](https://ag.hexor.cy/applications/argocd/tg-bots) |
|
| **tg-bots** | [](https://ag.hexor.cy/applications/argocd/tg-bots) |
|
||||||
| **vaultwarden** | [](https://ag.hexor.cy/applications/argocd/vaultwarden) |
|
| **vaultwarden** | [](https://ag.hexor.cy/applications/argocd/vaultwarden) |
|
||||||
| **vpn** | [](https://ag.hexor.cy/applications/argocd/vpn) |
|
| **vpn** | [](https://ag.hexor.cy/applications/argocd/vpn) |
|
||||||
|
| **web-petting** | [](https://ag.hexor.cy/applications/argocd/web-petting) |
|
||||||
|
| **wedding** | [](https://ag.hexor.cy/applications/argocd/wedding) |
|
||||||
| **xandikos** | [](https://ag.hexor.cy/applications/argocd/xandikos) |
|
| **xandikos** | [](https://ag.hexor.cy/applications/argocd/xandikos) |
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
|
|||||||
@@ -26,9 +26,9 @@ matrixRTC:
|
|||||||
host: livekit.matrix.hexor.cy
|
host: livekit.matrix.hexor.cy
|
||||||
sfu:
|
sfu:
|
||||||
enabled: true
|
enabled: true
|
||||||
manualIP: "138.201.61.182"
|
manualIP: "78.24.180.234"
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
kubernetes.io/hostname: spb.tail2fe2d.ts.net
|
||||||
exposedServices:
|
exposedServices:
|
||||||
rtcTcp:
|
rtcTcp:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -45,6 +45,14 @@ matrixRTC:
|
|||||||
## Synapse homeserver
|
## Synapse homeserver
|
||||||
synapse:
|
synapse:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
additional:
|
||||||
|
0-search-config:
|
||||||
|
config: |
|
||||||
|
user_directory:
|
||||||
|
enabled: true
|
||||||
|
search_all_users: true
|
||||||
|
prefer_local_users: true
|
||||||
|
enable_room_list_search: true
|
||||||
ingress:
|
ingress:
|
||||||
host: synapse.matrix.hexor.cy
|
host: synapse.matrix.hexor.cy
|
||||||
postgres:
|
postgres:
|
||||||
@@ -56,12 +64,12 @@ synapse:
|
|||||||
password:
|
password:
|
||||||
secret: matrix-postgres-creds
|
secret: matrix-postgres-creds
|
||||||
secretKey: synapse_db_password
|
secretKey: synapse_db_password
|
||||||
|
nodeSelector:
|
||||||
|
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
||||||
media:
|
media:
|
||||||
storage:
|
storage:
|
||||||
size: 20Gi
|
size: 20Gi
|
||||||
maxUploadSize: 100M
|
maxUploadSize: 100M
|
||||||
nodeSelector:
|
|
||||||
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
|
||||||
|
|
||||||
## Matrix Authentication Service
|
## Matrix Authentication Service
|
||||||
matrixAuthenticationService:
|
matrixAuthenticationService:
|
||||||
@@ -88,8 +96,8 @@ matrixAuthenticationService:
|
|||||||
1-oidc:
|
1-oidc:
|
||||||
configSecret: matrix-oidc-config
|
configSecret: matrix-oidc-config
|
||||||
configSecretKey: mas-oidc.yaml
|
configSecretKey: mas-oidc.yaml
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
||||||
|
|
||||||
## Element Web client
|
## Element Web client
|
||||||
elementWeb:
|
elementWeb:
|
||||||
|
|||||||
@@ -1,71 +1,5 @@
|
|||||||
---
|
---
|
||||||
apiVersion: v1
|
image: &image 'pasarguard/node:v0.4.0'
|
||||||
kind: ServiceAccount
|
|
||||||
metadata:
|
|
||||||
name: pasarguard-node
|
|
||||||
labels:
|
|
||||||
app: pasarguard-node
|
|
||||||
---
|
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
|
||||||
kind: Role
|
|
||||||
metadata:
|
|
||||||
name: pasarguard-node-configmap
|
|
||||||
labels:
|
|
||||||
app: pasarguard-node
|
|
||||||
rules:
|
|
||||||
- apiGroups: [""]
|
|
||||||
resources: ["configmaps"]
|
|
||||||
verbs: ["get", "list", "create", "update", "patch"]
|
|
||||||
- apiGroups: ["cert-manager.io"]
|
|
||||||
resources: ["certificates"]
|
|
||||||
verbs: ["get", "list", "create", "update", "patch", "delete"]
|
|
||||||
- apiGroups: [""]
|
|
||||||
resources: ["secrets"]
|
|
||||||
verbs: ["get", "list"]
|
|
||||||
- apiGroups: [""]
|
|
||||||
resources: ["services", "endpoints"]
|
|
||||||
verbs: ["get", "list", "create", "update", "patch", "delete"]
|
|
||||||
---
|
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
|
||||||
kind: RoleBinding
|
|
||||||
metadata:
|
|
||||||
name: pasarguard-node-configmap
|
|
||||||
labels:
|
|
||||||
app: pasarguard-node
|
|
||||||
roleRef:
|
|
||||||
apiGroup: rbac.authorization.k8s.io
|
|
||||||
kind: Role
|
|
||||||
name: pasarguard-node-configmap
|
|
||||||
subjects:
|
|
||||||
- kind: ServiceAccount
|
|
||||||
name: pasarguard-node
|
|
||||||
---
|
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
|
||||||
kind: ClusterRole
|
|
||||||
metadata:
|
|
||||||
name: pasarguard-node-reader
|
|
||||||
labels:
|
|
||||||
app: pasarguard-node
|
|
||||||
rules:
|
|
||||||
- apiGroups: [""]
|
|
||||||
resources: ["nodes"]
|
|
||||||
verbs: ["get", "list"]
|
|
||||||
---
|
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
|
||||||
kind: ClusterRoleBinding
|
|
||||||
metadata:
|
|
||||||
name: pasarguard-node-reader
|
|
||||||
labels:
|
|
||||||
app: pasarguard-node
|
|
||||||
roleRef:
|
|
||||||
apiGroup: rbac.authorization.k8s.io
|
|
||||||
kind: ClusterRole
|
|
||||||
name: pasarguard-node-reader
|
|
||||||
subjects:
|
|
||||||
- kind: ServiceAccount
|
|
||||||
name: pasarguard-node
|
|
||||||
namespace: pasarguard
|
|
||||||
---
|
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: DaemonSet
|
kind: DaemonSet
|
||||||
metadata:
|
metadata:
|
||||||
@@ -113,7 +47,7 @@ spec:
|
|||||||
mountPath: /scripts
|
mountPath: /scripts
|
||||||
containers:
|
containers:
|
||||||
- name: pasarguard-node
|
- name: pasarguard-node
|
||||||
image: 'pasarguard/node:v0.3.0'
|
image: *image
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
command:
|
command:
|
||||||
- /bin/sh
|
- /bin/sh
|
||||||
@@ -219,3 +153,71 @@ spec:
|
|||||||
configMap:
|
configMap:
|
||||||
name: pasarguard-scripts
|
name: pasarguard-scripts
|
||||||
defaultMode: 0755
|
defaultMode: 0755
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: pasarguard-node
|
||||||
|
labels:
|
||||||
|
app: pasarguard-node
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: Role
|
||||||
|
metadata:
|
||||||
|
name: pasarguard-node-configmap
|
||||||
|
labels:
|
||||||
|
app: pasarguard-node
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["configmaps"]
|
||||||
|
verbs: ["get", "list", "create", "update", "patch"]
|
||||||
|
- apiGroups: ["cert-manager.io"]
|
||||||
|
resources: ["certificates"]
|
||||||
|
verbs: ["get", "list", "create", "update", "patch", "delete"]
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["secrets"]
|
||||||
|
verbs: ["get", "list"]
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["services", "endpoints"]
|
||||||
|
verbs: ["get", "list", "create", "update", "patch", "delete"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: RoleBinding
|
||||||
|
metadata:
|
||||||
|
name: pasarguard-node-configmap
|
||||||
|
labels:
|
||||||
|
app: pasarguard-node
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: Role
|
||||||
|
name: pasarguard-node-configmap
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: pasarguard-node
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: pasarguard-node-reader
|
||||||
|
labels:
|
||||||
|
app: pasarguard-node
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["nodes"]
|
||||||
|
verbs: ["get", "list"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: pasarguard-node-reader
|
||||||
|
labels:
|
||||||
|
app: pasarguard-node
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: pasarguard-node-reader
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: pasarguard-node
|
||||||
|
namespace: pasarguard
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
---
|
---
|
||||||
|
image: &image 'pasarguard/panel:v3.1.0'
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
@@ -34,7 +35,7 @@ spec:
|
|||||||
mountPath: /templates/subscription
|
mountPath: /templates/subscription
|
||||||
containers:
|
containers:
|
||||||
- name: pasarguard-web
|
- name: pasarguard-web
|
||||||
image: 'pasarguard/panel:v3.0.1'
|
image: *image
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
envFrom:
|
envFrom:
|
||||||
- secretRef:
|
- secretRef:
|
||||||
|
|||||||
@@ -22,9 +22,13 @@ spec:
|
|||||||
claimName: web-petting-data
|
claimName: web-petting-data
|
||||||
containers:
|
containers:
|
||||||
- name: web-petting
|
- name: web-petting
|
||||||
image: ultradesu/web-petting:v0.1.0
|
image: ultradesu/web-petting:0.1.0
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
args:
|
args:
|
||||||
|
# - "tail"
|
||||||
|
# - "-F"
|
||||||
|
# - "/1"
|
||||||
|
- "web-petting"
|
||||||
- "-l"
|
- "-l"
|
||||||
- "0.0.0.0:3000"
|
- "0.0.0.0:3000"
|
||||||
ports:
|
ports:
|
||||||
@@ -43,11 +47,3 @@ spec:
|
|||||||
limits:
|
limits:
|
||||||
memory: "128Mi"
|
memory: "128Mi"
|
||||||
cpu: "150m"
|
cpu: "150m"
|
||||||
securityContext:
|
|
||||||
runAsNonRoot: true
|
|
||||||
runAsUser: 1000
|
|
||||||
allowPrivilegeEscalation: false
|
|
||||||
readOnlyRootFilesystem: true
|
|
||||||
capabilities:
|
|
||||||
drop:
|
|
||||||
- ALL
|
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: kanidm
|
||||||
|
namespace: argocd
|
||||||
|
spec:
|
||||||
|
project: core
|
||||||
|
destination:
|
||||||
|
namespace: kanidm
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
source:
|
||||||
|
repoURL: ssh://git@gt.hexor.cy:30022/ab/homelab.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: k8s/core/kanidm
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
selfHeal: true
|
||||||
|
prune: true
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- ServerSideApply=true
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
---
|
||||||
|
apiVersion: cert-manager.io/v1
|
||||||
|
kind: Certificate
|
||||||
|
metadata:
|
||||||
|
name: kanidm-tls
|
||||||
|
spec:
|
||||||
|
secretName: kanidm-tls
|
||||||
|
issuerRef:
|
||||||
|
name: letsencrypt
|
||||||
|
kind: ClusterIssuer
|
||||||
|
dnsNames:
|
||||||
|
- auth.hexor.cy
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: kanidm-config
|
||||||
|
data:
|
||||||
|
server.toml: |
|
||||||
|
bindaddress = "[::]:443"
|
||||||
|
db_path = "/data/kanidm.db"
|
||||||
|
tls_chain = "/certs/tls.crt"
|
||||||
|
tls_key = "/certs/tls.key"
|
||||||
|
domain = "auth.hexor.cy"
|
||||||
|
origin = "https://auth.hexor.cy"
|
||||||
|
log_level = "info"
|
||||||
|
|
||||||
|
[online_backup]
|
||||||
|
path = "/data/backups/"
|
||||||
|
schedule = "00 22 * * *"
|
||||||
|
versions = 7
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
apiVersion: traefik.io/v1alpha1
|
||||||
|
kind: IngressRoute
|
||||||
|
metadata:
|
||||||
|
name: kanidm
|
||||||
|
annotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt
|
||||||
|
spec:
|
||||||
|
entryPoints:
|
||||||
|
- websecure
|
||||||
|
routes:
|
||||||
|
- match: Host(`auth.hexor.cy`)
|
||||||
|
kind: Rule
|
||||||
|
services:
|
||||||
|
- name: kanidm
|
||||||
|
port: 443
|
||||||
|
scheme: https
|
||||||
|
serversTransport: kanidm-transport
|
||||||
|
tls:
|
||||||
|
secretName: kanidm-ingress-tls
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
|
||||||
|
resources:
|
||||||
|
- app.yaml
|
||||||
|
- configmap.yaml
|
||||||
|
- certificate.yaml
|
||||||
|
- statefulset.yaml
|
||||||
|
- service.yaml
|
||||||
|
- ingress.yaml
|
||||||
|
- servers-transport.yaml
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
apiVersion: traefik.io/v1alpha1
|
||||||
|
kind: ServersTransport
|
||||||
|
metadata:
|
||||||
|
name: kanidm-transport
|
||||||
|
spec:
|
||||||
|
insecureSkipVerify: true
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: kanidm
|
||||||
|
labels:
|
||||||
|
app: kanidm
|
||||||
|
spec:
|
||||||
|
ports:
|
||||||
|
- name: https
|
||||||
|
port: 443
|
||||||
|
targetPort: 443
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
app: kanidm
|
||||||
@@ -0,0 +1,86 @@
|
|||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: StatefulSet
|
||||||
|
metadata:
|
||||||
|
name: kanidm
|
||||||
|
labels:
|
||||||
|
app: kanidm
|
||||||
|
spec:
|
||||||
|
serviceName: kanidm
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: kanidm
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: kanidm
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 1000
|
||||||
|
runAsGroup: 1000
|
||||||
|
fsGroup: 1000
|
||||||
|
containers:
|
||||||
|
- name: kanidm
|
||||||
|
image: kanidm/server:1.9.3
|
||||||
|
ports:
|
||||||
|
- containerPort: 443
|
||||||
|
name: https
|
||||||
|
protocol: TCP
|
||||||
|
volumeMounts:
|
||||||
|
- name: kanidm-data
|
||||||
|
mountPath: /data
|
||||||
|
- name: kanidm-config
|
||||||
|
mountPath: /data/server.toml
|
||||||
|
subPath: server.toml
|
||||||
|
readOnly: true
|
||||||
|
- name: kanidm-tls
|
||||||
|
mountPath: /certs
|
||||||
|
readOnly: true
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
memory: "128Mi"
|
||||||
|
cpu: "100m"
|
||||||
|
limits:
|
||||||
|
memory: "512Mi"
|
||||||
|
cpu: "500m"
|
||||||
|
readinessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /status
|
||||||
|
port: 443
|
||||||
|
scheme: HTTPS
|
||||||
|
initialDelaySeconds: 5
|
||||||
|
periodSeconds: 10
|
||||||
|
livenessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /status
|
||||||
|
port: 443
|
||||||
|
scheme: HTTPS
|
||||||
|
initialDelaySeconds: 15
|
||||||
|
periodSeconds: 30
|
||||||
|
securityContext:
|
||||||
|
allowPrivilegeEscalation: false
|
||||||
|
readOnlyRootFilesystem: false
|
||||||
|
runAsUser: 1000
|
||||||
|
runAsGroup: 1000
|
||||||
|
volumes:
|
||||||
|
- name: kanidm-config
|
||||||
|
configMap:
|
||||||
|
name: kanidm-config
|
||||||
|
- name: kanidm-tls
|
||||||
|
secret:
|
||||||
|
secretName: kanidm-tls
|
||||||
|
nodeSelector:
|
||||||
|
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
||||||
|
tolerations:
|
||||||
|
- key: node-role.kubernetes.io/master
|
||||||
|
effect: NoSchedule
|
||||||
|
volumeClaimTemplates:
|
||||||
|
- metadata:
|
||||||
|
name: kanidm-data
|
||||||
|
spec:
|
||||||
|
accessModes: ["ReadWriteOnce"]
|
||||||
|
storageClassName: longhorn
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: keycloak
|
||||||
|
namespace: argocd
|
||||||
|
spec:
|
||||||
|
project: core
|
||||||
|
destination:
|
||||||
|
namespace: keycloak
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
source:
|
||||||
|
repoURL: ssh://git@gt.hexor.cy:30022/ab/homelab.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: k8s/core/keycloak
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
selfHeal: true
|
||||||
|
prune: true
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- ServerSideApply=true
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
---
|
||||||
|
apiVersion: external-secrets.io/v1
|
||||||
|
kind: ExternalSecret
|
||||||
|
metadata:
|
||||||
|
name: keycloak-creds
|
||||||
|
spec:
|
||||||
|
target:
|
||||||
|
name: keycloak-creds
|
||||||
|
deletionPolicy: Delete
|
||||||
|
template:
|
||||||
|
type: Opaque
|
||||||
|
data:
|
||||||
|
KC_DB_USERNAME: keycloak
|
||||||
|
KC_DB_PASSWORD: |-
|
||||||
|
{{ .db_password }}
|
||||||
|
KC_BOOTSTRAP_ADMIN_USERNAME: admin
|
||||||
|
KC_BOOTSTRAP_ADMIN_PASSWORD: |-
|
||||||
|
{{ .admin_password }}
|
||||||
|
data:
|
||||||
|
- secretKey: db_password
|
||||||
|
sourceRef:
|
||||||
|
storeRef:
|
||||||
|
name: vaultwarden-login
|
||||||
|
kind: ClusterSecretStore
|
||||||
|
remoteRef:
|
||||||
|
conversionStrategy: Default
|
||||||
|
decodingStrategy: None
|
||||||
|
metadataPolicy: None
|
||||||
|
key: 2a9deb39-ef22-433e-a1be-df1555625e22
|
||||||
|
property: fields[18].value
|
||||||
|
- secretKey: admin_password
|
||||||
|
sourceRef:
|
||||||
|
storeRef:
|
||||||
|
name: vaultwarden-login
|
||||||
|
kind: ClusterSecretStore
|
||||||
|
remoteRef:
|
||||||
|
conversionStrategy: Default
|
||||||
|
decodingStrategy: None
|
||||||
|
metadataPolicy: None
|
||||||
|
key: 9422b636-a91d-40e4-bf98-925b2a3f831d
|
||||||
|
property: login.password
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
|
||||||
|
resources:
|
||||||
|
- app.yaml
|
||||||
|
- external-secrets.yaml
|
||||||
|
|
||||||
|
helmCharts:
|
||||||
|
- name: keycloakx
|
||||||
|
repo: https://codecentric.github.io/helm-charts
|
||||||
|
version: 7.1.11
|
||||||
|
releaseName: keycloak
|
||||||
|
namespace: keycloak
|
||||||
|
valuesFile: values.yaml
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
replicas: 1
|
||||||
|
|
||||||
|
image:
|
||||||
|
repository: quay.io/keycloak/keycloak
|
||||||
|
tag: "26.5.6"
|
||||||
|
|
||||||
|
command:
|
||||||
|
- "/opt/keycloak/bin/kc.sh"
|
||||||
|
- "start"
|
||||||
|
- "--http-port=8080"
|
||||||
|
- "--hostname-strict=false"
|
||||||
|
- "--proxy-headers=xforwarded"
|
||||||
|
|
||||||
|
extraEnvFrom: |
|
||||||
|
- secretRef:
|
||||||
|
name: keycloak-creds
|
||||||
|
|
||||||
|
extraEnv: |
|
||||||
|
- name: KC_HOSTNAME
|
||||||
|
value: auth.hexor.cy
|
||||||
|
- name: JAVA_OPTS_APPEND
|
||||||
|
value: "-Djgroups.dns.query=keycloak-headless.keycloak.svc"
|
||||||
|
|
||||||
|
dbchecker:
|
||||||
|
enabled: true
|
||||||
|
|
||||||
|
database:
|
||||||
|
vendor: postgres
|
||||||
|
hostname: psql.psql.svc
|
||||||
|
port: 5432
|
||||||
|
database: keycloak
|
||||||
|
existingSecret: keycloak-creds
|
||||||
|
existingSecretKey: KC_DB_PASSWORD
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
ingressClassName: traefik
|
||||||
|
annotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt
|
||||||
|
traefik.ingress.kubernetes.io/router.middlewares: kube-system-https-redirect@kubernetescrd
|
||||||
|
rules:
|
||||||
|
- host: auth.hexor.cy
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
tls:
|
||||||
|
- secretName: keycloak-tls
|
||||||
|
hosts:
|
||||||
|
- auth.hexor.cy
|
||||||
|
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 200m
|
||||||
|
memory: 512Mi
|
||||||
|
limits:
|
||||||
|
cpu: "1"
|
||||||
|
memory: 1Gi
|
||||||
|
|
||||||
|
nodeSelector:
|
||||||
|
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
||||||
|
|
||||||
|
tolerations:
|
||||||
|
- key: node-role.kubernetes.io/master
|
||||||
|
effect: NoSchedule
|
||||||
@@ -135,6 +135,8 @@ spec:
|
|||||||
{{ .furumi }}
|
{{ .furumi }}
|
||||||
USER_furumi_dev: |-
|
USER_furumi_dev: |-
|
||||||
{{ .furumi_dev }}
|
{{ .furumi_dev }}
|
||||||
|
USER_keycloak: |-
|
||||||
|
{{ .keycloak }}
|
||||||
data:
|
data:
|
||||||
- secretKey: authentik
|
- secretKey: authentik
|
||||||
sourceRef:
|
sourceRef:
|
||||||
@@ -323,4 +325,14 @@ spec:
|
|||||||
metadataPolicy: None
|
metadataPolicy: None
|
||||||
key: 2a9deb39-ef22-433e-a1be-df1555625e22
|
key: 2a9deb39-ef22-433e-a1be-df1555625e22
|
||||||
property: fields[17].value
|
property: fields[17].value
|
||||||
|
- secretKey: keycloak
|
||||||
|
sourceRef:
|
||||||
|
storeRef:
|
||||||
|
name: vaultwarden-login
|
||||||
|
kind: ClusterSecretStore
|
||||||
|
remoteRef:
|
||||||
|
conversionStrategy: Default
|
||||||
|
decodingStrategy: None
|
||||||
|
metadataPolicy: None
|
||||||
|
key: 2a9deb39-ef22-433e-a1be-df1555625e22
|
||||||
|
property: fields[18].value
|
||||||
|
|||||||
Reference in New Issue
Block a user