Bug 2009204

Summary: InfraEnv condition does not reflect the actual error message
Product: Red Hat Advanced Cluster Management for Kubernetes Reporter: Fred Rolland <frolland>
Component: Infrastructure OperatorAssignee: Fred Rolland <frolland>
Status: CLOSED ERRATA QA Contact: bjacot
Severity: medium Docs Contact: Christopher Dawson <cdawson>
Priority: medium    
Version: rhacm-2.4CC: aos-bugs, ccrum, mfilanov, trwest, yfirst
Target Milestone: ---Keywords: Triaged
Target Release: rhacm-2.5Flags: ming: rhacm-2.4+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: AI-Team-Hive
Fixed In Version: OCP-Metal-v1.0.26.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2010030 (view as bug list) Environment:
Last Closed: 2021-11-11 18:33:32 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:
Bug Depends On:    
Bug Blocks: 2010030    

Description Fred Rolland 2021-09-30 07:35:49 UTC
Description of problem:

When an error happens in the InfraEnv controller loop, for example a non existing pull secret, the error in the conditions shows :
'Failed to create image: internal error'
without the error message from the underlying error.

Version-Release number of selected component (if applicable):


How reproducible:
100%

Steps to Reproduce:
1. Create an InfraEnv CR with a wrong pull secret name
2. Check InfraEnv conditions.

Actual results:

  conditions:
  - lastTransitionTime: "2021-09-30T07:20:31Z"
    message: 'Failed to create image: internal error'
    reason: ImageCreationError
    status: "False"
    type: ImageCreated

Expected results:
  conditions:
  - lastTransitionTime: "2021-09-30T07:20:31Z"
    message: 'Failed to create image: internal error: failed to get secret assisted-installer/pull-secret-nope from API: secrets "pull-secret-nope" not found"'
    reason: ImageCreationError
    status: "False"
    type: ImageCreated


Additional info:

Comment 5 errata-xmlrpc 2021-11-11 18:33:32 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 (Important: Red Hat Advanced Cluster Management 2.4 images and security updates), 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:4618