Bug 1620126 - In production webpacked_plugins_js_for $PLUGIN doesn't load the js if the plugin doesn't provide the sources
Summary: In production webpacked_plugins_js_for $PLUGIN doesn't load the js if the plu...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Ansible - Configuration Management
Version: Unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: 6.4.0
Assignee: satellite6-bugs
QA Contact: Lukas Pramuk
URL:
Whiteboard:
: 1620124 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-08-22 13:38 UTC by Marek Hulan
Modified: 2019-11-05 23:33 UTC (History)
3 users (show)

Fixed In Version: foreman-1.18.0.14-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-16 19:03:22 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Report OK (138.30 KB, image/png)
2018-09-11 07:55 UTC, Martin Korbel
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 24371 0 None None None 2018-08-22 13:38:18 UTC

Description Marek Hulan 2018-08-22 13:38:14 UTC
On nightly production install some components from foreman_ansible were not showing on the page. The issue was webpackage_plugins_js ignored plugins which didn't provide "webpack/index.js" in their root even though the plugin provided the precompiled assets.

Also webpacked_plugins_js fails silently if it can't find the required js

Comment 1 Marek Hulan 2018-08-22 13:38:22 UTC
Created from redmine issue https://projects.theforeman.org/issues/24371

Comment 2 Marek Hulan 2018-08-22 13:38:28 UTC
Upstream bug assigned to ekohlvan

Comment 3 Marek Hulan 2018-08-22 13:41:08 UTC
the workaround:

mkdir -p /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_ansible-2.2.5/webpack
touch /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_ansible-2.2.5/webpack/index.js
service httpd restart

that will start mounting the component on config foreman_ansible reports page again

Comment 9 Marek Hulan 2018-09-01 06:44:25 UTC
Could you please try applying the workaround from comment 3 to verify it's triggered by the same cause? It seems the patch has been applied correctly.

Comment 13 Marek Hulan 2018-09-07 07:49:32 UTC
*** Bug 1620124 has been marked as a duplicate of this bug. ***

Comment 14 Martin Korbel 2018-09-11 07:55:18 UTC
Created attachment 1482310 [details]
Report OK

Comment 15 Martin Korbel 2018-09-11 07:58:35 UTC
VERIFIED on Sat6.4#21

Reproducer:
1. We have got Sat6.4 and some client machine. On client machine we have to upload Satellite public SSH key.
   > curl -k https://<fqdn>:9090/ssh/pubkey >> ~/.ssh/authorized_keys
2. install some Ansible role to satellite
   > ansible-galaxy install -p /etc/ansible/roles/ linuxhq.setup
3. import this role to Satellite
   > hammer ansible roles import
   ---|--------------------------------|--------------------
   ID | NAME                           | IMPORTED AT        
   ---|--------------------------------|--------------------
   2  | linuxhq.setup                  | 2018/09/11 07:17:47
   3  | RedHatInsights.insights-client | 2018/09/11 07:17:47
   ---|--------------------------------|--------------------

4. assign this role to client profile. We can not use attribute --ansible-roles, because it does not work (bz1590854). 
   > hammer host update --ansible-role-ids 2 --id 1
   Host updated.
5. Open profile of host (Hosts > All hosts > client; in my case https://<fqdn>/hosts/1)
6. Click on the "Run Ansible roles" button and wait for job passes.
7. Open reports (Monitor > Config Management). 
8. choose our client and one of reports
9. we should see table with tree view structure (see attachement 1482310 )

Comment 17 Bryan Kearney 2018-10-16 19:03:22 UTC
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, 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-2018:2927


Note You need to log in before you can comment on or make changes to this bug.