78 lines
2.1 KiB
Text
78 lines
2.1 KiB
Text
|
|
apiVersion: apps/v1
|
||
|
|
kind: Deployment
|
||
|
|
metadata:
|
||
|
|
name: backup-manager
|
||
|
|
namespace: {{ namespace }}
|
||
|
|
labels:
|
||
|
|
app: backup-manager
|
||
|
|
app.kubernetes.io/name: backup-manager
|
||
|
|
app.kubernetes.io/component: orchestrator
|
||
|
|
app.kubernetes.io/part-of: backup-system
|
||
|
|
spec:
|
||
|
|
replicas: 1
|
||
|
|
strategy:
|
||
|
|
type: Recreate
|
||
|
|
selector:
|
||
|
|
matchLabels:
|
||
|
|
app: backup-manager
|
||
|
|
template:
|
||
|
|
metadata:
|
||
|
|
labels:
|
||
|
|
app: backup-manager
|
||
|
|
annotations:
|
||
|
|
prometheus.io/scrape: "true"
|
||
|
|
prometheus.io/port: "{{ daemon_metrics_port }}"
|
||
|
|
prometheus.io/path: "/metrics"
|
||
|
|
spec:
|
||
|
|
serviceAccountName: backup-manager
|
||
|
|
containers:
|
||
|
|
- name: daemon
|
||
|
|
image: "{{ daemon_image }}"
|
||
|
|
args: ["daemon", "start"]
|
||
|
|
ports:
|
||
|
|
- name: api
|
||
|
|
containerPort: {{ daemon_http_port }}
|
||
|
|
- name: metrics
|
||
|
|
containerPort: {{ daemon_metrics_port }}
|
||
|
|
env:
|
||
|
|
- name: BACKUP_LOG
|
||
|
|
value: "info"
|
||
|
|
- name: BACKUP_DAEMON_HTTP_ADDR
|
||
|
|
value: "0.0.0.0:{{ daemon_http_port }}"
|
||
|
|
envFrom:
|
||
|
|
- secretRef:
|
||
|
|
name: backup-manager-bootstrap
|
||
|
|
resources:
|
||
|
|
requests:
|
||
|
|
cpu: "200m"
|
||
|
|
memory: "256Mi"
|
||
|
|
limits:
|
||
|
|
cpu: "2"
|
||
|
|
memory: "1Gi"
|
||
|
|
volumeMounts:
|
||
|
|
- name: state
|
||
|
|
mountPath: /var/lib/prvng-backup
|
||
|
|
- name: definitions
|
||
|
|
mountPath: /opt/provisioning
|
||
|
|
readOnly: true
|
||
|
|
livenessProbe:
|
||
|
|
httpGet:
|
||
|
|
path: /healthz
|
||
|
|
port: api
|
||
|
|
initialDelaySeconds: 10
|
||
|
|
periodSeconds: 30
|
||
|
|
readinessProbe:
|
||
|
|
httpGet:
|
||
|
|
path: /readyz
|
||
|
|
port: api
|
||
|
|
initialDelaySeconds: 5
|
||
|
|
periodSeconds: 10
|
||
|
|
volumes:
|
||
|
|
- name: state
|
||
|
|
persistentVolumeClaim:
|
||
|
|
claimName: backup-manager-state
|
||
|
|
- name: definitions
|
||
|
|
configMap:
|
||
|
|
name: backup-manager-definitions
|
||
|
|
optional: true
|