Skip to content

Commit fa26ee6

Browse files
committed
Fix cluster resizing when running cortex cluster configure (#1568)
(cherry picked from commit dceb1a9)
1 parent 444a4ed commit fa26ee6

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

manager/install.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,12 @@ function cluster_configure() {
105105
setup_secrets
106106
echo ""
107107

108+
# this is necessary since max_instances may have been updated
109+
echo -n "○ configuring autoscaling "
110+
python render_template.py $CORTEX_CLUSTER_CONFIG_FILE manifests/cluster-autoscaler.yaml.j2 > /workspace/cluster-autoscaler.yaml
111+
kubectl apply -f /workspace/cluster-autoscaler.yaml >/dev/null
112+
echo ""
113+
108114
restart_operator
109115

110116
validate_cortex

manager/manifests/cluster-autoscaler.yaml.j2

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,3 +199,7 @@ spec:
199199
- name: ssl-certs
200200
hostPath:
201201
path: "/etc/ssl/certs/ca-bundle.crt"
202+
strategy:
203+
type: RollingUpdate
204+
rollingUpdate:
205+
maxSurge: 0 # necessary because there may not be enough room on the operator node for a rolling update

0 commit comments

Comments
 (0)