Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 3d99719a06 | |||
| c850ad291a | |||
| 4228217497 | |||
| df2e2ec68d | |||
| 180fd33ffc | |||
| bbb8ca0323 | |||
| ec91419b36 | |||
| 1384b96742 | |||
| ab138b033a | |||
| 968e633bf8 | |||
| aa6c02f60b | |||
| 60423333fe | |||
| 4026adc04a | |||
| 94669590b1 | |||
| cf6223f0b5 | |||
| 89ade00efb | |||
| 4f67181637 | |||
| 2bd3d91595 |
@@ -18,6 +18,7 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
app: llamacpp
|
app: llamacpp
|
||||||
spec:
|
spec:
|
||||||
|
dnsPolicy: Default
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
kubernetes.io/hostname: ai.tail2fe2d.ts.net
|
kubernetes.io/hostname: ai.tail2fe2d.ts.net
|
||||||
tolerations:
|
tolerations:
|
||||||
|
|||||||
@@ -53,8 +53,8 @@ spec:
|
|||||||
upstream_oauth2:
|
upstream_oauth2:
|
||||||
providers:
|
providers:
|
||||||
- id: 001KKV4EKY7KG98W2M9T806K6A
|
- id: 001KKV4EKY7KG98W2M9T806K6A
|
||||||
human_name: Authentik
|
human_name: SSO Login
|
||||||
issuer: https://idm.hexor.cy/application/o/matrix/
|
issuer: https://auth.hexor.cy/auth/realms/hexor
|
||||||
client_id: "{{ .oauth_client_id }}"
|
client_id: "{{ .oauth_client_id }}"
|
||||||
client_secret: "{{ .oauth_client_secret }}"
|
client_secret: "{{ .oauth_client_secret }}"
|
||||||
token_endpoint_auth_method: client_secret_post
|
token_endpoint_auth_method: client_secret_post
|
||||||
@@ -93,3 +93,4 @@ spec:
|
|||||||
metadataPolicy: None
|
metadataPolicy: None
|
||||||
key: ca76867f-49f3-4a30-9ef3-b05af35ee49a
|
key: ca76867f-49f3-4a30-9ef3-b05af35ee49a
|
||||||
property: fields[1].value
|
property: fields[1].value
|
||||||
|
on_conflict: replace
|
||||||
|
|||||||
@@ -18,8 +18,8 @@ spec:
|
|||||||
"openid_connect": {
|
"openid_connect": {
|
||||||
"APPS": [
|
"APPS": [
|
||||||
{
|
{
|
||||||
"provider_id": "authentik",
|
"provider_id": "keycloak",
|
||||||
"name": "Authentik",
|
"name": "Keycloak",
|
||||||
"client_id": "{{ .oauth_id }}",
|
"client_id": "{{ .oauth_id }}",
|
||||||
"secret": "{{ .oauth_secret }}",
|
"secret": "{{ .oauth_secret }}",
|
||||||
"settings": {
|
"settings": {
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ spec:
|
|||||||
mountPath: /scripts
|
mountPath: /scripts
|
||||||
containers:
|
containers:
|
||||||
- name: pasarguard-node
|
- name: pasarguard-node
|
||||||
image: pasarguard/node:v0.5.0
|
image: pasarguard/node:v0.5.2
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
command:
|
command:
|
||||||
- /bin/sh
|
- /bin/sh
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ spec:
|
|||||||
mountPath: /templates/subscription
|
mountPath: /templates/subscription
|
||||||
containers:
|
containers:
|
||||||
- name: pasarguard-web
|
- name: pasarguard-web
|
||||||
image: pasarguard/panel:v4.0.2
|
image: pasarguard/panel:v5.0.1
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
envFrom:
|
envFrom:
|
||||||
- secretRef:
|
- secretRef:
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ resources:
|
|||||||
- nfs-storage.yaml
|
- nfs-storage.yaml
|
||||||
- coredns-internal-resolve.yaml
|
- coredns-internal-resolve.yaml
|
||||||
- https-middleware.yaml
|
- https-middleware.yaml
|
||||||
|
- node-external-ip-labeler.yaml
|
||||||
|
|
||||||
helmCharts:
|
helmCharts:
|
||||||
- name: csi-driver-nfs
|
- name: csi-driver-nfs
|
||||||
@@ -15,4 +16,3 @@ helmCharts:
|
|||||||
namespace: kube-system
|
namespace: kube-system
|
||||||
#valuesFile: values.yaml
|
#valuesFile: values.yaml
|
||||||
includeCRDs: true
|
includeCRDs: true
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,173 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["nodes"]
|
||||||
|
verbs: ["get", "list", "patch", "update"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: Role
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
rules:
|
||||||
|
- apiGroups: ["batch"]
|
||||||
|
resources: ["jobs"]
|
||||||
|
verbs: ["get", "list", "watch", "create", "update", "patch", "delete"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: RoleBinding
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: Role
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
---
|
||||||
|
apiVersion: batch/v1
|
||||||
|
kind: CronJob
|
||||||
|
metadata:
|
||||||
|
name: node-external-ip-labeler
|
||||||
|
namespace: kube-system
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
spec:
|
||||||
|
schedule: "17 3 * * *"
|
||||||
|
concurrencyPolicy: Forbid
|
||||||
|
successfulJobsHistoryLimit: 3
|
||||||
|
failedJobsHistoryLimit: 3
|
||||||
|
jobTemplate:
|
||||||
|
spec:
|
||||||
|
backoffLimit: 1
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
spec:
|
||||||
|
serviceAccountName: node-external-ip-labeler
|
||||||
|
restartPolicy: Never
|
||||||
|
tolerations:
|
||||||
|
- operator: Exists
|
||||||
|
containers:
|
||||||
|
- name: fanout
|
||||||
|
image: bitnami/kubectl:latest
|
||||||
|
imagePullPolicy: IfNotPresent
|
||||||
|
command:
|
||||||
|
- /bin/bash
|
||||||
|
- -lc
|
||||||
|
args:
|
||||||
|
- |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
clean_name() {
|
||||||
|
echo "$1" \
|
||||||
|
| tr '[:upper:]' '[:lower:]' \
|
||||||
|
| tr -c 'a-z0-9-' '-' \
|
||||||
|
| sed 's/^-*//;s/-*$//' \
|
||||||
|
| cut -c1-45
|
||||||
|
}
|
||||||
|
|
||||||
|
for NODE_NAME in $(kubectl get nodes -o jsonpath='{range .items[*]}{.metadata.name}{"\n"}{end}'); do
|
||||||
|
NODE_CLEAN="$(clean_name "${NODE_NAME}")"
|
||||||
|
JOB_NAME="node-external-ip-${NODE_CLEAN}"
|
||||||
|
|
||||||
|
kubectl delete job "${JOB_NAME}" -n kube-system --ignore-not-found=true --wait=true --timeout=60s
|
||||||
|
|
||||||
|
cat <<EOF | kubectl apply -f -
|
||||||
|
apiVersion: batch/v1
|
||||||
|
kind: Job
|
||||||
|
metadata:
|
||||||
|
name: ${JOB_NAME}
|
||||||
|
namespace: kube-system
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
target-node: "${NODE_CLEAN}"
|
||||||
|
spec:
|
||||||
|
ttlSecondsAfterFinished: 86400
|
||||||
|
backoffLimit: 2
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: node-external-ip-labeler
|
||||||
|
target-node: "${NODE_CLEAN}"
|
||||||
|
spec:
|
||||||
|
serviceAccountName: node-external-ip-labeler
|
||||||
|
nodeName: "${NODE_NAME}"
|
||||||
|
hostNetwork: true
|
||||||
|
dnsPolicy: ClusterFirstWithHostNet
|
||||||
|
restartPolicy: Never
|
||||||
|
tolerations:
|
||||||
|
- operator: Exists
|
||||||
|
containers:
|
||||||
|
- name: label-node
|
||||||
|
image: bitnami/kubectl:latest
|
||||||
|
imagePullPolicy: IfNotPresent
|
||||||
|
env:
|
||||||
|
- name: NODE_NAME
|
||||||
|
value: "${NODE_NAME}"
|
||||||
|
command:
|
||||||
|
- /bin/bash
|
||||||
|
- -lc
|
||||||
|
args:
|
||||||
|
- |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
json_ip() {
|
||||||
|
sed -n 's/.*"ip"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p'
|
||||||
|
}
|
||||||
|
|
||||||
|
IPV4="\$(curl -fsS --connect-timeout 10 --max-time 30 'https://api.ipify.org?format=json' | json_ip)"
|
||||||
|
IP64="\$(curl -fsS --connect-timeout 10 --max-time 30 'https://api64.ipify.org?format=json' | json_ip || true)"
|
||||||
|
|
||||||
|
if [ -z "\${IPV4}" ]; then
|
||||||
|
echo "Unable to detect external IPv4 for node ${NODE_NAME}"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
kubectl label node "${NODE_NAME}" external-ipv4="\${IPV4}" --overwrite
|
||||||
|
kubectl annotate node "${NODE_NAME}" homelab.hexor.cy/external-ipv4="\${IPV4}" --overwrite
|
||||||
|
|
||||||
|
if echo "\${IP64}" | grep -q ':'; then
|
||||||
|
kubectl annotate node "${NODE_NAME}" homelab.hexor.cy/external-ipv6="\${IP64}" --overwrite
|
||||||
|
elif [ -n "\${IP64}" ]; then
|
||||||
|
kubectl annotate node "${NODE_NAME}" homelab.hexor.cy/external-ipv4-api64="\${IP64}" --overwrite
|
||||||
|
fi
|
||||||
|
EOF
|
||||||
|
done
|
||||||
@@ -13,7 +13,7 @@ resources:
|
|||||||
helmCharts:
|
helmCharts:
|
||||||
- name: pgadmin4
|
- name: pgadmin4
|
||||||
repo: https://helm.runix.net
|
repo: https://helm.runix.net
|
||||||
version: 1.50.0
|
version: 1.64.0
|
||||||
releaseName: pgmanager
|
releaseName: pgmanager
|
||||||
namespace: psql
|
namespace: psql
|
||||||
valuesFile: pgadmin4-values.yaml
|
valuesFile: pgadmin4-values.yaml
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ spec:
|
|||||||
spec:
|
spec:
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
#kubernetes.io/hostname: home.homenet
|
#kubernetes.io/hostname: home.homenet
|
||||||
kubernetes.io/hostname: master.tail2fe2d.ts.net
|
kubernetes.io/hostname: music.tail2fe2d.ts.net
|
||||||
terminationGracePeriodSeconds: 10
|
terminationGracePeriodSeconds: 10
|
||||||
containers:
|
containers:
|
||||||
- name: prom-a2s-exporter
|
- name: prom-a2s-exporter
|
||||||
|
|||||||
@@ -46,18 +46,49 @@ oauth2_applications = {
|
|||||||
post_logout_redirect_uris = ["https://ai.hexor.cy/*"]
|
post_logout_redirect_uris = ["https://ai.hexor.cy/*"]
|
||||||
}
|
}
|
||||||
FuruMusic = {
|
FuruMusic = {
|
||||||
redirect_uris = ["https://music.hexor.cy/auth/oidc/callback"]
|
redirect_uris = ["https://music.hexor.cy/auth/oidc/callback", "https://music.hexor.cy/auth/mobile/oidc/callback"]
|
||||||
web_origins = ["https://music.hexor.cy"]
|
web_origins = ["https://music.hexor.cy"]
|
||||||
post_logout_redirect_uris = ["https://music.hexor.cy/*"]
|
post_logout_redirect_uris = ["https://music.hexor.cy/*"]
|
||||||
}
|
}
|
||||||
FuruMusic-dev = {
|
FuruMusic-dev = {
|
||||||
redirect_uris = ["https://music-dev.hexor.cy/auth/oidc/callback", "http://127.0.0.1:3000/auth/oidc/callback", "http://10.0.5.103:3000/auth/oidc/callback"]
|
redirect_uris = ["http://127.0.0.1:3000/auth/oidc/callback", "http://10.0.5.104:3000/auth/oidc/callback", "http://10.0.5.104:3000/auth/mobile/oidc/callback"]
|
||||||
web_origins = ["https://music-dev.hexor.cy", "http://127.0.0.1:3000", "http://10.0.5.103:3000"]
|
web_origins = ["http://127.0.0.1:3000", "http://10.0.5.104:3000"]
|
||||||
post_logout_redirect_uris = ["https://music-dev.hexor.cy/*", "http://127.0.0.1:3000/*", "http://10.0.5.103:3000/*"]
|
post_logout_redirect_uris = ["http://127.0.0.1:3000/*", "http://10.0.5.104:3000/*"]
|
||||||
}
|
}
|
||||||
Web-Petting = {
|
Web-Petting = {
|
||||||
redirect_uris = ["https://pet.hexor.cy/admin/oidc/callback", "https://xn--l1acako8eb.xn--p1ai/admin/oidc/callback", "https://мурняня.рф/admin/oidc/callback"]
|
redirect_uris = ["https://pet.hexor.cy/admin/oidc/callback", "https://xn--l1acako8eb.xn--p1ai/admin/oidc/callback", "https://мурняня.рф/admin/oidc/callback"]
|
||||||
web_origins = ["https://pet.hexor.cy", "https://xn--l1acako8eb.xn--p1ai", "https://мурняня.рф", ]
|
web_origins = ["https://pet.hexor.cy", "https://xn--l1acako8eb.xn--p1ai", "https://мурняня.рф", ]
|
||||||
post_logout_redirect_uris = ["https://pet.hexor.cy/*", "https://xn--l1acako8eb.xn--p1ai/*", "https://мурняня.рф/*"]
|
post_logout_redirect_uris = ["https://pet.hexor.cy/*", "https://xn--l1acako8eb.xn--p1ai/*", "https://мурняня.рф/*"]
|
||||||
}
|
}
|
||||||
|
Paperless-ngx = {
|
||||||
|
redirect_uris = ["https://docs.hexor.cy/accounts/oidc/authentik/login/callback/"]
|
||||||
|
web_origins = ["https://docs.hexor.cy"]
|
||||||
|
post_logout_redirect_uris = ["https://docs.hexor.cy/*"]
|
||||||
|
}
|
||||||
|
Immich = {
|
||||||
|
redirect_uris = [
|
||||||
|
"https://photos.hexor.cy/auth/login",
|
||||||
|
"https://photos.hexor.cy/user-settings",
|
||||||
|
"app.immich:///oauth-callback",
|
||||||
|
"http://photos.homenet:30283/auth/login",
|
||||||
|
"http://photos.homenet:30283/user-settings"
|
||||||
|
]
|
||||||
|
web_origins = ["https://photos.hexor.cy", "http://photos.homenet:30283"]
|
||||||
|
post_logout_redirect_uris = ["https://photos.hexor.cy/*", "http://photos.homenet:30283/*"]
|
||||||
|
}
|
||||||
|
HomeAssistant-LMS = {
|
||||||
|
redirect_uris = ["http://ha-lms:8123/auth/oidc/callback", "http://ha-lms.homenet:8123/auth/oidc/callback"]
|
||||||
|
web_origins = ["http://ha-lms:8123", "http://ha-lms.homenet:8123"]
|
||||||
|
post_logout_redirect_uris = ["http://ha-lms:8123/*", "http://ha-lms.homenet:8123/*"]
|
||||||
|
}
|
||||||
|
HomeAssistant-LND = {
|
||||||
|
redirect_uris = ["http://ha-london:8123/auth/oidc/callback", "http://ha-london.tail2fe2d.ts.net:8123/auth/oidc/callback"]
|
||||||
|
web_origins = ["http://ha-london:8123", "http://ha-london.tail2fe2d.ts.net:8123"]
|
||||||
|
post_logout_redirect_uris = ["http://ha-london:8123/*", "http://ha-london.tail2fe2d.ts.net:8123/*"]
|
||||||
|
}
|
||||||
|
Matrix-Chat = {
|
||||||
|
redirect_uris = ["https://auth.matrix.hexor.cy/upstream/callback/001KKV4EKY7KG98W2M9T806K6A"]
|
||||||
|
web_origins = ["https://auth.matrix.hexor.cy"]
|
||||||
|
post_logout_redirect_uris = ["https://auth.matrix.hexor.cy/*"]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user