selfoss.yaml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. ---
  2. apiVersion: v1
  3. kind: Namespace
  4. metadata:
  5. name: selfoss
  6. ---
  7. apiVersion: v1
  8. kind: PersistentVolumeClaim
  9. metadata:
  10. name: selfoss-pvc
  11. namespace: selfoss
  12. labels:
  13. app: selfoss
  14. spec:
  15. storageClassName: ceph-block
  16. accessModes:
  17. - ReadWriteOnce
  18. resources:
  19. requests:
  20. storage: 2Gi
  21. ---
  22. apiVersion: apps/v1
  23. kind: Deployment
  24. metadata:
  25. name: selfoss
  26. namespace: selfoss
  27. spec:
  28. strategy:
  29. type: Recreate
  30. selector:
  31. matchLabels:
  32. app: selfoss
  33. replicas: 1
  34. template:
  35. metadata:
  36. labels:
  37. app: selfoss
  38. spec:
  39. containers:
  40. - name: selfoss
  41. image: jibby0/selfoss:2.18
  42. ports:
  43. - containerPort: 8888
  44. name: http-web-svc
  45. volumeMounts:
  46. - mountPath: "/selfoss/data"
  47. name: data
  48. env:
  49. - name: CRON_PERIOD
  50. value: 5m
  51. livenessProbe:
  52. httpGet:
  53. path: /
  54. port: 8888
  55. failureThreshold: 10
  56. initialDelaySeconds: 30
  57. periodSeconds: 10
  58. volumes:
  59. - name: data
  60. persistentVolumeClaim:
  61. claimName: selfoss-pvc
  62. ---
  63. apiVersion: v1
  64. kind: Service
  65. metadata:
  66. name: selfoss-service
  67. namespace: selfoss
  68. spec:
  69. selector:
  70. app: selfoss
  71. type: ClusterIP
  72. ports:
  73. - name: selfoss-web-port
  74. protocol: TCP
  75. port: 8888
  76. targetPort: http-web-svc
  77. ---
  78. apiVersion: traefik.containo.us/v1alpha1
  79. kind: IngressRoute
  80. metadata:
  81. name: selfoss
  82. namespace: selfoss
  83. spec:
  84. entryPoints:
  85. - websecure
  86. routes:
  87. - kind: Rule
  88. match: Host(`selfoss.jibby.org`)
  89. services:
  90. - kind: Service
  91. name: selfoss-service
  92. port: 8888