init
This commit is contained in:
36
k8s/cronjob.yaml
Normal file
36
k8s/cronjob.yaml
Normal file
@@ -0,0 +1,36 @@
|
||||
apiVersion: batch/v1
|
||||
kind: CronJob
|
||||
metadata:
|
||||
name: ncore-hnr
|
||||
spec:
|
||||
schedule: "0 6 * * *"
|
||||
concurrencyPolicy: Forbid
|
||||
successfulJobsHistoryLimit: 3
|
||||
failedJobsHistoryLimit: 3
|
||||
jobTemplate:
|
||||
spec:
|
||||
backoffLimit: 1
|
||||
template:
|
||||
spec:
|
||||
restartPolicy: Never
|
||||
containers:
|
||||
- name: ncore-hnr
|
||||
image: ncore-hnr:local
|
||||
imagePullPolicy: IfNotPresent
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: ncore-hnr-secrets
|
||||
env:
|
||||
- name: APP_DB_PATH
|
||||
value: /data/ncore-hnr.sqlite
|
||||
- name: DRY_RUN
|
||||
value: "false"
|
||||
- name: ALERT_AFTER
|
||||
value: 48h
|
||||
volumeMounts:
|
||||
- name: data
|
||||
mountPath: /data
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
claimName: ncore-hnr-data
|
||||
10
k8s/pvc.yaml
Normal file
10
k8s/pvc.yaml
Normal file
@@ -0,0 +1,10 @@
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: ncore-hnr-data
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 1Gi
|
||||
19
k8s/secret.example.yaml
Normal file
19
k8s/secret.example.yaml
Normal file
@@ -0,0 +1,19 @@
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: ncore-hnr-secrets
|
||||
type: Opaque
|
||||
stringData:
|
||||
NCORE_USERNAME: "your-ncore-username"
|
||||
NCORE_PASSWORD: "your-ncore-password"
|
||||
QBITTORRENT_URL: "http://qbittorrent.default.svc.cluster.local:8080"
|
||||
QBITTORRENT_USERNAME: "admin"
|
||||
QBITTORRENT_PASSWORD: "your-qbit-password"
|
||||
NOTIFICATION_TYPE: ""
|
||||
NOTIFICATION_NTFY_URL: ""
|
||||
NOTIFICATION_SMTP_HOST: ""
|
||||
NOTIFICATION_SMTP_PORT: "587"
|
||||
NOTIFICATION_SMTP_USERNAME: ""
|
||||
NOTIFICATION_SMTP_PASSWORD: ""
|
||||
NOTIFICATION_SMTP_FROM: ""
|
||||
NOTIFICATION_SMTP_TO: ""
|
||||
Reference in New Issue
Block a user