1
0

app-deployment.yaml 1014 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. apiVersion: apps/v1
  2. kind: Deployment
  3. metadata:
  4. name: food-ai-app
  5. namespace: food-ai
  6. spec:
  7. replicas: 1
  8. selector:
  9. matchLabels:
  10. app: food-ai-app
  11. template:
  12. metadata:
  13. labels:
  14. app: food-ai-app
  15. spec:
  16. containers:
  17. - name: app
  18. image: food-ai-app:latest
  19. ports:
  20. - containerPort: 8501
  21. env:
  22. - name: LOG_PATH
  23. value: "/logs"
  24. - name: EMAIL_USER
  25. valueFrom:
  26. secretKeyRef:
  27. name: food-ai-secrets
  28. key: EMAIL_USER
  29. - name: EMAIL_PASS
  30. valueFrom:
  31. secretKeyRef:
  32. name: food-ai-secrets
  33. key: EMAIL_PASS
  34. volumeMounts:
  35. - name: logs
  36. mountPath: /logs
  37. resources:
  38. limits:
  39. cpu: "1"
  40. memory: "1Gi"
  41. requests:
  42. cpu: "500m"
  43. memory: "512Mi"
  44. volumes:
  45. - name: logs
  46. persistentVolumeClaim:
  47. claimName: logs-pvc