diff --git a/playbooks/transient_cloud_instance.yml b/playbooks/transient_cloud_instance.yml index 0ffdfb25ac..6edbae0367 100644 --- a/playbooks/transient_cloud_instance.yml +++ b/playbooks/transient_cloud_instance.yml @@ -45,6 +45,20 @@ - include: "{{ tasks }}/transient_cloud.yml" +- name: Install python2 and dnf as needed + hosts: tmp_just_created + gather_facts: False + + - name: gather facts + setup: + always_run: True + ignore_errors: True + register: facts + + - name: install python2 and dnf stuff + raw: dnf -y install python-dnf libselinux-python + when: facts|failed + - name: provision instance hosts: tmp_just_created gather_facts: True diff --git a/tasks/transient_cloud.yml b/tasks/transient_cloud.yml index cdc51b098a..ddde57018d 100644 --- a/tasks/transient_cloud.yml +++ b/tasks/transient_cloud.yml @@ -53,13 +53,3 @@ # we have to wait some time. 10 sec is usually enough, but not always. - name: waiting for cloud-init pause: seconds=30 - -- name: gather facts - setup: - always_run: True - ignore_errors: True - register: facts - -- name: install python2 and dnf stuff - raw: dnf -y install python-dnf libselinux-python - when: facts|failed