Last active
October 31, 2021 11:36
-
-
Save clarkmcc/a613f5f9c535ac0bf878a2195bc5579a to your computer and use it in GitHub Desktop.
A Kubernetes implementation of Resilio Sync
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Namespace | |
metadata: | |
name: resilio | |
--- | |
apiVersion: v1 | |
kind: PersistentVolume | |
metadata: | |
name: resilio-pv-volume | |
namespace: resilio | |
labels: | |
type: local | |
spec: | |
storageClassName: local-storage | |
persistentVolumeReclaimPolicy: Retain | |
local: | |
path: "/mnt/sync" | |
capacity: | |
storage: 100Gi | |
accessModes: | |
- ReadWriteOnce | |
nodeAffinity: | |
required: | |
nodeSelectorTerms: | |
- matchExpressions: | |
- key: kubernetes.io/hostname | |
operator: In | |
values: | |
- my-node | |
--- | |
apiVersion: v1 | |
kind: PersistentVolumeClaim | |
metadata: | |
name: resilio-pv-claim | |
namespace: resilio | |
spec: | |
storageClassName: local-storage | |
accessModes: | |
- ReadWriteOnce | |
resources: | |
requests: | |
storage: 100Gi | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
creationTimestamp: null | |
labels: | |
app: sync | |
name: sync | |
namespace: resilio | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: sync | |
strategy: | |
type: Recreate | |
template: | |
metadata: | |
creationTimestamp: null | |
labels: | |
app: sync | |
spec: | |
containers: | |
- image: resilio/sync | |
name: sync | |
volumeMounts: | |
- name: resilio-pv-claim | |
mountPath: /mnt/sync | |
resources: {} | |
volumes: | |
- name: resilio-pv-claim | |
persistentVolumeClaim: | |
claimName: resilio-pv-claim | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
app: sync | |
name: sync | |
namespace: resilio | |
spec: | |
clusterIP: 10.152.183.240 | |
externalTrafficPolicy: Cluster | |
ports: | |
- nodePort: 30011 | |
port: 8888 | |
protocol: TCP | |
targetPort: 8888 | |
selector: | |
app: sync | |
sessionAffinity: None | |
type: NodePort |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment