rename old cluster

This commit is contained in:
Vivian 2022-12-28 20:26:45 +01:00
parent 18f40825a8
commit 8549fe2789
58 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,32 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: umami
namespace: olympus
labels:
app: umami
spec:
replicas: 1
selector:
matchLabels:
app: umami
template:
metadata:
labels:
app: umami
spec:
containers:
- name: umami
imagePullPolicy: IfNotPresent
image: ghcr.io/mikecao/umami:postgresql-v1.31.0
ports:
- containerPort: 3000
name: web
env:
- name: DATABASE_TYPE
value: postgres
- name: DATABASE_URL
value: "postgresql://umami@10.42.42.26/umami"
envFrom:
- secretRef:
name: umami

View file

@ -0,0 +1,17 @@
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: umami
namespace: olympus
spec:
refreshInterval: "5m"
secretStoreRef:
name: vault
kind: ClusterSecretStore
target:
name: umami
data:
- secretKey: HASH_SALT
remoteRef:
key: olympus/umami
property: hash_salt

View file

@ -0,0 +1,19 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: umami
namespace: olympus
annotations:
traefik.ingress.kubernetes.io/router.middlewares: olympus-umamijs@kubernetescrd
spec:
rules:
- host: "msg.0x76.dev"
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: umami
port:
number: 80

View file

@ -0,0 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- deployment.yaml
- external-secret.yaml
- ingress.yaml
- svc.yaml
- middleware.yaml

View file

@ -0,0 +1,9 @@
apiVersion: traefik.containo.us/v1alpha1
kind: Middleware
metadata:
name: umamijs
namespace: olympus
spec:
replacePathRegex:
regex: ^/script\.js
replacement: /umami.js

View file

@ -0,0 +1,12 @@
apiVersion: v1
kind: Service
metadata:
name: umami
namespace: olympus
spec:
selector:
app: umami
ports:
- protocol: TCP
port: 80
targetPort: web