This commit is contained in:
2025-05-06 05:33:30 -05:00
parent 9d0a172198
commit b33158e0fe
7 changed files with 190 additions and 74 deletions

View File

@@ -1,74 +1,74 @@
apiVersion: v1 #apiVersion: v1
kind: Service #kind: Service
metadata: #metadata:
name: redlib # name: redlib
spec: #spec:
ports: # ports:
- name: app # - name: app
port: 8082 # port: 8082
protocol: TCP # protocol: TCP
targetPort: 8082 # targetPort: 8082
clusterIP: None # clusterIP: None
type: ClusterIP # type: ClusterIP
#
--- #---
#
apiVersion: v1 #apiVersion: v1
kind: Endpoints #kind: Endpoints
metadata: #metadata:
name: redlib # name: redlib
subsets: #subsets:
- addresses: #- addresses:
- ip: 192.168.21.200 # - ip: 192.168.21.200
ports: # ports:
- name: app # - name: app
port: 8082 # port: 8082
protocol: TCP # protocol: TCP
#
--- #---
#
apiVersion: traefik.io/v1alpha1 #apiVersion: traefik.io/v1alpha1
kind: IngressRoute #kind: IngressRoute
metadata: #metadata:
name: redlib-ingress # name: redlib-ingress
spec: #spec:
entryPoints: # entryPoints:
- websecure # - websecure
routes: # routes:
- match: Host(`redlib.durp.info`) && PathPrefix(`/`) # - match: Host(`redlib.durp.info`) && PathPrefix(`/`)
middlewares: # middlewares:
- name: authentik-proxy-provider # - name: authentik-proxy-provider
namespace: traefik # namespace: traefik
kind: Rule # kind: Rule
services: # services:
- name: redlib # - name: redlib
port: 8082 # port: 8082
tls: # tls:
secretName: redlib-tls # secretName: redlib-tls
#
--- #---
#
apiVersion: cert-manager.io/v1 #apiVersion: cert-manager.io/v1
kind: Certificate #kind: Certificate
metadata: #metadata:
name: redlib-tls # name: redlib-tls
spec: #spec:
secretName: redlib-tls # secretName: redlib-tls
issuerRef: # issuerRef:
name: letsencrypt-production # name: letsencrypt-production
kind: ClusterIssuer # kind: ClusterIssuer
commonName: "redlib.durp.info" # commonName: "redlib.durp.info"
dnsNames: # dnsNames:
- "redlib.durp.info" # - "redlib.durp.info"
#
--- #---
#
kind: Service #kind: Service
apiVersion: v1 #apiVersion: v1
metadata: #metadata:
name: redlib-external-dns # name: redlib-external-dns
annotations: # annotations:
external-dns.alpha.kubernetes.io/hostname: redlib.durp.info # external-dns.alpha.kubernetes.io/hostname: redlib.durp.info
spec: #spec:
type: ExternalName # type: ExternalName
externalName: durp.info # externalName: durp.info

7
dmz/redlib/Chart.yaml Normal file
View File

@@ -0,0 +1,7 @@
apiVersion: v2
name: redlib
description: A Helm chart for Kubernetes
type: application
version: 0.1.0
appVersion: "1.16.0"

View File

@@ -0,0 +1,33 @@
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: redlib
name: redlib
labels:
app: redlib
spec:
selector:
matchLabels:
app: redlib
replicas: 3
template:
metadata:
labels:
app: redlib
spec:
containers:
- name: redlib
image: registry.durp.info/redlib/redlib:latest
imagePullPolicy: Always
livenessProbe:
httpGet:
path: /
port: 8080
readinessProbe:
httpGet:
path: /
port: 8080
env:
ports:
- name: http
containerPort: 8080

View File

@@ -0,0 +1,42 @@
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: redlib-ingress
spec:
entryPoints:
- websecure
routes:
- match: Host(`links.durp.info`) && PathPrefix(`/`)
kind: Rule
services:
- name: redlib
port: 8080
tls:
secretName: redlib-tls
---
apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: redlib-tls
spec:
secretName: redlib-tls
issuerRef:
name: letsencrypt-production
kind: ClusterIssuer
commonName: "redlib.durp.info"
dnsNames:
- "redlib.durp.info"
---
kind: Service
apiVersion: v1
metadata:
name: redlib-external-dns
annotations:
external-dns.alpha.kubernetes.io/hostname: redlib.durp.info
spec:
type: ExternalName
externalName: durp.info

View File

@@ -0,0 +1,12 @@
apiVersion: v1
kind: Service
metadata:
name: redlib
spec:
ports:
- name: http
port: 8080
targetPort: 8080
protocol: TCP
selector:
app: redlib

0
dmz/redlib/values.yaml Normal file
View File

View File

@@ -0,0 +1,22 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: redlib
namespace: argocd
spec:
project: default
source:
repoURL: https://gitlab.com/developerdurp/homelab.git
targetRevision: main
path: dmz/redlib
directory:
recurse: true
destination:
name: dmz
namespace: redlib
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true