Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 140772 - Allow ebuilds to whitelist environment variables for init scripts
Summary: Allow ebuilds to whitelist environment variables for init scripts
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High enhancement
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-17 05:38 UTC by Jakub Moc (RETIRED)
Modified: 2007-11-22 23:02 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Allow RC_ENV_WHITELIST variable for conf.d/foo (x,3.16 KB, patch)
2006-07-18 09:08 UTC, Roy Marples (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jakub Moc (RETIRED) gentoo-dev 2006-07-17 05:38:48 UTC
Currently, /etc/conf.d/env_whitelist is a file. Might be useful to make it a directory and let ebuilds install the needed entries there, that will be parsed by baselayout (similar to revdep-rebuild). There's at least one ebuild that could make use of that functionality currently (CCing Flameeyes here :P).
Comment 1 SpanKY gentoo-dev 2006-07-17 15:24:37 UTC
adding a new directory seems like a lot of overhead for very little gain

Roy: any way we can let init.d or conf.d files declare this ?  or is it too late by the time we source them ?  it'd be nice if init.d scripts could do like:
RC_WHITELIST="foo bar vars"
Comment 2 Roy Marples (RETIRED) gentoo-dev 2006-07-17 15:38:15 UTC
We can do that, but would have to parse the config file twice - once by /sbin/runscript and again by /sbin/runscript.sh

Infact I like this more as an extra directory would be a mess.
Comment 3 Roy Marples (RETIRED) gentoo-dev 2006-07-18 09:08:56 UTC
Created attachment 92135 [details, diff]
Allow RC_ENV_WHITELIST variable for conf.d/foo

Patch only applies to svn trunk rev 2165

This is just recorded for posterity - it's not being added to trunk as Az don't like it.

Also, we can add env vars to daemons like so
start-stop-daemon $args --env FOO=BAR

Although that's currently limited to 1 env var at this time, and that works in baselayout-1.12.1 so does this bug need to remain open?