Skip to content

Commit 1689a28

Browse files
authored
update redis resource config to prevent frequent evictions (#1383)
* update redis resource config to prevent frequent evictions * Remove "safe-to-evict" config and add strategy * update redis config for eks
1 parent b69bdcf commit 1689a28

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

k8s/base/aws_eks/deployments/redis.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ metadata:
1515
name: redis-db
1616
spec:
1717
replicas: 1
18+
strategy:
19+
type: Recreate
1820
selector:
1921
matchLabels:
2022
app: redis-db
@@ -50,3 +52,13 @@ spec:
5052
targetPort: 6379
5153
selector:
5254
app: redis-db
55+
---
56+
apiVersion: policy/v1
57+
kind: PodDisruptionBudget
58+
metadata:
59+
name: redis-pdb
60+
spec:
61+
minAvailable: 1
62+
selector:
63+
matchLabels:
64+
app: redis-db

k8s/base/gcp_gke/redis.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ metadata:
1515
name: redis-db
1616
spec:
1717
replicas: 1
18+
strategy:
19+
type: Recreate
1820
selector:
1921
matchLabels:
2022
app: redis-db
@@ -50,3 +52,13 @@ spec:
5052
targetPort: 6379
5153
selector:
5254
app: redis-db
55+
---
56+
apiVersion: policy/v1
57+
kind: PodDisruptionBudget
58+
metadata:
59+
name: redis-pdb
60+
spec:
61+
minAvailable: 1
62+
selector:
63+
matchLabels:
64+
app: redis-db

0 commit comments

Comments
 (0)