You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by da...@apache.org on 2016/11/14 17:07:25 UTC
[22/53] [abbrv] incubator-trafficcontrol git commit: renamed the
users to match the databases
renamed the users to match the databases
Project: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/commit/e363f58c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/tree/e363f58c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/diff/e363f58c
Branch: refs/heads/psql-rebase
Commit: e363f58c9622c4fb31355188719eadf5e4962b7a
Parents: 8eb5ecf
Author: Dewayne Richardson <de...@gmail.com>
Authored: Tue Oct 4 10:51:18 2016 -0600
Committer: Dan Kirkwood <da...@gmail.com>
Committed: Fri Nov 11 13:53:57 2016 -0700
----------------------------------------------------------------------
traffic_ops/app/conf/development/database.conf | 2 +-
traffic_ops/app/conf/integration/database.conf | 2 +-
traffic_ops/app/conf/production/database.conf | 2 +-
traffic_ops/app/conf/test/database.conf | 2 +-
traffic_ops/app/db/admin.pl | 40 ++++++++++-----------
traffic_ops/app/db/dbconf.yml | 13 +++----
6 files changed, 31 insertions(+), 30 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/conf/development/database.conf
----------------------------------------------------------------------
diff --git a/traffic_ops/app/conf/development/database.conf b/traffic_ops/app/conf/development/database.conf
index b79c7e8..523c779 100644
--- a/traffic_ops/app/conf/development/database.conf
+++ b/traffic_ops/app/conf/development/database.conf
@@ -3,7 +3,7 @@
"description": "Local PostgreSQL database on port 5432",
"dbname": "to_development",
"hostname": "localhost",
- "user": "to_user",
+ "user": "to_development",
"password": "twelve",
"port": "5432",
"type": "Pg"
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/conf/integration/database.conf
----------------------------------------------------------------------
diff --git a/traffic_ops/app/conf/integration/database.conf b/traffic_ops/app/conf/integration/database.conf
index 061d6da..caccc44 100644
--- a/traffic_ops/app/conf/integration/database.conf
+++ b/traffic_ops/app/conf/integration/database.conf
@@ -2,7 +2,7 @@
"description": "Local PostgreSQL database on port 5432",
"dbname": "to_integration",
"hostname": "localhost",
- "user": "to_user",
+ "user": "to_integration",
"password": "twelve",
"port": "5432",
"type": "Pg"
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/conf/production/database.conf
----------------------------------------------------------------------
diff --git a/traffic_ops/app/conf/production/database.conf b/traffic_ops/app/conf/production/database.conf
index 23d6d8c..19a81c1 100644
--- a/traffic_ops/app/conf/production/database.conf
+++ b/traffic_ops/app/conf/production/database.conf
@@ -1,7 +1,7 @@
{
"description": "Local PostgreSQL database on port 5432",
- "dbname": "traffic_ops_db",
+ "dbname": "traffic_ops",
"hostname": "localhost",
"user": "traffic_ops",
"password": "password",
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/conf/test/database.conf
----------------------------------------------------------------------
diff --git a/traffic_ops/app/conf/test/database.conf b/traffic_ops/app/conf/test/database.conf
index c0a9f1d..5d4cd64 100644
--- a/traffic_ops/app/conf/test/database.conf
+++ b/traffic_ops/app/conf/test/database.conf
@@ -2,7 +2,7 @@
"description": "Local PostgreSQL database on port 5432",
"dbname": "to_test",
"hostname": "localhost",
- "user": "to_user",
+ "user": "to_test",
"password": "twelve",
"port": "5432",
"type": "Pg"
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/db/admin.pl
----------------------------------------------------------------------
diff --git a/traffic_ops/app/db/admin.pl b/traffic_ops/app/db/admin.pl
index 4e1b3bc..324044e 100755
--- a/traffic_ops/app/db/admin.pl
+++ b/traffic_ops/app/db/admin.pl
@@ -55,7 +55,7 @@ my $db_protocol;
# This is defaulted to 'to_development' so
# you don't have to specify --env=development for dev workstations
my $db_name = 'to_development';
-my $db_username = 'to_user';
+my $db_username = 'to_development';
my $db_password = '';
my $host_ip = '';
my $host_port = '';
@@ -134,9 +134,9 @@ else {
exit(0);
sub parse_dbconf_yml_pg_driver {
- my $db_conf = LoadFile('db/dbconf.yml');
+ my $db_conf = LoadFile('db/dbconf.yml');
my $db_connection = $db_conf->{$environment};
- $db_protocol = $db_connection->{driver};
+ $db_protocol = $db_connection->{driver};
my $open = $db_connection->{open};
# Goose requires the 'open' line in the dbconf file to be a scalar.
@@ -147,11 +147,11 @@ sub parse_dbconf_yml_pg_driver {
$open = join "\n", map { s/=/ : /; $_ } split " ", $open;
my $hash = Load $open;
- $host_ip = $hash->{host};
- $host_port = $hash->{port};
- $db_name = $hash->{dbname};
- $db_username = $hash->{user};
- $db_password = $hash->{password};
+ $host_ip = $hash->{host};
+ $host_port = $hash->{port};
+ $db_name = $hash->{dbname};
+ $db_username = $hash->{user};
+ $db_password = $hash->{password};
}
sub migrate {
@@ -193,16 +193,16 @@ sub showusers {
sub reverse_schema {
- my $db_info = Schema->get_dbinfo();
- my $user = $db_info->{user};
- my $pass = $db_info->{password};
- my $dsn = Schema->get_dsn();
- make_schema_at(
- 'Schema', {
- debug => 1,
- dump_directory => './lib',
- overwrite_modifications => 1,
- },
- [ $dsn, $user, $pass ],
- );
+ my $db_info = Schema->get_dbinfo();
+ my $user = $db_info->{user};
+ my $pass = $db_info->{password};
+ my $dsn = Schema->get_dsn();
+ make_schema_at(
+ 'Schema', {
+ debug => 1,
+ dump_directory => './lib',
+ overwrite_modifications => 1,
+ },
+ [ $dsn, $user, $pass ],
+ );
}
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/e363f58c/traffic_ops/app/db/dbconf.yml
----------------------------------------------------------------------
diff --git a/traffic_ops/app/db/dbconf.yml b/traffic_ops/app/db/dbconf.yml
index fb45262..ed624e7 100755
--- a/traffic_ops/app/db/dbconf.yml
+++ b/traffic_ops/app/db/dbconf.yml
@@ -19,16 +19,17 @@ name: dbconf.yml
development:
driver: postgres
- open: host=127.0.0.1 port=5432 user=to_user password=twelve dbname=to_development sslmode=disable
+ open: host=127.0.0.1 port=5432 user=to_development password=twelve dbname=to_development sslmode=disable
test:
driver: postgres
- open: host=127.0.0.1 port=5432 user=to_user password=twelve dbname=to_test sslmode=disable
+ open: host=127.0.0.1 port=5432 user=to_test password=twelve dbname=to_test sslmode=disable
-production:
+integration:
driver: postgres
- open: host=127.0.0.1 port=5432 user=to_user password=twelve dbname=traffic_ops_db sslmode=disable
+ open: host=127.0.0.1 port=5432 user=to_integration password=twelve dbname=to_integration sslmode=disable
-integration:
+production:
driver: postgres
- open: host=127.0.0.1 port=5432 user=to_user password=twelve dbname=to_integration sslmode=disable
+ open: host=127.0.0.1 port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+