Progress report: Ruby Enterprise Edition documentation
One of the goals of the second Ruby Enterprise Edition sponsorship campaign is to have better documentation. I’m almost done with the documentation, and a preview is a available here.
Some REE features involve setting environment variables. Setting environment variables in the shell by calling ‘export FOO=bar’ has no permanent effect. Setting the environment variables in bashrc/profile is permanent, but doesn’t always work; for example Apache (and other processes which are typically started by the system init process) ignores bashrc/profile. There’s /etc/environment, but this seems to be Linux-specific, perhaps even Debian-specific.
Does anybody know a cross-platform method to permanently set environment variables for all processes? If no such method exists, how would one permanently set environment variables in FreeBSD, OS X and Solaris?

mla said,
January 9, 2009 @ 10:54 pm
Are you sure you want to do that? I mean, it sounds simple from an installation standpoint, but isn’t rather gross to expose REE environment to every process? Imagine if every application did that.
If you look at most init scripts, they usually set the environment variables there and start the process.
Hongli Lai said,
January 10, 2009 @ 1:08 am
Whether it’s gross depends on the person. So far I’ve received a lot of comments from people who think that specifying a wrapper script for the PassengerRuby config option is more gross than setting variables permanently and system-wide.