testing a few sample (joint) configurations
This commit is contained in:
40
apps/files/syncthing/deployment.yaml
Normal file
40
apps/files/syncthing/deployment.yaml
Normal file
@@ -0,0 +1,40 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: syncthing
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: syncthing
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: syncthing
|
||||
spec:
|
||||
containers:
|
||||
- name: syncthing
|
||||
image: syncthing
|
||||
resources:
|
||||
limits:
|
||||
memory: "256Mi"
|
||||
cpu: "500m"
|
||||
ports:
|
||||
- containerPort: 8384
|
||||
protocol: TCP
|
||||
name: syncthing-web
|
||||
- containerPort: 22000
|
||||
protocol: TCP
|
||||
- containerPort: 22000
|
||||
protocol: UDP
|
||||
volumeMounts:
|
||||
- name: persistence
|
||||
mountPath: /files
|
||||
- name: config
|
||||
mountPath: /var/syncthing/config
|
||||
volumes:
|
||||
- name: persistence
|
||||
persistentVolumeClaim:
|
||||
claimName: files-nfs
|
||||
- name: config
|
||||
persistentVolumeClaim:
|
||||
claimName: syncthing-config
|
16
apps/files/syncthing/ingress.yaml
Normal file
16
apps/files/syncthing/ingress.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: IngressRoute
|
||||
metadata:
|
||||
name: rss-ingressroute
|
||||
|
||||
spec:
|
||||
entryPoints:
|
||||
- websecure
|
||||
routes:
|
||||
- match: Host(`syncthing2.kluster.moll.re`)
|
||||
kind: Rule
|
||||
services:
|
||||
- name: syncthing-web
|
||||
port: 8384
|
||||
tls:
|
||||
certResolver: default-tls
|
15
apps/files/syncthing/kustomization.yaml
Normal file
15
apps/files/syncthing/kustomization.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- pvc.yaml
|
||||
- deployment.yaml
|
||||
- service.yaml
|
||||
- ingress.yaml
|
||||
- servicemonitor.yaml
|
||||
# - syncthing-api.sealedsecret.yaml
|
||||
|
||||
images:
|
||||
- name: syncthing
|
||||
newName: syncthing/syncthing
|
||||
newTag: "1.27"
|
11
apps/files/syncthing/pvc.yaml
Normal file
11
apps/files/syncthing/pvc.yaml
Normal file
@@ -0,0 +1,11 @@
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: syncthing-config
|
||||
spec:
|
||||
storageClassName: nfs-client
|
||||
accessModes:
|
||||
- ReadWriteMany
|
||||
resources:
|
||||
requests:
|
||||
storage: 1Gi
|
46
apps/files/syncthing/service.yaml
Normal file
46
apps/files/syncthing/service.yaml
Normal file
@@ -0,0 +1,46 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: syncthing-web
|
||||
labels:
|
||||
app: syncthing
|
||||
spec:
|
||||
selector:
|
||||
app: syncthing
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 8384
|
||||
targetPort: 8384
|
||||
name: syncthing-web
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: syncthing-listen
|
||||
annotations:
|
||||
metallb.universe.tf/allow-shared-ip: syncthing-service
|
||||
spec:
|
||||
selector:
|
||||
app: syncthing
|
||||
type: LoadBalancer
|
||||
loadBalancerIP: 192.168.3.5
|
||||
ports:
|
||||
- port: 22000
|
||||
targetPort: 22000
|
||||
protocol: TCP
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: syncthing-discover
|
||||
annotations:
|
||||
metallb.universe.tf/allow-shared-ip: syncthing-service
|
||||
spec:
|
||||
selector:
|
||||
app: syncthing
|
||||
type: LoadBalancer
|
||||
loadBalancerIP: 192.168.3.5
|
||||
ports:
|
||||
- port: 22000
|
||||
targetPort: 22000
|
||||
protocol: UDP
|
16
apps/files/syncthing/servicemonitor.yaml
Normal file
16
apps/files/syncthing/servicemonitor.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
name: syncthing-servicemonitor
|
||||
labels:
|
||||
app: syncthing
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: syncthing
|
||||
endpoints:
|
||||
- port: syncthing-web
|
||||
path: /metrics
|
||||
bearerTokenSecret:
|
||||
name: syncthing-api
|
||||
key: token
|
Reference in New Issue
Block a user