scale down
This commit is contained in:
@@ -4,51 +4,70 @@ metadata:
|
||||
name: fastapi-api
|
||||
namespace: student-martabulic
|
||||
annotations:
|
||||
argocd.argoproj.io/sync-wave: "1" # deploy NAKON baze
|
||||
argocd.argoproj.io/sync-wave: "1"
|
||||
|
||||
spec:
|
||||
replicas: 1
|
||||
replicas: 0
|
||||
|
||||
selector:
|
||||
matchLabels:
|
||||
app: fastapi-api
|
||||
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: fastapi-api
|
||||
|
||||
spec:
|
||||
containers:
|
||||
- name: fastapi-api
|
||||
image: dvasic/fastapi-todo-api:1.0
|
||||
|
||||
resources:
|
||||
requests:
|
||||
cpu: "5m"
|
||||
memory: "32Mi"
|
||||
limits:
|
||||
cpu: "20m"
|
||||
memory: "64Mi"
|
||||
|
||||
ports:
|
||||
- containerPort: 8000
|
||||
|
||||
env:
|
||||
- name: DATABASE_HOST
|
||||
valueFrom:
|
||||
configMapKeyRef:
|
||||
name: fastapi-config
|
||||
key: DATABASE_HOST
|
||||
|
||||
- name: DATABASE_PORT
|
||||
valueFrom:
|
||||
configMapKeyRef:
|
||||
name: fastapi-config
|
||||
key: DATABASE_PORT
|
||||
|
||||
- name: POSTGRES_USER
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: postgres-secret
|
||||
key: POSTGRES_USER
|
||||
|
||||
- name: POSTGRES_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: postgres-secret
|
||||
key: POSTGRES_PASSWORD
|
||||
|
||||
- name: POSTGRES_DB
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: postgres-secret
|
||||
key: POSTGRES_DB
|
||||
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /health
|
||||
port: 8000
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 5
|
||||
periodSeconds: 5
|
||||
Reference in New Issue
Block a user