Skip to content

Commit 14e8869

Browse files
committed
add retry for dnf and key_by for oci instance
1 parent 535e41f commit 14e8869

File tree

6 files changed

+21
-0
lines changed

6 files changed

+21
-0
lines changed

ol/build.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
-
3232
name: "OS Management Service Agent"
3333
desired_state: DISABLED
34+
key_by: [compartment_id, availability_domain, display_name]
3435
register: result
3536
vars:
3637
timestamp: "{{ now().strftime('%Y%m%d-%H%M%S') }}"

ol/provision_kvm.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
- cockpit-machines
2424
state: present
2525
when: ansible_distribution == 'OracleLinux' and ansible_distribution_major_version == '8'
26+
retries: 5
27+
delay: 10
2628

2729
- name: Install Oracle Linux 9 virtualization packages
2830
ansible.builtin.dnf:
@@ -36,6 +38,8 @@
3638
- cockpit-machines
3739
state: present
3840
when: ansible_distribution == 'OracleLinux' and ansible_distribution_major_version == '9'
41+
retries: 5
42+
delay: 10
3943

4044
- name: Start and enable Oracle Linux 8 monolithic virtualization services
4145
ansible.builtin.systemd:

ol/provision_podman.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
- curl
2121
state: present
2222
when: ansible_distribution == 'OracleLinux' and ansible_distribution_major_version == '8'
23+
retries: 5
24+
delay: 10
2325

2426
- name: Install Oracle Linux 9 container tools packages
2527
ansible.builtin.dnf:
@@ -30,3 +32,5 @@
3032
- curl
3133
state: present
3234
when: ansible_distribution == 'OracleLinux' and ansible_distribution_major_version == '9'
35+
retries: 5
36+
delay: 10

ol/provision_vbox.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
name: oracle-epel-release-el8
1818
state: present
1919
when: ansible_distribution == 'OracleLinux' and ansible_distribution_major_version == '8'
20+
retries: 5
21+
delay: 10
2022

2123
- name: Enable ol8_developer_EPEL repo
2224
ansible.builtin.command:
@@ -34,6 +36,8 @@
3436
- perl
3537
- xcb-util-cursor
3638
state: present
39+
retries: 5
40+
delay: 10
3741

3842
- name: Add virtualbox repo keys
3943
ansible.builtin.rpm_key:
@@ -50,6 +54,8 @@
5054
ansible.builtin.dnf:
5155
name: "VirtualBox-{{ virtualbox_version }}"
5256
state: present
57+
retries: 5
58+
delay: 10
5359

5460
- name: Check if extension pack is already installed
5561
ansible.builtin.shell: |

ol/provision_vnc.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,17 @@
1616
ansible.builtin.dnf:
1717
name: '@Server with GUI'
1818
state: present
19+
retries: 5
20+
delay: 10
1921

2022
- name: Installing the vnc package
2123
ansible.builtin.dnf:
2224
name:
2325
- tigervnc-server
2426
- tigervnc-server-module
2527
state: present
28+
retries: 5
29+
delay: 10
2630

2731
- name: Set systemd default boot target to graphical.target
2832
ansible.builtin.file:

ol/update_all_rpms.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
state: latest
1919
update_only: true
2020
when: ansible_distribution == 'OracleLinux'
21+
retries: 5
22+
delay: 10
2123

2224
- name: Check if a reboot is required
2325
ansible.builtin.command: /usr/bin/needs-restarting -r

0 commit comments

Comments
 (0)