129 lines
2.8 KiB
YAML
129 lines
2.8 KiB
YAML
apiVersion: v1
|
|
kind: Namespace
|
|
metadata:
|
|
name: ntfy
|
|
labels:
|
|
app.kubernetes.io/instance: ntfy
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: ntfy
|
|
namespace: ntfy
|
|
labels:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
app.kubernetes.io/instance: ntfy
|
|
app.kubernetes.io/part-of: ntfy
|
|
spec:
|
|
type: ClusterIP
|
|
selector:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
ports:
|
|
- name: http
|
|
port: 2586
|
|
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: ntfy
|
|
namespace: ntfy
|
|
labels:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
app.kubernetes.io/instance: ntfy
|
|
app.kubernetes.io/part-of: ntfy
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
app.kubernetes.io/instance: ntfy
|
|
app.kubernetes.io/part-of: ntfy
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
app.kubernetes.io/instance: ntfy
|
|
app.kubernetes.io/part-of: ntfy
|
|
spec:
|
|
containers:
|
|
- name: ntfy
|
|
image: docker.io/binwiederhier/ntfy:v2.5.0
|
|
imagePullPolicy: IfNotPresent
|
|
args:
|
|
- serve
|
|
ports:
|
|
- containerPort: 2586
|
|
name: http
|
|
readinessProbe:
|
|
failureThreshold: 3
|
|
httpGet:
|
|
path: /config.js
|
|
port: 2586
|
|
initialDelaySeconds: 1
|
|
periodSeconds: 60
|
|
successThreshold: 1
|
|
timeoutSeconds: 1
|
|
securityContext:
|
|
runAsUser: 1000
|
|
volumeMounts:
|
|
- name: config
|
|
mountPath: /etc/ntfy
|
|
readOnly: true
|
|
- name: cache
|
|
mountPath: /var/cache/ntfy/attachments
|
|
subPath: attachments
|
|
securityContext:
|
|
fsGroup: 1000
|
|
volumes:
|
|
- name: config
|
|
configMap:
|
|
name: ntfy
|
|
- name: cache
|
|
ephemeral:
|
|
volumeClaimTemplate:
|
|
spec:
|
|
accessModes:
|
|
- ReadWriteOnce
|
|
resources:
|
|
requests:
|
|
storage: 1Gi
|
|
|
|
---
|
|
apiVersion: networking.k8s.io/v1
|
|
kind: Ingress
|
|
metadata:
|
|
name: ntfy
|
|
namespace: ntfy
|
|
labels:
|
|
app.kubernetes.io/name: ntfy
|
|
app.kubernetes.io/component: ntfy
|
|
app.kubernetes.io/instance: ntfy
|
|
app.kubernetes.io/part-of: ntfy
|
|
annotations:
|
|
nginx.ingress.kubernetes.io/proxy-body-size: '0'
|
|
spec:
|
|
ingressClassName: nginx
|
|
rules:
|
|
- host: ntfy.pyrocufflink.blue
|
|
http: &http
|
|
paths:
|
|
- path: /
|
|
pathType: Prefix
|
|
backend:
|
|
service:
|
|
name: ntfy
|
|
port:
|
|
name: http
|
|
- host: ntfy.pyrocufflink.net
|
|
http: *http
|
|
tls:
|
|
- hosts:
|
|
- ntfy.pyrocufflink.blue
|
|
- ntfy.pyrocufflink.net
|