Bug 1923786

Summary: RHV UPI fails with unhelpful message when ASSET_DIR is not set.
Product: OpenShift Container Platform Reporter: Peter Lauterbach <pelauter>
Component: InstallerAssignee: Douglas Schilling Landgraf <dougsland>
Installer sub component: OpenShift on RHV QA Contact: Guilherme Santos <gdeolive>
Status: CLOSED ERRATA Docs Contact:
Severity: medium    
Priority: low CC: ansulliv, bretm, dougsland, gzaidman, mburman, michal.skrivanek
Version: 4.6   
Target Milestone: ---   
Target Release: 4.8.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-07-27 22:37:35 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Peter Lauterbach 2021-02-01 22:06:59 UTC
Version:

$ openshift-install version
OpenShift 4.6 

Platform:
ovirt 

Please specify:
* UPI (semi-manual installation on customized infrastructure)

What happened?

When you use the UPI Ansible playbooks, it relies on the environment variable ASSETS_DIR to be defined and pointing to something real. This is clearly documented.  However, if there use forgets to define this environment variable, when they run the playbook they get the very cryptic and unhelpful error message:

>  [WARNING] provided hosts list is empty, only localhosts is available.  Not that the implicit localhost does not match 'all'
> 
> PLAY [localhost] *****
> 
> TASK [including metadata.json cards] ****
> fatal: [localhost]: FAILED! => {"ansible_facts": {"metadata": {}}, "ansible_included_var_files": [], "changed": false, "message": Could not find or access '/metadata.json' on the Ansible controller.\nIf you are using a module and expect the file to exist on the remote, see the remote_src option"}

What did you expect to happen?

Give the user guidance how to fix the problem. If ASSET_DIR is required to be defined, we can check it before the run, or give a clearer message after the failure.

How to reproduce it (as minimally and precisely as possible)?

Run UPI install without ASSET_DIR defined.

Anything else we need to know?

This failure came up during a recent OpenShift Twitch live stream.

Comment 1 Gal Zaidman 2021-02-02 16:35:59 UTC
Can you please set a priority?

Comment 2 Gal Zaidman 2021-03-30 13:27:27 UTC
due to capacity constraints we will be revisiting this bug in the upcoming sprint

Douglas when are you planning on taking this? I see it is low so removed the target release for now

Comment 3 Douglas Schilling Landgraf 2021-04-17 00:55:28 UTC
We documented about ASSET_DIR, if users decided to go with our UPI documentation.
https://github.com/openshift/installer/blob/master/docs/user/ovirt/install_upi.md#assets-directory

Maybe replace "better" to "required"?

Comment 5 Guilherme Santos 2021-05-11 13:31:12 UTC
Verified as the proposed changes were properly applied. Please, feel free to reopen on ON_QA if you believe an extra look should be taken

Comment 11 errata-xmlrpc 2021-07-27 22:37:35 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 (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), 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-2021:2438

Comment 12 Red Hat Bugzilla 2023-09-15 01:00:12 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 500 days