From a4402eedb32d0933b11070a1f6f681d020ab270f Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 23 Jun 2009 11:22:54 -0700 Subject: use different name for connection and database --- scripts/setup.cfg.sample | 5 ++--- scripts/setup_status_network.sh | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'scripts') diff --git a/scripts/setup.cfg.sample b/scripts/setup.cfg.sample index ef33cd632..8d03b06f5 100644 --- a/scripts/setup.cfg.sample +++ b/scripts/setup.cfg.sample @@ -1,8 +1,7 @@ # CONFIGURATION FILE for setup_status_network.sh -# Base database name; full name will include nickname - -export DBHOST=masterdb.example.net +export DBHOST=localhost +export DBHOSTNAME=masterdb.example.net export DBBASE=_example_net export USERBASE=_example_net export ADMIN=root diff --git a/scripts/setup_status_network.sh b/scripts/setup_status_network.sh index 0261a7f55..17440640e 100755 --- a/scripts/setup_status_network.sh +++ b/scripts/setup_status_network.sh @@ -22,7 +22,7 @@ mysql -h $DBHOST -u $ADMIN --password=$ADMINPASS $SITEDB << ENDOFCOMMANDS GRANT INSERT,SELECT,UPDATE,DELETE ON $database.* TO '$username'@'localhost' IDENTIFIED BY '$password'; GRANT INSERT,SELECT,UPDATE,DELETE ON $database.* TO '$username'@'%' IDENTIFIED BY '$password'; INSERT INTO status_network (nickname, dbhost, dbuser, dbpass, dbname, sitename, created) -VALUES ('$nickname', '$DBHOST', '$username', '$password', '$database', '$sitename', now()); +VALUES ('$nickname', '$DBHOSTNAME', '$username', '$password', '$database', '$sitename', now()); ENDOFCOMMANDS -- cgit v1.2.3-54-g00ecf