82 lines
2.9 KiB
YAML
82 lines
2.9 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: postiz
|
|
namespace: postiz
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: postiz
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: postiz
|
|
spec:
|
|
affinity:
|
|
nodeAffinity:
|
|
requiredDuringSchedulingIgnoredDuringExecution:
|
|
nodeSelectorTerms:
|
|
- matchExpressions:
|
|
- key: kubernetes.io/arch
|
|
operator: In
|
|
values:
|
|
- amd64
|
|
containers:
|
|
- name: postiz-web
|
|
image: git.halis.io/athens-school/postiz:1.40.1
|
|
ports:
|
|
- containerPort: 5000
|
|
envFrom:
|
|
- secretRef:
|
|
name: postiz-providers
|
|
env:
|
|
- name: MAIN_URL
|
|
value: "https://postiz.halis.io"
|
|
- name: FRONTEND_URL
|
|
value: "https://postiz.halis.io"
|
|
- name: NEXT_PUBLIC_BACKEND_URL
|
|
value: "https://postiz.halis.io/api"
|
|
- name: JWT_SECRET
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: postiz-secrets
|
|
key: JWT_SECRET
|
|
- name: DB_USER
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: postiz-db
|
|
key: username
|
|
- name: DB_PASS
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: postiz-db
|
|
key: password
|
|
- name: DATABASE_URL
|
|
value: "postgresql://$(DB_USER):$(DB_PASS)@postiz-db-rw.postiz.svc.cluster.local:5432/postiz"
|
|
- name: REDIS_URL
|
|
value: "redis://redis-svc.postiz.svc.cluster.local:6379"
|
|
- name: BACKEND_INTERNAL_URL
|
|
value: "http://localhost:3000"
|
|
- name: IS_GENERAL
|
|
value: "true"
|
|
- name: STORAGE_PROVIDER
|
|
value: "local"
|
|
- name: UPLOAD_DIRECTORY
|
|
value: "/uploads"
|
|
- name: MASTODON_URL
|
|
value: "https://mastodon.halis.io"
|
|
- name: NEXT_PUBLIC_UPLOAD_DIRECTORY
|
|
value: "/uploads"
|
|
volumeMounts:
|
|
- mountPath: "/uploads"
|
|
name: postiz-data
|
|
- name: redis
|
|
image: redis:7.4.2
|
|
ports:
|
|
- containerPort: 6379
|
|
volumes:
|
|
- name: postiz-data
|
|
persistentVolumeClaim:
|
|
claimName: postiz-pvc
|