2 Commits

Author SHA1 Message Date
f87f680a83 authZ+N chained 2025-02-03 16:03:41 +01:00
8939577c15 change repo scope for argo and restructure deployment 2025-02-03 15:56:46 +01:00
10 changed files with 39 additions and 80 deletions

View File

@@ -0,0 +1,20 @@
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: https-only
spec:
redirectScheme:
scheme: https
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: auth-chain
namespace: apps
spec:
chain:
middlewares:
- name: https-only
- name: authn
- name: authz

View File

@@ -8,4 +8,4 @@ resources:
- ./deployment.yaml
- ./service.yaml
- ./horizontalPodAutoScaler.yaml
- ./forwardAuth.yaml
- ./middleware.yaml

View File

@@ -1,7 +1,7 @@
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: auth-service
name: authz
spec:
forwardAuth:
address: https://gh-authz/auth/

View File

@@ -1,22 +0,0 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: gh-authz
spec:
project: generations-heritage-vv
source:
repoURL: 'https://github.com/vcscsvcscs/GenerationsHeritage'
path: deployment/authZ
targetRevision: main
kustomize:
namespace: generations-heritage
destination:
server: 'https://kubernetes.default.svc'
namespace: generations-heritage
syncPolicy:
automated:
selfHeal: true
syncOptions:
- CreateNamespace=true
- ServerSideApply=true

View File

@@ -1,22 +0,0 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: gh-backend
spec:
project: generations-heritage-vv
source:
repoURL: 'https://github.com/vcscsvcscs/GenerationsHeritage'
path: deployment/backend
targetRevision: main
kustomize:
namespace: generations-heritage
destination:
server: 'https://kubernetes.default.svc'
namespace: generations-heritage
syncPolicy:
automated:
selfHeal: true
syncOptions:
- CreateNamespace=true
- ServerSideApply=true

View File

@@ -15,3 +15,5 @@ spec:
port: 443
scheme: https
serversTransport: gh-backend
middlewares:
- name: auth-chain

View File

@@ -0,0 +1,14 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: generations-heritage
bases:
- authZ
- authN
- backend
- memgraph
resources:
- ./cert-issuer.yaml
- ./server-transport.yaml
- ./auth-chain.yaml

View File

@@ -1,22 +0,0 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: memgraph
spec:
project: generations-heritage-vv
source:
repoURL: 'https://github.com/vcscsvcscs/GenerationsHeritage'
path: deployment/memgraph
targetRevision: main
kustomize:
namespace: generations-heritage
destination:
server: 'https://kubernetes.default.svc'
namespace: generations-heritage
syncPolicy:
automated:
selfHeal: true
syncOptions:
- CreateNamespace=true
- ServerSideApply=true

View File

@@ -1,11 +0,0 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: argocd
resources:
- ./deployment/cert-issuer.yaml
- ./deployment/server-transport.yaml
- ./deployment/project-argo.yaml
- ./deployment/memgraph-argo.yaml
- ./deployment/auth-service-argo.yaml
- ./deployment/backend-argo.yaml

View File

@@ -5,7 +5,7 @@ metadata:
spec:
description: Generations heritages is a project that aims to preserve the heritage of families based on bloodlines.
sourceRepos:
- '*' # Allow all repositories
- 'https://github.com/vcscsvcscs/GenerationsHeritage'
destinations:
- namespace: 'generations-heritage'
server: '*'