* Fix for non-interactive SSH sessions
@ 2015-03-12 20:09 Ludovic Courtès
0 siblings, 0 replies; only message in thread
From: Ludovic Courtès @ 2015-03-12 20:09 UTC (permalink / raw)
To: GuixSD
FYI 9a10acc fixes a bug when running a non-interactive SSH session to a
GuixSD machine (running lshd), as in:
ssh localhost uname
Before, this would result in “command not found” because $PATH would be
left uninitialized. Now there’s a ha^W special trick in the .bashrc
skeleton to handle this use case:
if [ -n "$SSH_CLIENT" -a -z "`type -P cat`" ]
then
# We are being invoked from a non-interactive SSH session
# (as in "ssh host command") but 'cat' cannot be found
# in $PATH. Source /etc/profile so we get $PATH and other
# essential variables.
source /etc/profile
fi
You may want to copy this to your ~/.bashrc.
Ludo’.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2015-03-12 20:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-12 20:09 Fix for non-interactive SSH sessions Ludovic Courtès
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.