Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 26 Feb 2002 17:14:52 +0100
From:      Cliff Sarginson <csfbsd@raggedclown.net>
To:        freebsd-questions@freebsd.org
Subject:   Re: System-wide environment variables
Message-ID:  <20020226161452.GA482@raggedclown.net>
In-Reply-To: <1014735740.677.25.camel@blackbox.pacbell.net>
References:  <20020226030324.4a94cc33.doktorn@realworld.nu> <1014689577.677.0.camel@blackbox.pacbell.net> <20020226025447.GA21944@dan.emsphone.com> <1014696241.677.5.camel@blackbox.pacbell.net> <20020226051544.GC1931@raggedclown.net> <1014735740.677.25.camel@blackbox.pacbell.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Feb 26, 2002 at 07:02:20AM -0800, Mike Makonnen wrote:
> On Mon, 2002-02-25 at 21:15, Cliff Sarginson wrote:
> > On Mon, Feb 25, 2002 at 08:04:01PM -0800, Mike Makonnen wrote:
> > > On Mon, 2002-02-25 at 18:54, Dan Nelson wrote:
> > > > In the last episode (Feb 25), Mike Makonnen said:
> > > > > On Mon, 2002-02-25 at 18:03, Rickard Borgmäster wrote:
> > > > >  
> > > > > > Where should i put this? Into rc.conf.local or something maybe?
> > > > > 
> > > > > .login
> > > > 
> > > > That only works if you use /bin/sh as your shell.  
> > > 
> > > or csh/tcsh (which is the same thing now).
> > > 
> > Nope. ".login" is only used by the (t)csh.
> > That does not answer the question, which is how to set global
> > environment variables that are there without having to login
> > to get them set. 
> 
> I can't remember if that's what he wanted or not. If it is then you're
> right .login/.profile/login.conf won't help.
> 
> > Any such program will inherit the exported environment
> > from it's parent process. Examination of /etc/rc will lead
> > you to see what they will be for startup daemons and such like.
> > Examination of the non-interactive behaviour of a shell startup
> > script (if one is used) will tell you what that environment will
> > be. Use of the "env" command may also help.
> 
> I can't remember what he originally wanted this for, but the solution
> might be to put whatever he needs this for in a wrapper script. 

Yes that is what I would do.
If they are cron jobs, he should also note the conditions under which
cron jobs run as described in the manual pages.

-- 
Regards
   Cliff Sarginson -- <csfbsd@raggedclown.net>

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020226161452.GA482>