add nginx service

This commit is contained in:
Mans Ziesel 2025-01-17 14:39:13 +01:00
parent 4c83ece90e
commit a71cda6a8f
7 changed files with 94 additions and 0 deletions

View File

@ -0,0 +1,20 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: argo-app-nginx-testing
namespace: argocd
spec:
destination:
name: ''
namespace: default
server: https://kubernetes.default.svc
source:
path: nginx-testing
repoURL: https://git.mziesel.nl/mans/argocd-test
targetRevision: HEAD
sources: []
project: default
syncPolicy:
automated:
prune: true
selfHeal: true

View File

@ -19,4 +19,5 @@ resources:
- ./base/mediaserver-application.yaml - ./base/mediaserver-application.yaml
- ./base/uptime-kuma-application.yaml - ./base/uptime-kuma-application.yaml
- ./base/metrics-server-application.yaml - ./base/metrics-server-application.yaml
- ./base/nginx-testing-application.yaml
# - ./base/authentik-application.yaml # - ./base/authentik-application.yaml

View File

@ -0,0 +1,21 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-testing
namespace: nginx-testing
spec:
replicas: 3
selector:
matchLabels:
app: nginx-testing
template:
metadata:
labels:
app: nginx-testing
spec:
containers:
- image: nginx:1.27.3
name: nginx-testing
ports:
- name: web
containerPort: 80

View File

@ -0,0 +1,27 @@
---
apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: m4n5.online-cert
spec:
secretName: m4n5.online-secret
issuerRef:
name: cloudflare-issuer
kind: ClusterIssuer
dnsNames:
- m4n5.online
- www.m4n5.online
---
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: nginx-testing-ingressroute
spec:
routes:
- match: Host(`m4n5.online`) || Host(`www.m4n5.online`)
kind: Rule
services:
- name: nginx-testing
port: web
tls:
secretName: m4n5.online-secret

View File

@ -0,0 +1,4 @@
apiVersion: v1
kind: Namespace
metadata:
name: nginx-testing

View File

@ -0,0 +1,11 @@
apiVersion: v1
kind: Service
metadata:
name: nginx-testing
spec:
ports:
- name: web
port: 80
targetPort: web
selector:
app: nginx-testing

View File

@ -0,0 +1,10 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: nginx-testing
resources:
- ./base/nginx-testing-namespace.yaml
- ./base/nginx-testing-deployment.yaml
- ./base/nginx-testing-svc.yaml
- ./base/nginx-testing-ingress.yaml