* ci: remove stray serviceName * ci: volumeClaimTemplate name -> volumeMount, not volume * ci: datatracker listens on containerPort 8000 * ci: services/containers have dt- prefix * chore: adjust indent for k8s yaml * ci: use a secret for CELERY_PASSWORD * fix: touched wrong CELERY_PASSWORD setting * ci: get rid of the celery pw secretGenerator * ci: use DB_PASS instead of DBPASS (etc) for k8s * ci: Fill in django-config.yaml from env vars * ci: add vault-mappings.txt * ci: use $CELERY_PASSWORD in rabbitmq.yaml * ci: moving vault-mappings.txt out of this repo * Revert "ci: Fill in django-config.yaml from env vars" This reverts commit 75cd181deb390d3ab21d6887b091d66c80e1d18e. * Revert "ci: use $CELERY_PASSWORD in rabbitmq.yaml" This reverts commit f251f9920d07c65413f72fd165cc06acd562c2c7. * ci: parameterize db OPTIONS setting
81 lines
2.4 KiB
YAML
81 lines
2.4 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: celery
|
|
spec:
|
|
replicas: 1
|
|
revisionHistoryLimit: 2
|
|
selector:
|
|
matchLabels:
|
|
app: celery
|
|
strategy:
|
|
type: Recreate
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: celery
|
|
spec:
|
|
securityContext:
|
|
runAsNonRoot: true
|
|
containers:
|
|
# -----------------------------------------------------
|
|
# ScoutAPM Container
|
|
# -----------------------------------------------------
|
|
- name: scoutapm
|
|
image: "scoutapp/scoutapm:version-1.4.0"
|
|
imagePullPolicy: IfNotPresent
|
|
livenessProbe:
|
|
exec:
|
|
command:
|
|
- "sh"
|
|
- "-c"
|
|
- "./core-agent probe --tcp 0.0.0.0:6590 | grep -q 'Agent found'"
|
|
securityContext:
|
|
readOnlyRootFilesystem: true
|
|
runAsUser: 65534 # "nobody" user by default
|
|
runAsGroup: 65534 # "nogroup" group by default
|
|
# -----------------------------------------------------
|
|
# Celery Container
|
|
# -----------------------------------------------------
|
|
- name: celery
|
|
image: "ghcr.io/ietf-tools/datatracker:$APP_IMAGE_TAG"
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 8000
|
|
name: http
|
|
protocol: TCP
|
|
volumeMounts:
|
|
- name: dt-vol
|
|
mountPath: /a
|
|
- name: dt-tmp
|
|
mountPath: /tmp
|
|
- name: dt-cfg
|
|
mountPath: /workspace/ietf/settings_local.py
|
|
subPath: settings_local.py
|
|
env:
|
|
- name: "CONTAINER_ROLE"
|
|
value: "celery"
|
|
envFrom:
|
|
- configMapRef:
|
|
name: django-config
|
|
securityContext:
|
|
allowPrivilegeEscalation: false
|
|
capabilities:
|
|
drop:
|
|
- ALL
|
|
readOnlyRootFilesystem: true
|
|
runAsUser: 1000
|
|
runAsGroup: 1000
|
|
volumes:
|
|
# To be overriden with the actual shared volume
|
|
- name: dt-vol
|
|
- name: dt-tmp
|
|
emptyDir:
|
|
sizeLimit: "2Gi"
|
|
- name: dt-cfg
|
|
configMap:
|
|
name: files-cfgmap
|
|
dnsPolicy: ClusterFirst
|
|
restartPolicy: Always
|
|
terminationGracePeriodSeconds: 30
|