Bug 1798961 - The `oc adm catalog build` help example is wrong
Summary: The `oc adm catalog build` help example is wrong
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 4.4
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: 4.4.0
Assignee: Maciej Szulik
QA Contact: Jian Zhang
URL:
Whiteboard:
: 1798958 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-02-06 12:07 UTC by Jian Zhang
Modified: 2020-09-28 20:31 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-05-13 21:56:25 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Github https://github.com/openshift oc pull 285 None None None 2020-09-29 14:28:20 UTC
Github openshift oc pull 285 None closed Bug 1798961: correct the example info 2020-09-29 14:28:19 UTC
Red Hat Product Errata RHBA-2020:0581 None None None 2020-05-13 21:56:26 UTC

Description Jian Zhang 2020-02-06 12:07:59 UTC
Description of problem:
The help example of the `oc adm catalog build` should NOT display the:

  oc adm catalog mirror --appregistry-org=redhat-operators --to=file://offline/redhat-operators:4.3
...

Version-Release number of selected component (if applicable):
[jzhang@dhcp-140-36 ~]$ oc version
Client Version: 4.4.0-0.nightly-2020-02-04-032141

How reproducible:
always

Steps to Reproduce:
1. Run command: `oc adm catalog build --help`

Actual results:

[jzhang@dhcp-140-36 ~]$ oc adm catalog build --help
Builds a catalog container image from a collection operator manifests.

 Extracts the contents of a collection of operator manifests to disk, and builds them into an operator registry catalog
image.

Usage:
  oc adm catalog build [flags]

Examples:
  # Build an operator catalog from an appregistry repo and store in a file
  oc adm catalog mirror --appregistry-org=redhat-operators --to=file://offline/redhat-operators:4.3
  
  # Build an operator catalog from an appregistry repo and mirror to a registry
  oc adm catalog mirror --appregistry-org=redhat-operators --to=quay.io/my/redhat-operators:4.3

Expected results:
Should be `build`, not the `mirror` in the example info:

  oc adm catalog mirror --appregistry-org=redhat-operators --to=file://offline/redhat-operators:4.3
  oc adm catalog mirror --appregistry-org=redhat-operators --to=quay.io/my/redhat-operators:4.3

Additional info:

Comment 1 Maciej Szulik 2020-02-11 08:50:29 UTC
*** Bug 1798958 has been marked as a duplicate of this bug. ***

Comment 3 Jian Zhang 2020-02-14 05:55:04 UTC
[jzhang@dhcp-140-36 ~]$ ./oc version -o yaml
clientVersion:
  buildDate: "2020-02-13T20:11:27Z"
  compiler: gc
  gitCommit: 5d7a12f03389b03b651f963cb5ee8ddfa9cff559
  gitTreeState: dirty
  gitVersion: openshift-clients-4.4-51-g5d7a12f0
  goVersion: go1.13.4
  major: ""
  minor: ""
  platform: linux/amd64
releaseClientVersion: 4.4.0-0.nightly-2020-02-13-212616
serverVersion:
  buildDate: "2019-05-02T11:52:09Z"
  compiler: gc
  gitCommit: d4cacc0
  gitTreeState: clean
  gitVersion: v1.11.0+d4cacc0
  goVersion: go1.10.8
  major: "1"
  minor: 11+
  platform: linux/amd64

[jzhang@dhcp-140-36 ~]$ ./oc adm catalog build --help
Builds a catalog container image from a collection operator manifests.

 Extracts the contents of a collection of operator manifests to disk, and builds them into an operator registry catalog
image.

Usage:
  oc adm catalog build [flags]

Examples:
  # Build an operator catalog from an appregistry repo and store in a file
  oc adm catalog build --appregistry-org=redhat-operators --to=file://offline/redhat-operators:4.3
  
  # Build an operator catalog from an appregistry repo and mirror to a registry
  oc adm catalog build --appregistry-org=redhat-operators --to=quay.io/my/redhat-operators:4.3
...

LGTM, verify it.

Comment 5 errata-xmlrpc 2020-05-13 21:56:25 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/RHBA-2020:0581


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