The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

jailshell and setting up timezone as a user?

Discussion in 'General Discussion' started by jsosic, May 8, 2007.

  1. jsosic

    jsosic Registered

    May 8, 2007
    Likes Received:
    Trophy Points:
    Hi guys.

    Where can I find documentation for jailshell? It writes history down to .bash_history, but it doesn't read .bashrc at startup, and if I want to set up my timezone being different from the system timezone, then I have to set up TZ variable, but that ain't happening - once again - because jailshell doesn't read ~/.bashrc file.

  2. SoftDux

    SoftDux Well-Known Member

    May 27, 2006
    Likes Received:
    Trophy Points:
    Johannesburg, South Africa
    cPanel Access Level:
    Root Administrator
    I don't think this has todo with jailshell, but rather with bash (which is probably "bound" to jailshell.

    Use the .bach_profile files instead of the .bashrc file.

    From the bach man page:

          [B]When bash is invoked as an interactive login shell[/B], or  as  a  non-interactive  shell
           with the --login option, it first reads and executes commands from the file /etc/pro-
           file, if that file exists.  After reading that file, it  looks  for  [B]~/.bash_profile[/B],
           ~/.bash_login,  and  ~/.profile,  in that order, and reads and executes commands from
           the first one that exists and is readable.  The --noprofile option may be  used  when
           the shell is started to inhibit this behavior.
           When   a  login  shell  exits,  bash  reads  and  executes  commands  from  the  file
           ~/.bash_logout, if it exists.
           [B]When an interactive shell that is not a login shell is started[/B], bash reads  and  exe-
           cutes  commands  from[B] ~/.bashrc[/B], if that file exists.  This may be inhibited by using
           the --norc option.  The --rcfile file option will force bash to read and execute com-
           mands from file instead of ~/.bashrc.

Share This Page