Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: limit resources #6

Merged
merged 3 commits into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions templates/broker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ spec:
{{ end }}
imagePullPolicy: Always
resources:
requests:
memory: "128Mi"
cpu: "0.1"
limits:
memory: "1Gi"
cpu: "0.5"
Expand Down
7 changes: 7 additions & 0 deletions templates/frontend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,13 @@ spec:
image: {{ .Values.deployment.registry }}/polytope-common:{{ .Release.Namespace }}-latest
{{ end }}
imagePullPolicy: Always
resources:
requests:
memory: "128Mi"
cpu: "0.1"
limits:
memory: "2Gi"
cpu: "2"
volumeMounts:
- name: config-volume
mountPath: /etc/polytope
Expand Down
14 changes: 14 additions & 0 deletions templates/worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ spec:
image: {{ .Values.deployment.registry }}/worker:{{ .Release.Namespace }}-latest
{{ end }}
imagePullPolicy: Always
resources:
requests:
memory: "2Gi"
cpu: "1"
limits:
memory: "4Gi"
cpu: "2"
env:
- name: K8S_POD_NAME
valueFrom:
Expand Down Expand Up @@ -168,6 +175,13 @@ spec:
image: {{ .Values.deployment.registry }}/worker:{{ .Release.Namespace }}-latest
{{ end }}
imagePullPolicy: Always
resources:
requests:
memory: "2Gi"
cpu: "1"
limits:
memory: "4Gi"
cpu: "2"
env:
- name: K8S_POD_NAME
valueFrom:
Expand Down
4 changes: 2 additions & 2 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ download_port: &download_port 9000

rabbitmq:
enabled: true
replicaCount: 2
replicaCount: 1
resurcesPreset: xlarge
fullnameOverride: rabbitmq #required for polytope to find the rabbitmq service
auth: #polytope assumes default rabbitmq user and password are set to guest
Expand All @@ -75,7 +75,7 @@ rabbitmq:
perObject:
enabled: true
pdb:
enabled: true
enabled: false
minAvailable: 1

mongodb:
Expand Down