add ntfy
This commit is contained in:
parent
6c04a312d7
commit
8a7876b841
5 changed files with 204 additions and 0 deletions
3
ntfy/README.md
Normal file
3
ntfy/README.md
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
### ntfy
|
||||||
|
|
||||||
|

|
||||||
164
ntfy/deployment.yaml
Normal file
164
ntfy/deployment.yaml
Normal file
|
|
@ -0,0 +1,164 @@
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert -o deployment.yaml -n ntfy
|
||||||
|
kompose.service.expose: ntfy.wayl.one
|
||||||
|
kompose.version: 1.31.2 (a92241f79)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
name: ntfy
|
||||||
|
namespace: ntfy
|
||||||
|
spec:
|
||||||
|
ports:
|
||||||
|
- name: "3008"
|
||||||
|
port: 3008
|
||||||
|
targetPort: 80
|
||||||
|
selector:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
status:
|
||||||
|
loadBalancer: {}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: ntfy
|
||||||
|
namespace: ntfy
|
||||||
|
spec: {}
|
||||||
|
status: {}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert -o deployment.yaml -n ntfy
|
||||||
|
kompose.service.expose: ntfy.wayl.one
|
||||||
|
kompose.version: 1.31.2 (a92241f79)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
name: ntfy
|
||||||
|
namespace: ntfy
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert -o deployment.yaml -n ntfy
|
||||||
|
kompose.service.expose: ntfy.wayl.one
|
||||||
|
kompose.version: 1.31.2 (a92241f79)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.network/ntfy-default: "true"
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- args:
|
||||||
|
- serve
|
||||||
|
env:
|
||||||
|
- name: TZ
|
||||||
|
value: UTC
|
||||||
|
image: binwiederhier/ntfy
|
||||||
|
livenessProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- wget -q --tries=1 http://localhost:80/v1/health -O - | grep -Eo '"healthy"\s*:\s*true' || exit 1
|
||||||
|
failureThreshold: 3
|
||||||
|
initialDelaySeconds: 40
|
||||||
|
periodSeconds: 60
|
||||||
|
timeoutSeconds: 10
|
||||||
|
name: ntfy
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
hostPort: 3008
|
||||||
|
protocol: TCP
|
||||||
|
resources: {}
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 1000
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /var/cache/ntfy
|
||||||
|
name: ntfy-cache
|
||||||
|
- mountPath: /etc/ntfy
|
||||||
|
name: ntfy
|
||||||
|
restartPolicy: Always
|
||||||
|
volumes:
|
||||||
|
- name: ntfy-cache
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: ntfy-cache
|
||||||
|
- name: ntfy
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: ntfy
|
||||||
|
status: {}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert -o deployment.yaml -n ntfy
|
||||||
|
kompose.service.expose: ntfy.wayl.one
|
||||||
|
kompose.version: 1.31.2 (a92241f79)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
name: ntfy
|
||||||
|
namespace: ntfy
|
||||||
|
spec:
|
||||||
|
rules:
|
||||||
|
- host: ntfy.wayl.one
|
||||||
|
http:
|
||||||
|
paths:
|
||||||
|
- backend:
|
||||||
|
service:
|
||||||
|
name: ntfy
|
||||||
|
port:
|
||||||
|
number: 3008
|
||||||
|
path: /
|
||||||
|
pathType: Prefix
|
||||||
|
status:
|
||||||
|
loadBalancer: {}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: ntfy-cache
|
||||||
|
name: ntfy-cache
|
||||||
|
namespace: ntfy
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: ntfy
|
||||||
|
name: ntfy
|
||||||
|
namespace: ntfy
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
|
|
||||||
28
ntfy/docker-compose.yml
Normal file
28
ntfy/docker-compose.yml
Normal file
|
|
@ -0,0 +1,28 @@
|
||||||
|
version: "2.3"
|
||||||
|
|
||||||
|
services:
|
||||||
|
ntfy:
|
||||||
|
image: binwiederhier/ntfy
|
||||||
|
container_name: ntfy
|
||||||
|
command:
|
||||||
|
- serve
|
||||||
|
environment:
|
||||||
|
- TZ=UTC # optional: set desired timezone
|
||||||
|
user: "1000" # optional: replace with your own user/group or uid/gid
|
||||||
|
volumes:
|
||||||
|
- ntfy-cache:/var/cache/ntfy
|
||||||
|
- ntfy:/etc/ntfy
|
||||||
|
ports:
|
||||||
|
- 3008:80
|
||||||
|
healthcheck: # optional: remember to adapt the host:port to your environment
|
||||||
|
test: ["CMD-SHELL", "wget -q --tries=1 http://localhost:80/v1/health -O - | grep -Eo '\"healthy\"\\s*:\\s*true' || exit 1"]
|
||||||
|
interval: 60s
|
||||||
|
timeout: 10s
|
||||||
|
retries: 3
|
||||||
|
start_period: 40s
|
||||||
|
restart: always
|
||||||
|
labels:
|
||||||
|
kompose.service.expose: ntfy.wayl.one
|
||||||
|
volumes:
|
||||||
|
ntfy:
|
||||||
|
ntfy-cache:
|
||||||
9
ntfy/justfile
Normal file
9
ntfy/justfile
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
default: convert deploy viz
|
||||||
|
convert:
|
||||||
|
kompose convert -o deployment.yaml -n ntfy
|
||||||
|
deploy:
|
||||||
|
kubectl apply -f deployment.yaml
|
||||||
|
viz:
|
||||||
|
k8sviz -n ntfy --kubeconfig ~/.config/kube/falcon-k3s.yaml -t png -o ntfy-k8s.png
|
||||||
|
restart:
|
||||||
|
kubectl rollout restart -n ntfy deployment/ntfy
|
||||||
BIN
ntfy/ntfy-k8s.png
Normal file
BIN
ntfy/ntfy-k8s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 92 KiB |
Loading…
Add table
Add a link
Reference in a new issue