From e5ba37936697652ef6e049a25f777846e9a19605 Mon Sep 17 00:00:00 2001 From: Neil Hanlon Date: Sat, 12 Feb 2022 17:04:54 -0500 Subject: [PATCH] get python3 working again --- ansible/playbooks/tasks/infra-host.yml | 5 +++-- ansible/playbooks/tasks/init-nodes.yml | 2 +- ansible/playbooks/tasks/python3-lxc.yml | 6 ++++++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/ansible/playbooks/tasks/infra-host.yml b/ansible/playbooks/tasks/infra-host.yml index 52c6590..f0c118d 100644 --- a/ansible/playbooks/tasks/infra-host.yml +++ b/ansible/playbooks/tasks/infra-host.yml @@ -94,8 +94,9 @@ - name: patch the thing args: chdir: /etc/ansible/roles/os_nova/ - ansible.builtin.shell: patch -p1 < /tmp/os_nova.patch - when: do_patch | default(true) | bool + creates: /etc/ansible/roles/os_nova/.patched + ansible.builtin.shell: 'patch -p1 < /tmp/os_nova.patch && touch .patched' + - name: Disable SSH Agent Forwarding lineinfile: diff --git a/ansible/playbooks/tasks/init-nodes.yml b/ansible/playbooks/tasks/init-nodes.yml index 51d0f1b..57da194 100644 --- a/ansible/playbooks/tasks/init-nodes.yml +++ b/ansible/playbooks/tasks/init-nodes.yml @@ -141,7 +141,7 @@ user: root state: present key: "{{ lookup('file', 'files/buffer/infra-id_rsa.pub') }}" - when: tag.find("infra") == -1 and sshkey_fetch + when: tag.find("infra") == -1 and sshkey_fetch | default(false) tags: sshkey #- name: Setup a hosts file for the static deployment diff --git a/ansible/playbooks/tasks/python3-lxc.yml b/ansible/playbooks/tasks/python3-lxc.yml index 940fd0f..4beaa1a 100644 --- a/ansible/playbooks/tasks/python3-lxc.yml +++ b/ansible/playbooks/tasks/python3-lxc.yml @@ -16,9 +16,15 @@ with_items: - python38-lxc-3.0.4-11.el8.x86_64.rpm +# @TODO - fix this to not be shit +- name: Install neil/lxc3.0 copr + become: yes + shell: "dnf -y copr enable neil/lxc3.0" + - name: Install package ansible.builtin.dnf: name: "{{ item }}" + disable_gpg_check: yes # @TODO NO with_items: - https://download.copr.fedorainfracloud.org/results/neil/lxc3.0/epel-8-x86_64/03253339-lxc/lxc-4.0.10-2.el8.x86_64.rpm - https://download.copr.fedorainfracloud.org/results/neil/lxc3.0/epel-8-x86_64/03253339-lxc/lxc-devel-4.0.10-2.el8.x86_64.rpm