-
Notifications
You must be signed in to change notification settings - Fork 1
/
housekeeping.yaml
40 lines (40 loc) · 1.13 KB
/
housekeeping.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
apiVersion: batch/v1beta1
kind: CronJob
metadata:
name: netbox-housekeeping
spec:
schedule: "0 3 * * *"
successfulJobsHistoryLimit: 1
failedJobsHistoryLimit: 1
jobTemplate:
spec:
template:
spec:
containers:
- name: netbox-housekeeping-run
image: image-registry.openshift-image-registry.svc:5000/netbox/netbox-app:latest
command:
- python3
- netbox/manage.py
- housekeeping
env:
- name: NETBOX_REDIS_PASS
valueFrom:
secretKeyRef:
name: redis
key: database-password
imagePullPolicy: Always
envFrom:
- configMapRef:
name: netbox-secrets
- secretRef:
name: netbox-secret-key
- secretRef:
name: netbox-aws
- secretRef:
name: netbox-db-pass
- secretRef:
name: netbox-mail
- secretRef:
name: netbox-ldap
restartPolicy: OnFailure