Change umami url and add middleware
This commit is contained in:
parent
6ca563ea5a
commit
40e4e8b13e
|
@ -3,15 +3,17 @@ kind: Ingress
|
|||
metadata:
|
||||
name: umami-deployment-ingress
|
||||
namespace: asraphiel
|
||||
annotations:
|
||||
traefik.ingress.kubernetes.io/router.middlewares: asraphiel-umamijs@kubernetescrd
|
||||
spec:
|
||||
rules:
|
||||
- host: "analytics.asraphiel.dev"
|
||||
http:
|
||||
paths:
|
||||
- path: /
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: umami-deployment-service
|
||||
port:
|
||||
number: 80
|
||||
- host: "ikaros.asraphiel.dev"
|
||||
http:
|
||||
paths:
|
||||
- path: /
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: umami-deployment-service
|
||||
port:
|
||||
number: 80
|
||||
|
|
|
@ -5,3 +5,4 @@ resources:
|
|||
- ingress.yaml
|
||||
- service.yaml
|
||||
- secret.yaml
|
||||
- middleware.yaml
|
9
flux/cluster/apps/asraphiel/umami/middleware.yaml
Normal file
9
flux/cluster/apps/asraphiel/umami/middleware.yaml
Normal file
|
@ -0,0 +1,9 @@
|
|||
apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: umamijs
|
||||
namespace: asraphiel
|
||||
spec:
|
||||
replacePathRegex:
|
||||
regex: ^/script\.js
|
||||
replacement: /umami.js
|
|
@ -21,7 +21,12 @@ let
|
|||
'';
|
||||
};
|
||||
};
|
||||
|
||||
redirect = dest: {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
http2 = true;
|
||||
globalRedirect = dest;
|
||||
};
|
||||
k8sProxy = proxy "http://kubernetes.lxd:8080/";
|
||||
in {
|
||||
imports = [ ../../common ../../common/lxc.nix ];
|
||||
|
@ -52,20 +57,14 @@ in {
|
|||
|
||||
virtualHosts."s3.asraphiel.dev" = bigProxy "http://minio.lxd:9000/";
|
||||
virtualHosts."shell.s3.asraphiel.dev" = proxy "http://minio.lxd:9001/";
|
||||
virtualHosts."cdn.voidcorp.nl" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
http2 = true;
|
||||
globalRedirect = "s3.asraphiel.dev";
|
||||
};
|
||||
virtualHosts."cdn.voidcorp.nl" = redirect "s3.asraphiel.dev";
|
||||
virtualHosts."cdn.asraphiel.dev" = k8sProxy;
|
||||
|
||||
virtualHosts."registry.asraphiel.dev" = proxy "http://registry.lxd:5000/";
|
||||
virtualHosts."registrydbg.asraphiel.dev" =
|
||||
proxy "http://registry.lxd:5001/";
|
||||
virtualHosts."vaultwarden.asraphiel.dev" =
|
||||
proxy "http://vaultwarden.lxd:8000/";
|
||||
virtualHosts."analytics.asraphiel.dev" = k8sProxy;
|
||||
virtualHosts."analytics.asraphiel.dev" = redirect "ikaros.asraphiel.dev";
|
||||
virtualHosts."ikaros.asraphiel.dev" = k8sProxy;
|
||||
virtualHosts."whoami.asraphiel.dev" = k8sProxy;
|
||||
|
||||
virtualHosts."groenehartansichtkaarten.nl" = k8sProxy;
|
||||
|
|
Loading…
Reference in a new issue