mirror of
https://github.com/michaelthomson0797/fleet-infra.git
synced 2026-02-04 04:59:54 +00:00
initial refactor
This commit is contained in:
43
apps/syncthing/deployment.yaml
Normal file
43
apps/syncthing/deployment.yaml
Normal file
@@ -0,0 +1,43 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: syncthing
|
||||
namespace: syncthing
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: syncthing
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: syncthing
|
||||
spec:
|
||||
containers:
|
||||
- env:
|
||||
- name: PGID
|
||||
value: "1000"
|
||||
- name: PUID
|
||||
value: "1000"
|
||||
image: syncthing/syncthing
|
||||
name: syncthing
|
||||
ports:
|
||||
- containerPort: 8384
|
||||
name: http
|
||||
protocol: TCP
|
||||
- containerPort: 22000
|
||||
name: tcp
|
||||
protocol: TCP
|
||||
- containerPort: 22000
|
||||
name: quic
|
||||
protocol: UDP
|
||||
- containerPort: 21027
|
||||
name: discovery
|
||||
protocol: UDP
|
||||
volumeMounts:
|
||||
- mountPath: /var/syncthing
|
||||
name: data
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
claimName: data
|
||||
12
apps/syncthing/dns-endpoint.yaml
Normal file
12
apps/syncthing/dns-endpoint.yaml
Normal file
@@ -0,0 +1,12 @@
|
||||
apiVersion: externaldns.k8s.io/v1alpha1
|
||||
kind: DNSEndpoint
|
||||
metadata:
|
||||
name: syncthing.michaelthomson.dev
|
||||
namespace: syncthing
|
||||
spec:
|
||||
endpoints:
|
||||
- dnsName: syncthing.michaelthomson.dev
|
||||
recordTTL: 180
|
||||
recordType: CNAME
|
||||
targets:
|
||||
- server.michaelthomson.dev
|
||||
24
apps/syncthing/ingress.yaml
Normal file
24
apps/syncthing/ingress.yaml
Normal file
@@ -0,0 +1,24 @@
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: syncthing
|
||||
namespace: syncthing
|
||||
annotations:
|
||||
traefik.ingress.kubernetes.io/router.entrypoints: websecure
|
||||
traefik.ingress.kubernetes.io/router.tls: "true"
|
||||
spec:
|
||||
rules:
|
||||
- host: syncthing.michaelthomson.dev
|
||||
http:
|
||||
paths:
|
||||
- pathType: ImplementationSpecific
|
||||
path: /
|
||||
backend:
|
||||
service:
|
||||
name: syncthing
|
||||
port:
|
||||
name: http
|
||||
tls:
|
||||
- hosts:
|
||||
- syncthing.michaelthomson.dev
|
||||
secretName: letsencrypt-wildcard-cert-michaelthomson.dev
|
||||
4
apps/syncthing/namespace.yaml
Normal file
4
apps/syncthing/namespace.yaml
Normal file
@@ -0,0 +1,4 @@
|
||||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: syncthing
|
||||
12
apps/syncthing/pvc-data.yaml
Normal file
12
apps/syncthing/pvc-data.yaml
Normal file
@@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: data
|
||||
namespace: syncthing
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
storageClassName: nfs-client
|
||||
resources:
|
||||
requests:
|
||||
storage: 1Ti
|
||||
23
apps/syncthing/service-lb.yaml
Normal file
23
apps/syncthing/service-lb.yaml
Normal file
@@ -0,0 +1,23 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: syncthing-lb
|
||||
namespace: syncthing
|
||||
annotations:
|
||||
metallb.universe.tf/loadBalancerIPs: 192.168.2.247
|
||||
spec:
|
||||
selector:
|
||||
app: syncthing
|
||||
type: LoadBalancer
|
||||
ports:
|
||||
- name: tcp
|
||||
port: 22000
|
||||
targetPort: tcp
|
||||
- name: quic
|
||||
port: 22000
|
||||
protocol: UDP
|
||||
targetPort: quic
|
||||
- name: discovery
|
||||
port: 21027
|
||||
protocol: UDP
|
||||
targetPort: discovery
|
||||
12
apps/syncthing/service.yaml
Normal file
12
apps/syncthing/service.yaml
Normal file
@@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: syncthing
|
||||
namespace: syncthing
|
||||
spec:
|
||||
selector:
|
||||
app: syncthing
|
||||
ports:
|
||||
- name: http
|
||||
port: 8384
|
||||
targetPort: http
|
||||
Reference in New Issue
Block a user