Re: Calling User Program

Though not strictly an SSH issue, I believe you can also override the 'shell' setting for a designated user. E.G. replace /bin/bash or whatever SHELL you have assigned to that user with /path/to/my/app. The result will be that login shall invoke /path/to/my/app.
read 'man 5 passwd' & 'man useradd'

Alberto Mijares wrote:
On Tue, Aug 25, 2009 at 6:41 PM, linux newbie<linux.newbie79@xxxxxxxxx> wrote:

I am running sshd (version 5.2.p1) in my embedded platform and I can
succesfully login
from ssh client in remote host.

I like to do some modifications. i.e. After typing username and
password, I want to run a application program directly instead of
prompt. I like to know, which file has to be modified?

Thanks in Advance

For wide-system setting:

/etc/profile (sh & bash)

Per-user settings:

~/.profile (sh & bash)
~/.bash_profile (bash)


Alberto Mijares

Relevant Pages

  • Re: tcsh is better for interactive use (Was: Bash command via ssh)
    ... In 1994 I was working on plenty of systems that didn't have bash or tcsh. ... The problem is that you need two useful ways of invoking a command ... Though that would be somewhat of a hack, ssh could simply make this distinction ... shell code, two or more arguments are strings to be passed to execv. ...
  • Re: setting defaults for system variables for users who SSH in to z/OS
    ... setting defaults for system variables for users who SSH in to z/OS ... It's a noninteractive shell. ... What if the user's preferred shell is not bash? ... user will need to exit twice to logoff, ...
  • Re: pkg_delete bash, logged out by accident, cant ssh back in (not good)
    ... Both use bash as default. ... ssh -t user@xxxxxxx /bin/sh works for me ... try to invoke default shell first to then execute what exec requests...) ... Use a different remote account with a different shell. ...
  • (Unix) Login with ssh ... TERM not set.
    ... The account on the target machine I ssh into has sh as a default shell. ... I prefer bash, but don't want to manually invoke 'bash' every time I log in, ...
  • Re: Learning Lisp
    ... I compared VNC to SSH. ... Some programs can work only over VNC or a similar protocol, so I had a chance to compare these approaches. ... Let's say I need to check access rights on file /home/foo/bar.txt on server quux. ... This is what I would call 'doing it myself' -- I think of something, translate it to shell language, type and get results. ...