Bug 1478804

Summary: documentation should never suggest to copy local scripts to /usr/bin
Product: Red Hat Satellite Reporter: Evgeni Golov <egolov>
Component: Docs Transition GuideAssignee: Stephen Wadeley <swadeley>
Status: CLOSED CURRENTRELEASE QA Contact: Russell Dickenson <rdickens>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: UnspecifiedCC: egolov, swadeley
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-09 07:26:05 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 Evgeni Golov 2017-08-07 07:10:30 UTC
Document URL: 
https://access.redhat.com/documentation/en-us/red_hat_satellite/6.2/html/transition_guide/chap-red_hat_satellite-transition_guide-transitioning_from_satellite_5_to_6#sect-Red_Hat_Satellite-Transition_Guide-Migrating_a_System_Using_The_Bootstrap_Script

Section Number and Name: 
3.6.10. Migrating Existing Systems Using The Bootstrap Script

Describe the issue: 
When downloading the bootstrap.py script, the docs currently suggest:
  As root, change to a directory suitable for scripts. For example:
  # cd /usr/bin/
IMHO the documentation should never suggest to add non-packaged files to /usr/bin (or any other folder in /usr, that is not /usr/local/*).

Suggestions for improvement: 
Change /usr/bin to /usr/local/bin (or /usr/local/sbin, as bootstrap.py is not usable by non-root).

Additional information: 
Technically, you don't need to place the script in $PATH at all. It will be called *once* per machine and can be removed after that.
If doing so, the check step "Change back to the root directory and confirm the script can be run without "./"" should be dropped too.

Comment 1 Stephen Wadeley 2017-08-07 07:41:24 UTC
Thank you for raising this bug

If it will only be used once, and then deleted, then I guess just putting it in root is OK

I can say, "As the script is only required one, and only for the root user, you can place it in /root and remove it after use or place it in /usr/local/sbin.

Sounds good?

Comment 2 Evgeni Golov 2017-08-07 08:24:22 UTC
Yes, when doing migrations at customers I usually placed it in /root (not /tmp or /var/tmp as those often have no exec-perms!)

ACK on your wording.

Comment 4 Stephen Wadeley 2017-08-07 09:18:21 UTC
(In reply to Evgeni Golov from comment #2)
> Yes, when doing migrations at customers I usually placed it in /root (not
> /tmp or /var/tmp as those often have no exec-perms!)
> 
Interesting, I can see I lack practical knowledge.

What about the use of wget? Is that annoying as it is not installed by default? Should be change to `curl -O` ?


Thank you

Comment 5 Evgeni Golov 2017-08-07 09:35:49 UTC
(In reply to Stephen Wadeley from comment #4)
> (In reply to Evgeni Golov from comment #2)
> > Yes, when doing migrations at customers I usually placed it in /root (not
> > /tmp or /var/tmp as those often have no exec-perms!)
> > 
> Interesting, I can see I lack practical knowledge.

pre-SELinux "security" features that are still widely used in corps.

> What about the use of wget? Is that annoying as it is not installed by
> default? Should be change to `curl -O` ?

I would certainly not object to changing wget to curl -O, but I guess we probably just should go and do that over all our docs in one run?

Comment 6 Stephen Wadeley 2017-08-07 09:51:07 UTC
(In reply to Evgeni Golov from comment #5)
> (In reply to Stephen Wadeley from comment #4)
> > (In reply to Evgeni Golov from comment #2)

> 
> > What about the use of wget? Is that annoying as it is not installed by
> > default? Should be change to `curl -O` ?
> 
> I would certainly not object to changing wget to curl -O, but I guess we
> probably just should go and do that over all our docs in one run?

OK, leave it for another bug and another day

Thank you

Comment 14 Stephen Wadeley 2017-08-10 06:58:54 UTC
Bug 1480093 - Fix bootstrap section to match Transition Guide's section