infrastructure/k8s/roles/agola/templates/all-deployment.yml.j2
2022-09-11 18:49:31 +02:00

56 lines
1.4 KiB
Django/Jinja

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: agola
spec:
# Do not increase replica count or everything will break since every pod will
# have its own database
replicas: 1
strategy:
type: Recreate
selector:
matchLabels:
app: agola
template:
metadata:
labels:
app: agola
spec:
serviceAccountName: agola
containers:
- name: agola
image: {{ agola_image }}
command:
- /bin/agola
- serve
- "--config"
- /mnt/agola/config/config.yml
- "--components"
- all-base,executor
- "--detailed-errors"
- "--embedded-etcd"
- "--embedded-etcd-data-dir"
- "/mnt/agola/data/etcd"
env:
ports:
- containerPort: 8000
- containerPort: 4000
- containerPort: 4002
- containerPort: 4003
volumeMounts:
- name: config-volume
mountPath: /mnt/agola/config
- name: agola-localdata
mountPath: /mnt/agola/local
- name: agola-objectstorage
mountPath: /mnt/agola/data
volumes:
- name: config-volume
secret:
secretName: agola
- name: agola-localdata
emptyDir: {}
- name: agola-objectstorage
persistentVolumeClaim:
claimName: agola-data