move default env settings to Netdisco.pm

This commit is contained in:
Oliver Gorwits
2014-04-24 21:05:42 +01:00
parent b4b5cce00a
commit 349bddf609
3 changed files with 6 additions and 12 deletions

View File

@@ -28,12 +28,6 @@ use Role::Tiny::With;
use MCE::Signal '-setpgrp';
use MCE;
# set defaults for AnyEvent::DNS
local $ENV{'PERL_ANYEVENT_MAX_OUTSTANDING_DNS'}
= setting('dns')->{max_outstanding} || 10;
local $ENV{'PERL_ANYEVENT_HOSTS'}
= setting('dns')->{hosts_file} || '/etc/hosts';
# set temporary MCE files' location in home directory
my $home = ($ENV{NETDISCO_HOME} || $ENV{HOME});
my $tmp_dir = ($ENV{NETDISCO_TEMP} || dir($home, 'tmp'));