- Timestamp:
- Jun 20, 2012, 12:21:48 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20120601/ippScripts/scripts/nightly_science.pl
r33863 r34047 32 32 exit($PS_EXIT_CONFIG_ERROR); 33 33 } 34 35 ## for DB connection, want to use siteConfig DB settings 36 my $ipprc = PS::IPP::Config->new(); # IPP Configuration 37 my $siteConfig = $ipprc->{_siteConfig}; 34 38 35 39 my $db; … … 2052 2056 2053 2057 sub init_gpc_db { 2058 ## change to use the siteConfig setting, while readonly probably do not want to use a readonly replicated DB incase it gets behind 2059 my $dbserver = metadataLookupStr($siteConfig, 'DBSERVER'); 2060 my $dbuser = metadataLookupStr($ipprc->{_siteConfig}, "RO_DBUSER"); 2061 my $dbpass = metadataLookupStr($ipprc->{_siteConfig}, "RO_DBPASSWORD"); 2062 die "database configuration not set up" unless defined($dbserver); 2063 die "database configuration not set up" unless defined($dbuser); 2064 die "database configuration not set up" unless defined($dbpass); 2065 #my $dbserver = 'ippdb01'; 2066 #my $dbuser = 'ippuser'; 2067 #my $dbpass = 'ippuser'; 2054 2068 use constant DB_SOCKET => '/var/run/mysqld/mysqld.sock'; 2055 my $dbserver = 'ippdb01';2056 my $dbuser = 'ippuser';2057 my $dbpass = 'ippuser';2058 2069 $db = DBI->connect("DBI:mysql:database=${dbname};host=${dbserver};" . 2059 2070 "mysql_socket=" . DB_SOCKET(),
Note:
See TracChangeset
for help on using the changeset viewer.
