Problem/Justification
There’s a learning curve on where to download and install user command-line tools. (Not through apt-get.) Lacking a source of gentle guidance, every user and every guide author needs to reinvent the wheel in whichever odd pattern comes to mind today. Unruly workarounds have caused trouble for users and iX alike.
Impact
The issue only affects command-line users. The solution only affects command-line users.
User Story
It’s poor form to group three separate requests, but these are a family that I think is best discussed in concert.
- User-installed tools and scripts
Users have scripts that they’ve written or downloaded. Some should be available in the active shell’s search path. I’d like to see simple official guidance on how to make that happen. Specifically: I’d like to be able to point to central documentation from a readme on GitHub.
Currently, outside projects find themselves having to tiptoe around whether to edit .bashrc
or .zshrc
or .profile
or .zshenv
or whatever. It’s a mess for users and contributors both, all of whom could benefit greatly from a common link to a short summary page about the platform’s file hierarchy norms.
FWIW the recommended standard location for user-installed scripts is ~/.local/bin
. Ubuntu includes this in search paths in their default user skeleton. Debian does not. TrueNAS does not. If that remains the case, I’d still like to point to the platform’s published norms and suggestions.
- Local-installed tools and scripts
Similar deal: the standard path is of course /usr/local/bin
and Debian has us covered there. But that’s off limits on TrueNAS. I have no desire to re-litigate that decision, but I would like clarity on the platform’s suggested alternative location.
Would it be possible to configure and document, say, a /home/.shared/bin
for this? Perhaps if presented in stark terms that this should only ever symlink into somewhere on your own pool…
Importantly: none of the above is currently accessible through sudo. So for example “superbackup --start” might say “this command must be run under sudo”, while “sudo superbackup --start” then says “command not found”.
We find ourselves explaining how to edit all style of user shell resources and all style of root shell resources. Or updating independent copies of tools both in ~/.local/bin
and in /root/bin
. Or curating arbitrary symlinks to/from who knows where or why, across various pools and datasets…
Save us from ourselves.
- Sandbox-installed tools and scripts
IMO it would be perfectly appropriate for iX to shut down shell access entirely and for good. Seriously! Don’t stop at walling off /usr/local
and apt-get
, but definitively state that the host environment contains no user-serviceable parts at all.
Instead: actively facilitate setting up one or more guest environments. (Of whatever kinds, be they VM or nspawn or LXC or even Docker with persistent mounts…) This could even be made seamless: funnel every tty session into a container or chroot, etc.
Until that happens we’re left with unfortunate roadblocks in the way of achieving this for ourselves. Whether standing up a full nspawn sandbox from scratch, or even a Python venv without the python3-venv package… help us get out of your way and vice-versa.
Thanks for reading and considering!