Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
After provisioning a new host the assigned Ansible roles from hostgroups
are not executed on the new host
Version-Release number of selected component (if applicable):
- Satellite 6.10.1
How reproducible:
Steps to Reproduce:
1. Deploy a new host
2. Check if the default ansible roles have been executed on the new host
Actual results:
- No job is scheduled after the new host finished the build
Expected results:
- A job to run all assigned Ansible roles should be scheduled
Additional info:
- by default webhooks plugin was not installed after update to 6.10
From customer: Ideally we would like to be able to build servers with no manual intervention beyond pressing a button. This makes it so someone has to manually run a Run All Ansible Roles job on a server after it is built. I'm wondering if it might be possible to put in some sort of workaround, possibly using foreman_webhooks.
Hello team,
We have another Customer that hit the same issue. The workaround has been applied from this Bugzilla but Customer has the following query:
The patch made the hook trigger, but how do we pass the name of the host to the hook? When using an URL like this (which works for "Host updated" event):
https://satellite.example.com/svv/provisioning/webhooks/build-exit/<%= @object.name %>
we get the following error:
Backtrace for 'undefined method '#name' for NilClass::Jail (NilClass)' error (Safemode::NoMethodError): undefined method '#name' for NilClass::Jail (NilClass)
The question (and cause for needinfo) in #22 is not really related to this BZ in any way, sorry for derailing the thread. If you reach out to us we'll always try to help, but raising needinfos on sat6-bugs is not the best way, there are better communication channels for this.
> When using an URL like this (which works for "Host updated" event):
The event triggered when a host is updated carries the whole host as @object so you can use @object.name on it.
> but how do we pass the name of the host to the hook?
If I'm reading things right then build status changes carry only the id and hostname of the host as @id and @hostname respectively, so you should be able to do https://satellite.example.com/svv/provisioning/webhooks/build-exit/<%= @hostname %>
Version-Release number of selected component (if applicable):
- Satellite 6.11 - 18
Steps to Reproduce:
1. Create a host group with default Ansible roles.
1. Deploy a new host under that host group.
Actual results:
- A job running the hostgroup's ansible roles was scheduled.
Expected results:
- A job to run all assigned Ansible roles should be scheduled
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (Moderate: Satellite 6.11 Release), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHSA-2022:5498