ntfy.yaml 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. ---
  2. apiVersion: v1
  3. kind: Namespace
  4. metadata:
  5. name: ntfy
  6. ---
  7. apiVersion: v1
  8. kind: ConfigMap
  9. metadata:
  10. name: ntfy
  11. namespace: ntfy
  12. data:
  13. server.yml: |
  14. # Template: https://github.com/binwiederhier/ntfy/blob/main/server/server.yml
  15. base-url: https://ntfy.jibby.org
  16. auth-file: "/ntfy/user.db"
  17. auth-default-access: "deny-all"
  18. behind-proxy: true
  19. ---
  20. apiVersion: apps/v1
  21. kind: Deployment
  22. metadata:
  23. name: ntfy
  24. namespace: ntfy
  25. spec:
  26. strategy:
  27. type: Recreate
  28. selector:
  29. matchLabels:
  30. app: ntfy
  31. template:
  32. metadata:
  33. labels:
  34. app: ntfy
  35. spec:
  36. containers:
  37. - name: ntfy
  38. image: binwiederhier/ntfy:v2.7.0
  39. args: ["serve"]
  40. ports:
  41. - containerPort: 80
  42. name: http
  43. volumeMounts:
  44. - name: config
  45. mountPath: "/etc/ntfy"
  46. readOnly: true
  47. - name: data
  48. mountPath: "/ntfy"
  49. livenessProbe:
  50. httpGet:
  51. path: /v1/health
  52. port: 80
  53. failureThreshold: 10
  54. initialDelaySeconds: 30
  55. periodSeconds: 30
  56. timeoutSeconds: 10
  57. volumes:
  58. - name: config
  59. configMap:
  60. name: ntfy
  61. - name: data
  62. persistentVolumeClaim:
  63. claimName: ntfy-pvc
  64. ---
  65. # Basic service for port 80
  66. apiVersion: v1
  67. kind: Service
  68. metadata:
  69. name: ntfy-service
  70. namespace: ntfy
  71. spec:
  72. selector:
  73. app: ntfy
  74. ports:
  75. - port: 80
  76. targetPort: 80