Add Kubernetes configurations for Immich deployment, including database, machine learning, services, and secrets
This commit is contained in:
67
clusters/default/media/immich/immich.yml
Normal file
67
clusters/default/media/immich/immich.yml
Normal file
@@ -0,0 +1,67 @@
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: immich-app
|
||||
namespace: media
|
||||
spec:
|
||||
strategy:
|
||||
type: Recreate
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: immich-app
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: immich-app
|
||||
spec:
|
||||
initContainers:
|
||||
- name: wait-for-redis
|
||||
image: busybox
|
||||
command:
|
||||
- sh
|
||||
- -c
|
||||
- |
|
||||
until nc -z -v -w30 immich-redis-service 6379; do
|
||||
echo "Waiting for redis database to be ready..."
|
||||
sleep 2
|
||||
done
|
||||
- name: wait-for-psql
|
||||
image: busybox
|
||||
command:
|
||||
- sh
|
||||
- -c
|
||||
- |
|
||||
until nc -z -v -w30 immich-psql-service 5432; do
|
||||
echo "Waiting for psql database to be ready"
|
||||
sleep 2
|
||||
done
|
||||
containers:
|
||||
- name: immich-server
|
||||
image: ghcr.io/immich-app/immich-server:v2.0.1
|
||||
ports:
|
||||
- containerPort: 2283
|
||||
env:
|
||||
- name: TZ
|
||||
value: "Asia/Kolkata"
|
||||
- name: REDIS_HOSTNAME
|
||||
value: "immich-redis-service"
|
||||
- name: DB_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: immich-postgres-secret
|
||||
key: password
|
||||
- name: DB_USERNAME
|
||||
value: "postgres"
|
||||
- name: DB_DATABASE_NAME
|
||||
value: "immich"
|
||||
- name: DB_HOSTNAME
|
||||
value: "immich-psql-service"
|
||||
volumeMounts:
|
||||
- mountPath: /usr/src/app/upload
|
||||
name: pictures
|
||||
volumes:
|
||||
- name: pictures
|
||||
persistentVolumeClaim:
|
||||
claimName: immich-pictures-pvc
|
||||
Reference in New Issue
Block a user