diff --git a/kubernetes/op-redis-config.yaml b/kubernetes/op-redis-config.yaml new file mode 100644 index 0000000..bdb456d --- /dev/null +++ b/kubernetes/op-redis-config.yaml @@ -0,0 +1,9 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: op-redis-configmap +data: + # Set the arguments passed to Redis + # - maxmemory configures Redis to use a specified amount of memory for the data set + # - maxmemory-policy is the eviction policy used when the maximum memory is reached + REDIS_ARGS: "--maxmemory 256mb --maxmemory-policy volatile-lru" diff --git a/kubernetes/op-scim-deployment.yaml b/kubernetes/op-scim-deployment.yaml index 7595bcc..928ffac 100644 --- a/kubernetes/op-scim-deployment.yaml +++ b/kubernetes/op-scim-deployment.yaml @@ -26,6 +26,13 @@ spec: - name: scimsession mountPath: "/secret" readOnly: false + resources: + requests: + cpu: 125m + memory: 256M + limits: + cpu: 250m + memory: 512M envFrom: - configMapRef: name: op-scim-configmap diff --git a/kubernetes/redis-deployment.yaml b/kubernetes/redis-deployment.yaml index f56690d..af5e9e5 100644 --- a/kubernetes/redis-deployment.yaml +++ b/kubernetes/redis-deployment.yaml @@ -18,3 +18,13 @@ spec: ports: - containerPort: 6379 name: redis + resources: + requests: + cpu: 125m + memory: 256M + limits: + cpu: 250m + memory: 512M + envFrom: + - configMapRef: + name: op-redis-configmap