diff --git a/controllers/zuul.go b/controllers/zuul.go index a3b97974..6805c163 100644 --- a/controllers/zuul.go +++ b/controllers/zuul.go @@ -471,7 +471,7 @@ func (r *SFController) EnsureZuulMerger(cfg *ini.File) bool { if r.GetM(service, ¤t) { if !utils.MapEquals(¤t.Spec.Template.ObjectMeta.Annotations, &annotations) { r.log.V(1).Info("zuul-merger configuration changed, rollout zuul-merger pods ...") - current.Spec = zm.DeepCopy().Spec + current.Spec.Template = *zm.Spec.Template.DeepCopy() r.UpdateR(¤t) return false } diff --git a/roles/health-check/scale-resources/defaults/main.yaml b/roles/health-check/scale-resources/defaults/main.yaml index 7750af38..9e5272a9 100644 --- a/roles/health-check/scale-resources/defaults/main.yaml +++ b/roles/health-check/scale-resources/defaults/main.yaml @@ -3,3 +3,6 @@ scaling_services: - name: zuul-executor kind: sts replicas: 2 + - name: zuul-merger + kind: sts + replicas: 2 diff --git a/roles/health-check/zuul-components/tasks/main.yaml b/roles/health-check/zuul-components/tasks/main.yaml index f1b96110..c96d1a79 100644 --- a/roles/health-check/zuul-components/tasks/main.yaml +++ b/roles/health-check/zuul-components/tasks/main.yaml @@ -39,10 +39,10 @@ failed_when: "'running' not in item.state" loop: "{{ _components.json['executor'] }}" -- name: Check if, at least, one Zuul Merger Instances Exists, fails otherwise +- name: Check if, two Zuul Merger Instances Exist, fails otherwise ansible.builtin.fail: - msg: "Zuul Merger has no instances" - when: "_components.json['merger'] | length == 0" + msg: "Zuul Merger must have 2 replicas" + when: "_components.json['merger'] | length != 2" - name: Check if Zuul Merger Components are Running ansible.builtin.fail: