Bug 1478804 - documentation should never suggest to copy local scripts to /usr/bin
Summary: documentation should never suggest to copy local scripts to /usr/bin
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Docs Transition Guide
Version: Unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: Stephen Wadeley
QA Contact: Russell Dickenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-08-07 07:10 UTC by Evgeni Golov
Modified: 2019-09-26 16:13 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-09 07:26:05 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

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


Note You need to log in before you can comment on or make changes to this bug.