Question 1mediummultiple choice
Read the full Ansible explanation →EX294 Coordinate rolling updates • Complete Question Bank
Complete EX294 Coordinate rolling updates question bank — all 0 questions with answers and detailed explanations.
Refer to the exhibit.
PLAY [Update web servers] ********************************************************
TASK [Gathering Facts] *********************************************************
ok: [web1.example.com]
ok: [web2.example.com]
ok: [web3.example.com]
TASK [Update Apache config] ****************************************************
changed: [web1.example.com] => {
"changed": true,
"msg": "Config updated"
}
changed: [web2.example.com] => {
"changed": true,
"msg": "Config updated"
}
failed: [web3.example.com] => {
"changed": false,
"msg": "Permission denied"
}
TASK [Restart Apache] **********************************************************
ok: [web1.example.com] => {
"changed": true,
"msg": "Service restarted"
}
ok: [web2.example.com] => {
"changed": true,
"msg": "Service restarted"
}
skipping: [web3.example.com]
PLAY RECAP *********************************************************************
web1.example.com : ok=3 changed=2 unreachable=0 failed=0 skipped=0 rescued=0 ignored=0
web2.example.com : ok=3 changed=2 unreachable=0 failed=0 skipped=0 rescued=0 ignored=0
web3.example.com : ok=1 changed=0 unreachable=0 failed=1 skipped=1 rescued=0 ignored=0Refer to the exhibit.
```
- name: Rolling update with load balancer
hosts: webservers
serial: 2
tasks:
- name: Disable server in haproxy
community.general.haproxy:
state: disabled
host: "{{ inventory_hostname }}"
socket: /var/run/haproxy.sock
delegate_to: lb01
- name: Update web server
yum:
name: httpd
state: latest
- name: Enable server in haproxy
community.general.haproxy:
state: enabled
host: "{{ inventory_hostname }}"
socket: /var/run/haproxy.sock
delegate_to: lb01
```Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag a concept onto its matching description — or click a concept then click the description.
Specify target hosts or groups
Enable privilege escalation
Define variables
List of modules to execute
Special tasks run on notification
Refer to the exhibit. $ oc describe deploymentconfig/myapp Strategy: RollingParams: UpdatePeriod: 1s IntervalSeconds: 6s MaxSurge: 25% (1 pod) MaxUnavailable: 25% (1 pod) TimeoutSeconds: 600 Replicas: 4
Refer to the exhibit.
- name: Rolling update
hosts: webservers
serial: 2
max_fail_percentage: 0
tasks:
- name: update app
yum:
name: httpd
state: latest
notify: restart httpdRefer to the exhibit.
```yaml
- name: Rolling update web servers
hosts: webservers
serial: 2
max_fail_percentage: 25
tasks:
- name: disable in haproxy
community.general.haproxy:
state: disabled
host: "{{ inventory_hostname }}"
delegate_to: lb01
- name: update web server
ansible.builtin.yum:
name: httpd
state: latest
- name: enable in haproxy
community.general.haproxy:
state: enabled
host: "{{ inventory_hostname }}"
delegate_to: lb01
```