From 442bb4ad5843bca9deb3b6ccd1d9f82a35705b07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reynir=20Bj=C3=B6rnsson?= Date: Fri, 22 Jul 2022 20:39:36 +0200 Subject: [PATCH] Add apt preferences file for dell repo Deny all packages from dell repo that exist elsewhere Fixes #95 --- roles/ubuntu_base/tasks/custom-apt-repos.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/roles/ubuntu_base/tasks/custom-apt-repos.yml b/roles/ubuntu_base/tasks/custom-apt-repos.yml index fc1555d..7bb042d 100644 --- a/roles/ubuntu_base/tasks/custom-apt-repos.yml +++ b/roles/ubuntu_base/tasks/custom-apt-repos.yml @@ -8,8 +8,16 @@ apt_repository: repo: "deb https://linux.dell.com/repo/community/openmanage/10101/focal focal main" state: "present" + +- name: "restrict dell apt repo" + copy: + dest: "/etc/apt/preferences.d/dell" + content: | + Explanation: Deny all packages from this repo that exist elsewhere + Package: * + Pin: origin "linux.dell.com" + Pin-Priority: 400 - name: update apt cache apt: update_cache: yes - \ No newline at end of file