Bug 1789266

Summary: Wrong command examples in "oc secrets new --help"
Product: OpenShift Container Platform Reporter: Liang Xia <lxia>
Component: ocAssignee: Maciej Szulik <maszulik>
Status: CLOSED ERRATA QA Contact: zhou ying <yinzhou>
Severity: low Docs Contact:
Priority: medium    
Version: 4.3.0CC: aos-bugs, jokerman, mfojtik
Target Milestone: ---   
Target Release: 4.4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-05-04 11:23:24 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 Liang Xia 2020-01-09 08:32:38 UTC
Description of problem:
Wrong command examples in "oc secrets new --help"

Version-Release number of selected component (if applicable):
$ rpm -q openshift-clients
openshift-clients-4.3.0-202001030600.git.1.5e09fe6.el7.x86_64
$ oc version --client -o yaml
clientVersion:
  buildDate: "2020-01-03T06:08:27Z"
  compiler: gc
  gitCommit: 6a937dfe56ff26255d09702c69b8406040c14505
  gitTreeState: clean
  gitVersion: v4.3.0
  goVersion: go1.12.12
  major: ""
  minor: ""
  platform: linux/amd64


How reproducible:
Always

Steps to Reproduce:
1. Run command "oc secrets new --help"


Actual results:
Wrong command used in examples.
------------------------------------------------------------------------------------
Examples:
  # Create a new secret named my-secret with a key named ssh-privatekey
  oc my-secret ~/.ssh/ssh-privatekey
  
  # Create a new secret named my-secret with keys named ssh-privatekey and ssh-publickey instead of the names of the
keys on disk
  oc my-secret ssh-privatekey=~/.ssh/id_rsa ssh-publickey=~/.ssh/id_rsa.pub
  
  # Create a new secret named my-secret with keys for each file in the folder "bar"
  oc my-secret path/to/bar
  
  # Create a new .dockercfg secret named my-secret
  oc my-secret path/to/.dockercfg
  
  # Create a new .docker/config.json secret named my-secret
  oc my-secret .dockerconfigjson=path/to/.docker/config.json
------------------------------------------------------------------------------------

Expected results:
Examples use correct commands.

Additional info:

Comment 2 zhou ying 2020-02-11 01:45:51 UTC
Can't reproduce the issue now:
[root@localhost ~]# oc version -o yaml 
clientVersion:
  buildDate: "2020-02-10T17:21:47Z"
  compiler: gc
  gitCommit: ee05f83cb8f0bee84c0a1516591437cd71befdc8
  gitTreeState: clean
  gitVersion: v4.4.0
  goVersion: go1.13.4
  major: ""
  minor: ""
  platform: linux/amd64

[root@localhost ~]# oc secret new -h
Manage secrets in your project

 Secrets are used to store confidential information that should not be contained inside of an image. They are commonly
used to hold things like keys for authentication to other internal systems like container image registries.

Aliases:
secrets, secret

Usage:
  oc secrets [flags]

Available Commands:
  link        Link secrets to a ServiceAccount
  unlink      Detach secrets from a ServiceAccount

Use "oc <command> --help" for more information about a given command.
Use "oc options" for a list of global command-line options (applies to all commands).

Comment 4 errata-xmlrpc 2020-05-04 11:23:24 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