zowe / docs-site

Documentation for the Zowe project
https://docs.zowe.org/
Creative Commons Attribution 4.0 International
71 stars 133 forks source link

Testing CLI Connection fails if `reject-unauthorized` isn't set #468

Closed adambattenburg closed 5 years ago

adambattenburg commented 5 years ago

Is your request for enhancement related to a problem? Please describe.

Apologies if this behavior is known or intended, but when following the guide to setup the Zowe CLI, the suggested command here to test a connection does not work the first time. Instead I had to use:

zowe profiles create zosmf-profile zoweCLI --host <host> --user <username> --pass <password> --reject-unauthorized false

After having set --rejected-unauthorized false the first time, I'm able to check connections without that flag for future requests.

Describe the solution you'd like

Maybe we could consider adding this as an option to the instructions?

Related doc pages

https://zowe.github.io/docs-site/latest/user-guide/cli-configuringcli.html#testing-zowe-cli-connection-to-z-osmf

under "Without a Profile".

BrandonJenkins14 commented 5 years ago

@adambattenburg A great suggestion! This topic came up in multiple places recently, and I just opened a related issue #462 to write an article about using certificates, the --ru flag, with the CLI.

I will address this one at the same time as the other issue, likely later in this upcoming sprint.

adambattenburg commented 5 years ago

@BrandonJenkins14, I talked to some people on my team, and you do mention this requirement further down on the page so maybe it's just me reading too quickly 😄

I normally prefer to read docs top to bottom when first setting up, but I can see the argument on not mentioning this flag the first time. I'll leave it up to you on whats clearer. Thanks for looking at it Brandon!

BrandonJenkins14 commented 5 years ago

I still think your comment is valid. The --ru flag is mentioned there, but only as an example of how to define environment variables as opposed to something you might want to do when issuing commands in general.

I think that the Create Profiles page should show an example, the Test Connections page should mention that you might need to set the flag (or have certificates set up) in order to test, and then there should be a standalone page that talks about setting up certificates, storing them in NODE_EXTRA_CERTS variable, and generally why you might use the --ru flag.

Thanks!