Red Hat Bugzilla – Bug 833759
failed to generate SSH keys when altering domain
Last modified: 2015-05-14 21:58:38 EDT
Description of problem:
remove ssh key and then alter domain on windows,new ssh keys can't be generated.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.create domain and create applications
2.remove ssh keys under C:\Users\window7\.ssh\
3.alter domain (rhc domain alter -a a1)
alter domain failed on windows
error messages are:
C:\Users\window7\test>rhc domain alter -n a1
WARNING: Unable to find 'C:/Users/window7/.ssh/id_rsa.pub'
Your SSH keys are created either by running ssh-keygen (password optional)
or by having the 'rhc domain create' command do it for you. If you created
them on your own (or want to use an existing keypair), be sure to paste
your public key into the express console at http://www.openshift.com.
The client tools use the value of 'ssh_key_file' in express.conf to find
your key followed by the defaults of id_rsa[.pub] and then
Generating OpenShift ssh key to C:/Users/window7/.ssh/id_rsa
: No such file or directory - C:/Users/window7/.ssh/id_rsa.pub (Errno::ENOENT)
n `<top (required)>'
from C:/Ruby193/bin/rhc-domain:23:in `load'
from C:/Ruby193/bin/rhc-domain:23:in `<main>'
ssh keys should be generated,and alter domain will succeed.
The error message should be instructing the user to use 'rhc setup' instead of 'rhc domain create'.
This error is also reproduced after only removing ~/.ssh/libra_id_rsa.pub with build rhc 0.95.4.gem on Fedora 17. But it works fine when removing ~/.ssh/id_rsa.pub&id_rsa
Steps to reproduce:
1.Create one domain: rhc domain create -n test1 -l firstname.lastname@example.org
2.Change the ssh key by removing ~/.ssh/libra_id_rsa.pub
3.Alter domain name and ssh key for email@example.com: rhc domain create -n test2 -l -a firstname.lastname@example.org
#rhc domain create -n jinzhang55 -l -a email@example.com
OpenShift key found at /root/.ssh/id_rsa. Reusing...
/usr/local/share/gems/gems/rhc-0.95.4/bin/rhc-domain:84:in `initialize': No such file or directory - /root/.ssh/id_rsa.pub (Errno::ENOENT)
from /usr/local/share/gems/gems/rhc-0.95.4/bin/rhc-domain:84:in `open'
from /usr/local/share/gems/gems/rhc-0.95.4/bin/rhc-domain:84:in `create_or_alter_domain'
from /usr/local/share/gems/gems/rhc-0.95.4/bin/rhc-domain:326:in `<top (required)>'
from /usr/local/bin/rhc-domain:23:in `load'
from /usr/local/bin/rhc-domain:23:in `<main>'
Please try this again with the new release. A duplicate bug on Linux was fixed and verified.
verified on Window7 + rhc-0.95.13 + ruby 1.9.3
3.remove ssh keys under C:\Users\window7\.ssh\
rhc domain alter -n w7test1
when altering domain, new ssh keys are generated and domain name is altered successfully.
fixed in rhc-0.95.13