camtiler: unify to cam.k-space.ee

This commit is contained in:
rasmus 2024-08-03 05:02:29 +03:00
parent 8876300dc4
commit 9b2c655a02
3 changed files with 22 additions and 15 deletions

View File

@ -4,7 +4,7 @@ Camtiler is the umbrella name for our homegrown camera surveilance system.
Everything besides [Camera](#camera)s is deployed with Kubernetes. Everything besides [Camera](#camera)s is deployed with Kubernetes.
## Components ## Components
![cams.graphviz.svg](cams.graphviz.svg) ![cameras.graphviz.svg](cameras.graphviz.svg)
<!-- Manually rendered with https://dreampuf.github.io/GraphvizOnline <!-- Manually rendered with https://dreampuf.github.io/GraphvizOnline
digraph G { digraph G {
"camera-operator" -> "camera-motion-detect" [label="deploys"] "camera-operator" -> "camera-motion-detect" [label="deploys"]

View File

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 7.8 KiB

View File

@ -5,7 +5,7 @@ metadata:
name: sso name: sso
spec: spec:
displayName: Cameras displayName: Cameras
uri: 'https://cams.k-space.ee/tiled' uri: 'https://cam.k-space.ee/tiled'
allowedGroups: allowedGroups:
- k-space:floor - k-space:floor
- k-space:friends - k-space:friends
@ -17,21 +17,12 @@ metadata:
annotations: annotations:
kubernetes.io/ingress.class: traefik kubernetes.io/ingress.class: traefik
traefik.ingress.kubernetes.io/router.entrypoints: websecure traefik.ingress.kubernetes.io/router.entrypoints: websecure
traefik.ingress.kubernetes.io/router.middlewares: camtiler-sso@kubernetescrd,camtiler-redirect@kubernetescrd traefik.ingress.kubernetes.io/router.middlewares: camtiler-sso@kubernetescrd
traefik.ingress.kubernetes.io/router.tls: "true" traefik.ingress.kubernetes.io/router.tls: "true"
external-dns.alpha.kubernetes.io/target: traefik.k-space.ee external-dns.alpha.kubernetes.io/target: traefik.k-space.ee
external-dns.alpha.kubernetes.io/hostname: cams.k-space.ee,cam.k-space.ee
spec: spec:
rules: rules:
- host: cams.k-space.ee
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: logmower-frontend
port:
number: 8080
- host: cam.k-space.ee - host: cam.k-space.ee
http: http:
paths: paths:
@ -70,9 +61,25 @@ spec:
apiVersion: traefik.io/v1alpha1 apiVersion: traefik.io/v1alpha1
kind: Middleware kind: Middleware
metadata: metadata:
name: redirect name: cams-redirect
spec: spec:
redirectRegex: redirectRegex:
regex: ^https://cams.k-space.ee/(.*)$ regex: ^https://cams.k-space.ee/(.*)$
replacement: https://cam.k-space.ee/$1 replacement: https://cam.k-space.ee/$1
permanent: false permanent: true
---
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: cams
spec:
entryPoints:
- websecure
routes:
- match: Host(`cams.k-space.ee`)
kind: Rule
middlewares:
- name: cams-redirect
services:
- kind: TraefikService
name: api@internal