Project

General

Profile

Bug #34638

Job invocation installs all the installable errata if incorrect `Job Template` is used

Added by Adam Ruzicka 4 months ago. Updated 3 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Target version:
Difficulty:
Triaged:
Yes
Bugzilla link:
Fixed in Releases:
Found in Releases:
Red Hat JIRA:

Description

Description of problem:
Job invocation installs all the installable errata if incorrect `Job Template` is used.

Version-Release number of selected component (if applicable):
Satellite 7.0.0-13.0 RHEL7,RHEL8

How reproducible:
Always

Steps to Reproduce:
1. Sync repos with errata, create lce,cv(promote it),ak
2. Register host and install some packages so that errata is created. (I used 5 errata)
3. Monitor > Jobs > Run Job > Job Category = Katello > Job template = Install errata by search query - Katello SSH Default > Search Query = <registered host> > Errata search query = errataID_1,errataID_2,errataID_3 > Submit
4. You should get a success. Goto Preview templates of the job ran and toggle the job ran.

Actual results:
Under "#Action"(from step 4), you can see `yum -y update-minimal`. That means all the errata have been installed. But only 3 errata were supposed to be installed.

Expected results:
It should have been `yum -y update-minimal --advisory=errataID_1 --advisory=errataID_2 --advisory=errataID_3` so that only the mentioned errata is installed.

Additional info:
Yes, When using `Install errata by search query - Katello SSH Default` to install errata, you're supposed to use it as `id ^ (errataID...)` but incase the customer does not notice it, this step will install all the installable errata for that host(s). Which they might not want.

Adding a searchquery format checker or just let job should fail?

Associated revisions

Revision bbecd8d7 (diff)
Added by Adam Ruzicka 3 months ago

Fixes #34638 - Fail if errata search query matches nothing

History

#1 Updated by The Foreman Bot 4 months ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/Katello/katello/pull/10026 added

#2 Updated by The Foreman Bot 3 months ago

  • Fixed in Releases Katello 4.5.0 added

#3 Updated by Anonymous 3 months ago

  • Status changed from Ready For Testing to Closed

#4 Updated by Ryan Verdile 3 months ago

  • Triaged changed from No to Yes
  • Target version set to Katello 4.5.0

Also available in: Atom PDF