diff options
author | ivan <ivan> | 1998-11-15 09:43:03 +0000 |
---|---|---|
committer | ivan <ivan> | 1998-11-15 09:43:03 +0000 |
commit | 60b5717194d18401d8532ca8b09376edeea535d7 (patch) | |
tree | 398eb265a60e5e98e1a4851584d215b8df961b95 /bin | |
parent | 1a354432763a3e699999b81402c42a12a347c10e (diff) |
update for new config file syntax, new adminsuidsetup
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/fs-setup | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/bin/fs-setup b/bin/fs-setup index 98e754261..4e64f1bdf 100755 --- a/bin/fs-setup +++ b/bin/fs-setup @@ -32,7 +32,10 @@ # fix radius attributes ivan@sisd.com 98-sep-27 # # $Log: fs-setup,v $ -# Revision 1.4 1998-10-22 15:51:23 ivan +# Revision 1.5 1998-11-15 09:43:03 ivan +# update for new config file syntax, new adminsuidsetup +# +# Revision 1.4 1998/10/22 15:51:23 ivan # also varchar with no length specified - postgresql fix broke mysql. # # Revision 1.3 1998/10/22 15:46:28 ivan @@ -49,8 +52,11 @@ use FS::UID qw(adminsuidsetup datasrc); use FS::Record; use FS::cust_main_county; +my $user = shift or die &usage; +FS::UID::getsecrets $user; + #needs to match FS::Record -my($dbdef_file) = "/var/spool/freeside/dbdef.". datasrc; +my($dbdef_file) = "/usr/local/etc/freeside/dbdef.". datasrc; ### @@ -151,13 +157,14 @@ foreach (qw(svc_acct svc_acct_sm svc_domain)) { #important $dbdef->save($dbdef_file); -FS::Record::reload_dbdef; +FS::Record::reload_dbdef($dbdef_file); ### # create 'em ### -my($dbh)=adminsuidsetup; +my($dbh)=adminsuidsetup $user; +warn $dbh; #create tables $|=1; @@ -198,6 +205,10 @@ SC SD TN TX TT UT VT VI VA WA WV WI WY AE AA AP $dbh->disconnect or die $dbh->errstr; +sub usage { + die "Usage:\n fs-setup user\n"; +} + ### # Now it becomes an object. much better. ### |