Re: ssh-agent with default runlevel of 5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ce 14 février 2003, Michael Kuss a écrit:

> On Fri, 14 Feb 2003, Aaron Konstam wrote:
> 
> > On Fri, Feb 14, 2003 at 11:38:24AM +0000, Neil Marjoram wrote:
> > > Can someone tell me where to call the ssh-agent from when using a
> > > default run level of 5. I usually use run level 3 and place the required
> > > commands in .xinitrc in my home directory, but I have found that using
> > > run level 5 this file is not used.
> > The sshd daemon is set to run at runlevel 5 by using the chkconfig
> > command as so: chkconfig --level 5 sshd on
> > 
> > By the way: chkconfig --level 35 sshd on
> > will get it to run at levels 3 and 5 by default.
> > 
> 
> That's not what Neil is talking about.  He wants to start ssh-agent, thus
> have a window pop up to enter the pass phrase.

If I understand well Neil query, here is what I do.

I edit /etc/X11/xinit/Xclients file and add the following lines at the beginning of the file:

# patch /etc/X11/xinit/Xclient for SSH ---------------------------
if [ -z "$SSH_AGENT_PID" -a -x /usr/bin/ssh-agent ]
then
        exec /usr/bin/ssh-agent $0  ${1+"$@"} < /dev/null
fi
if [ -r $HOME/.ssh/id_dsa ]
then
        /usr/bin/ssh-add $HOME/.ssh/id_dsa < /dev/null
elif [ -r $HOME/.ssh/identity ]
then
        /usr/bin/ssh-add $HOME/.ssh/identity < /dev/null
fi
# end of patch for ssh --------------------------------------------

This works for gnome and kde.
Very usefull if frequent ssh connections to remote accounts are needed.

					Anne



-- 
Psyche-list mailing list
Psyche-list@redhat.com
https://listman.redhat.com/mailman/listinfo/psyche-list

[Index of Archives]     [Fedora General Discussion]     [Red Hat General Discussion]     [Centos]     [Kernel]     [Red Hat Install]     [Red Hat Watch]     [Red Hat Development]     [Red Hat 9]     [Gimp]     [Yosemite News]

  Powered by Linux