Add memory request to pinniped deployment

- We are not setting an upper limit because Kubernetes might randomly
  decide to unschedule our pod in ways that we can't anticipate in
  advance, causing very hard to reproduce production bugs.
- We noticed that our app currently uses ~30 MB of memory when idle,
  and ~35 MB of memory under some load. So a memory request of 128
  MB should be reasonable.

Signed-off-by: Andrew Keesler <akeesler@vmware.com>
This commit is contained in:
Ryan Richard 2020-08-28 15:18:48 -04:00 committed by Andrew Keesler
parent 371b172616
commit f0c400235a
No known key found for this signature in database
GPG Key ID: 27CE0444346F9413

View File

@ -50,7 +50,6 @@ data:
.dockerconfigjson: #@ data.values.image_pull_dockerconfigjson
#@ end
---
#! TODO set resource minimums (e.g. 512MB RAM) to make sure we get scheduled onto a reasonable node?
apiVersion: apps/v1
kind: Deployment
metadata:
@ -83,6 +82,9 @@ spec:
image: #@ data.values.image_repo + ":" + data.values.image_tag
#@ end
imagePullPolicy: IfNotPresent
resources:
requests:
memory: "128Mi"
args:
- --config=/etc/config/pinniped.yaml
- --downward-api-path=/etc/podinfo