From 912b159638a6ea8f7361624f6f4ab6b1aee2680e Mon Sep 17 00:00:00 2001 From: mikeeq Date: Tue, 5 Nov 2024 13:25:29 +0100 Subject: [PATCH] ubuntu fix for pip v2 --- Dockerfile-ubuntu | 1 + roles/apps/docker/tasks/install.yml | 4 ++-- roles/desktop/machines/wsl/tasks/main.yml | 8 ++++---- roles/pkg_mgmt/pip/tasks/main.yml | 5 +++++ 4 files changed, 12 insertions(+), 6 deletions(-) diff --git a/Dockerfile-ubuntu b/Dockerfile-ubuntu index 7dafccdf..dc7596c1 100644 --- a/Dockerfile-ubuntu +++ b/Dockerfile-ubuntu @@ -2,6 +2,7 @@ FROM ubuntu:24.04 # ENV container docker ENV UBUNTU_USERNAME=mikee +ENV DEBIAN_FRONTEND=noninteractiv RUN apt-get update \ && apt-get upgrade -y \ diff --git a/roles/apps/docker/tasks/install.yml b/roles/apps/docker/tasks/install.yml index 6b1a489f..d1e55e00 100644 --- a/roles/apps/docker/tasks/install.yml +++ b/roles/apps/docker/tasks/install.yml @@ -7,7 +7,7 @@ ignore_errors: true - name: Remove old deps before installing docker - package: + dnf: name: "{{ pkgs }}" state: absent when: docker_check.rc != 0 @@ -36,7 +36,7 @@ when: docker_repo_check.rc != 0 - name: Install Docker - package: + dnf: name: "{{ pkgs }}" state: present vars: diff --git a/roles/desktop/machines/wsl/tasks/main.yml b/roles/desktop/machines/wsl/tasks/main.yml index a687cfab..ddcdc487 100644 --- a/roles/desktop/machines/wsl/tasks/main.yml +++ b/roles/desktop/machines/wsl/tasks/main.yml @@ -20,10 +20,10 @@ upgrade: dist update_cache: yes -- name: Install python3.11 package - apt: - name: "python3.11" - state: present +# - name: Install python3.11 package +# apt: +# name: "python3.11" +# state: present - name: Install packages apt: diff --git a/roles/pkg_mgmt/pip/tasks/main.yml b/roles/pkg_mgmt/pip/tasks/main.yml index 14a3a89b..432ce525 100644 --- a/roles/pkg_mgmt/pip/tasks/main.yml +++ b/roles/pkg_mgmt/pip/tasks/main.yml @@ -1,4 +1,9 @@ --- +- name: Remove all system-wide errors in pip + shell: rm -rfv /usr/lib/*/EXTERNALLY-MANAGED + register: pip_ext_managed + changed_when: pip_ext_managed.stdout != "" + - name: Install PIP virtualenv pip: name: "virtualenv"