Red Hat Bugzilla – Bug 991250
'rhc' command does not read the default configuration file in /etc/openshift/
Last modified: 2016-07-03 20:44:26 EDT
Description of problem:
After removing ~/.openshift/ and update broker in /etc/openshift/express.conf. 'rhc' command doesn't read the configuration file in /etc/openshift/.
But run `rhc setup`,could read the default configuration file.
Version-Release number of selected component (if applicable):
Step to Reproduce:
1.configure the file like below:
# cat /etc/openshift/express.conf
# Remote API server
libra_server = 'broker.rhn.com'
2.delete the local configration
#rm -rf ~/.openshift/
3.execute the command to login
the command try to login to openshift.redhat.com
the result like below
[root@localhost ~]# rhc
OpenShift Client Tools (RHC) Setup Wizard
This wizard will help you upload your SSH keys, set your application namespace, and check that other programs like Git are properly installed.
Login to openshift.redhat.com:
the help content of rhc should be given ,or try to login to broker.rhn.com
I'm pretty sure we removed all support for this, and didn't intend it to be used anywhere except for 'rhc setup'.
When removing ~/.openshift/express.conf and keeping /etc/openshift/express.conf with a given libra_server:
- single 'rhc' command launches the wizard against openshift.redhat.com
- 'rhc setup' launches it against the libra_server configured on /etc/openshift/express.conf
The wizard should behave equally on these two scenarios.
(In reply to Clayton Coleman from comment #1)
> I'm pretty sure we removed all support for this, and didn't intend it to be
> used anywhere except for 'rhc setup'.
Fixed in https://github.com/openshift/rhc/pull/531
The single 'rhc' command should now launch the wizard using the same context as 'rhc setup'. Every other command will still ignore /etc/openshift/express.conf.
In fact we decided to change this. When calling 'rhc' alone we will display the help no matter if OpenShift is configured or not. Please validate.
Commits pushed to master at https://github.com/openshift/rhc
Bug 991250 - 'rhc' must call wizard with the same context as 'rhc setup'
Bug 991250 - changed the behavior of the 'rhc' command called alone to display help instead of the wizard if it's not configured
check on devenv_4186
1.remove all configuration, then run the rhc command.
2.run "rhc setup", then run rhc
3.remove ~/.openshift/express.conf and keep /etc/openshift/express.conf, then run rhc command
The output of the three scenarios is the help content.