77 lines
1.8 KiB
YAML
77 lines
1.8 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
labels:
|
|
io.kompose.service: arr-db
|
|
name: arr-db
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
io.kompose.service: arr-db
|
|
strategy:
|
|
type: Recreate
|
|
template:
|
|
metadata:
|
|
labels:
|
|
io.kompose.service: arr-db
|
|
spec:
|
|
containers:
|
|
- env:
|
|
- name: POSTGRES_DB
|
|
value: radarr-main
|
|
- name: POSTGRES_PASSWORD
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: postgres-secrets
|
|
key: postgres-password
|
|
- name: POSTGRES_USER
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: postgres-secrets
|
|
key: postgres-user
|
|
- name: TZ
|
|
value: Asia/Kuwait
|
|
image: postgres:15.2
|
|
name: arr-db
|
|
volumeMounts:
|
|
- mountPath: /docker-entrypoint-initdb.d
|
|
name: init-script
|
|
- mountPath: /var/lib/postgresql/data
|
|
name: ssd
|
|
subPath: configs/databases/arrdatabase
|
|
restartPolicy: Always
|
|
volumes:
|
|
- name: init-script
|
|
configMap:
|
|
name: postgres-init-script
|
|
- name: ssd
|
|
persistentVolumeClaim:
|
|
claimName: nfs-ssd-pvc
|
|
- name: hdd
|
|
persistentVolumeClaim:
|
|
claimName: nfs-hdd-pvc
|
|
---
|
|
# apiVersion: v1
|
|
# kind: Pod
|
|
# metadata:
|
|
# name: migration-pod
|
|
# labels:
|
|
# app: migration-pod
|
|
# spec:
|
|
# containers:
|
|
# - name: migration
|
|
# image: ubuntu:latest
|
|
# command: ["/bin/bash"]
|
|
# args: ["-c", "apt-get update && apt-get install -y pgloader && sleep infinity"]
|
|
# volumeMounts:
|
|
# - mountPath: /data/configs
|
|
# name: ssd
|
|
# subPath: configs
|
|
# volumes:
|
|
# - name: ssd
|
|
# persistentVolumeClaim:
|
|
# claimName: nfs-ssd-pvc
|
|
# restartPolicy: Never
|
|
#
|
|
---
|