Bug 1569084

Summary: capsule-certs-generate suggests scp-ing tarball to Satellite, not to future Capsule
Product: Red Hat Satellite Reporter: Pavel Moravec <pmoravec>
Component: InstallationAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED NOTABUG QA Contact: Katello QA List <katello-qa-list>
Severity: medium Docs Contact:
Priority: low    
Version: 6.3.1CC: chrobert
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-20 06:42:46 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 Pavel Moravec 2018-04-18 15:08:14 UTC
Description of problem:
capsule-certs-generate wrongly suggests where to scp the tarball with certificates - in the step 2. below "Once this is completed", it tells to scp the tarball to the Satellite itself, instead of to the future Capsule, see:

[root@pmoravec-sat63 ~]# hostname -f
pmoravec-sat63.gsslab.brq2.redhat.com
[root@pmoravec-sat63 ~]# capsule-certs-generate --node-fqdn pmoravec-caps63.gsslab.brq2.redhat.com --certs-tar=pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
Installing             Done                                               [100%] [...........................................................................................................]
  Success!
..
  2. Copy the following file /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar to the system pmoravec-sat63.gsslab.brq2.redhat.com at the following location /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
  scp /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar root.brq2.redhat.com:/root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
..

"to the system <capsule-not-satellite>" and "root@<capsule-not-satellite>:" should be there.


Version-Release number of selected component (if applicable):
satellite-6.3.1-3.el7sat.noarch
satellite-installer-6.3.0.12-1.el7sat.noarch


How reproducible:
100%


Steps to Reproduce:
1. Run on Satellite:

CAPSULE=whatever.fqdn.you.come.up
capsule-certs-generate --node-fqdn $CAPSULE --certs-tar=${CAPSULE}-certs.tar 2>&1 | grep "root@${CAPSULE}"


Actual results:
no output


Expected results:
the scp command should be on output


Additional info:

Comment 1 Brad Buckingham 2018-04-19 16:47:55 UTC
Hey Chris,

Do you know if this may be a duplicate?  I recall there being other reports of incorrect output on capsule-certs-generate, but do not see one specifically for this.

Comment 2 Pavel Moravec 2018-04-20 06:42:46 UTC
Mea culpa, I used wrong parameter --node-fqdn instead of --foreman-proxy-fqdn . Using the prior one, I cant even install Capsule as the tarball lacks certificates :) and using the later one, proper scp command etc. is shown:

capsule-certs-generate --foreman-proxy-fqdn pmoravec-caps63.gsslab.brq2.redhat.com --certs-tar=pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
..
  2. Copy the following file /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar to the system pmoravec-caps63.gsslab.brq2.redhat.com at the following location /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
  scp /root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar root.brq2.redhat.com:/root/pmoravec-caps63.gsslab.brq2.redhat.com-certs.tar
..

Docs is clear here, purely human error.