From c9639c41f9b2ae83fd8e2c02923e4b075d30aa9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hozza?= Date: Wed, 9 Apr 2025 14:46:24 +0200 Subject: [PATCH] Stages/rhsm: support setting 'auto_enable_yum_plugins' option MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Support setting the `auto_enable_yum_plugins` option in the `rhsm` section of `rhsm.conf`. Add a unit test for the stage schema and also adjust the stage test manifest. Related to: https://github.com/osbuild/images/issues/1408 Signed-off-by: Tomáš Hozza --- stages/org.osbuild.rhsm.meta.json | 4 ++++ test/data/stages/rhsm/b.json | 3 ++- test/data/stages/rhsm/b.mpp.yaml | 1 + test/data/stages/rhsm/diff.json | 2 +- 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/stages/org.osbuild.rhsm.meta.json b/stages/org.osbuild.rhsm.meta.json index dbac77ba..5d9af71b 100644 --- a/stages/org.osbuild.rhsm.meta.json +++ b/stages/org.osbuild.rhsm.meta.json @@ -71,6 +71,10 @@ "manage_repos": { "type": "boolean", "description": "Whether subscription-manager should manage DNF repos file" + }, + "auto_enable_yum_plugins": { + "type": "boolean", + "description": "Whether yum/dnf plugins subscription-manager and product-id should be enabled every-time subscription-manager or subscription-manager-gui is executed" } } }, diff --git a/test/data/stages/rhsm/b.json b/test/data/stages/rhsm/b.json index 19e5a973..53be3825 100644 --- a/test/data/stages/rhsm/b.json +++ b/test/data/stages/rhsm/b.json @@ -755,7 +755,8 @@ }, "subscription-manager": { "rhsm": { - "manage_repos": false + "manage_repos": false, + "auto_enable_yum_plugins": false }, "rhsmcertd": { "auto_registration": true diff --git a/test/data/stages/rhsm/b.mpp.yaml b/test/data/stages/rhsm/b.mpp.yaml index 278a92e8..6b8b4570 100644 --- a/test/data/stages/rhsm/b.mpp.yaml +++ b/test/data/stages/rhsm/b.mpp.yaml @@ -38,5 +38,6 @@ pipelines: subscription-manager: rhsm: manage_repos: false + auto_enable_yum_plugins: false rhsmcertd: auto_registration: true diff --git a/test/data/stages/rhsm/diff.json b/test/data/stages/rhsm/diff.json index 63ba55b3..709af2a1 100644 --- a/test/data/stages/rhsm/diff.json +++ b/test/data/stages/rhsm/diff.json @@ -17,7 +17,7 @@ "/etc/rhsm/rhsm.conf": { "content": [ "sha256:57e2bee5a30283ee95f3da2d5945f1d5852f1a4ed6900d22afd8f6a5ee5e5a11", - "sha256:aeb3eca521d423823acc5dc0e7d3409b6570e71174306871c1a861e387369933" + "sha256:881061a0cbca545ba30b76f84c47d623e086e0b5dadec91fb5d53a8292681652" ] } }