X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2Fbin%2Ffreeside-selfservice-server;h=9df313fecb89235eda658300437db2bff34f7337;hb=fadbf7963db877d3c37028805cbb656ba1d634ec;hp=2087e71306298f75f8070e138f21a00faf21693a;hpb=c648976f0b7975f2328ebd7ba8c711fad0ca4195;p=freeside.git diff --git a/FS/bin/freeside-selfservice-server b/FS/bin/freeside-selfservice-server index 2087e7130..9df313fec 100644 --- a/FS/bin/freeside-selfservice-server +++ b/FS/bin/freeside-selfservice-server @@ -13,11 +13,13 @@ use Storable 2.09 qw(nstore_fd fd_retrieve); use Net::SSH qw(sshopen2); use FS::Daemon qw(daemonize1 drop_root logfile daemonize2 sigint sigterm); use FS::UID qw(adminsuidsetup forksuidsetup); -use FS::ClientAPI; +use FS::ClientAPI qw( load_clientapi_modules ); use FS::ClientAPI_SessionCache; +use FS::Record qw( qsearch qsearchs ); use FS::Conf; use FS::cust_svc; +use FS::agent; $FREESIDE_LOG = "%%%FREESIDE_LOG%%%"; $FREESIDE_LOCK = "%%%FREESIDE_LOCK%%%"; @@ -50,6 +52,8 @@ drop_root(); $ENV{HOME} = (getpwuid($>))[7]; #for ssh +load_clientapi_modules; + adminsuidsetup $user; #logfile("/usr/local/etc/freeside/selfservice.". $FS::UID::datasrc); #MACHINE @@ -70,6 +74,13 @@ my $cache = new FS::ClientAPI_SessionCache( { } ); $cache->remove('signup_info_cache'); +#and also clear the selfservice skin info cache, for the same reason +my $ss_cache = new FS::ClientAPI_SessionCache( { + 'namespace' => 'FS::ClientAPI::MyAccount', +} ); +$ss_cache->remove($_) + foreach grep /^skin_info_cache_agent/, $ss_cache->get_keys(); + my $clientd = "/usr/local/sbin/freeside-selfservice-clientd"; #better name? my $warnkids=0;