apiVersion: apps/v1 kind: Deployment metadata: name: backend namespace: eav labels: app: backend spec: replicas: 1 selector: matchLabels: app: backend template: metadata: labels: app: backend spec: volumes: - name: django-configmap configMap: name: django-configmap items: - key: production.py path: production.py defaultMode: 420 containers: - name: backend image: cr.yandex/crp3ccidau046kdj8g9q/eav:prod_0fb73247 imagePullPolicy: IfNotPresent ports: - name: http containerPort: 8000 protocol: TCP env: - name: KAFKA_ENABLED value: "False" - name: ASSETS_TOPIC value: sarex - name: DJANGO_SETTINGS_MODULE value: config.settings.production - name: DJANGO_POSTGRES_DATABASE value: eav_db - name: YC_S3_ENDPOINT_URL value: http://minio-svc.minio.svc.cluster.local:9000 - name: YC_S3_BUCKET_NAME value: eav - name: DJANGO_POSTGRES_HOST valueFrom: secretKeyRef: name: postgresql-secret key: hostname - name: DJANGO_POSTGRES_USER valueFrom: secretKeyRef: name: postgresql-secret key: username - name: DJANGO_POSTGRES_PASSWORD valueFrom: secretKeyRef: name: postgresql-secret key: password - name: DJANGO_POSTGRES_PORT valueFrom: secretKeyRef: name: postgresql-secret key: port - name: JWT_PRIVATE_KEY valueFrom: secretKeyRef: name: backend-secret key: ssh_private.key - name: JWT_PUBLIC_KEY valueFrom: secretKeyRef: name: backend-secret key: ssh_public.key - name: YC_S3_ACCESS_KEY_ID valueFrom: secretKeyRef: name: s3-secret key: login - name: YC_S3_SECRET_ACCESS_KEY valueFrom: secretKeyRef: name: s3-secret key: password resources: requests: cpu: 100m memory: 100Mi volumeMounts: - name: django-configmap mountPath: /server/config/settings/production.py subPath: production.py livenessProbe: httpGet: path: /ping port: 8000 initialDelaySeconds: 10 periodSeconds: 60 failureThreshold: 10 readinessProbe: httpGet: path: /ping port: 8000 initialDelaySeconds: 5 periodSeconds: 5 failureThreshold: 20 imagePullSecrets: - name: regcred