You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by de...@apache.org on 2018/06/14 18:05:23 UTC

[trafficcontrol] 11/20: reset, seed, add admin user

This is an automated email from the ASF dual-hosted git repository.

dewrich pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git

commit 48fa05bbd12b4258745dd45e7af7a405b8e49230
Author: Dan Kirkwood <da...@gmail.com>
AuthorDate: Thu Jun 7 23:16:57 2018 +0000

    reset, seed, add admin user
---
 infrastructure/cdn-in-a-box/traffic_ops/run.sh | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/infrastructure/cdn-in-a-box/traffic_ops/run.sh b/infrastructure/cdn-in-a-box/traffic_ops/run.sh
index be60d71..d4b23e3 100755
--- a/infrastructure/cdn-in-a-box/traffic_ops/run.sh
+++ b/infrastructure/cdn-in-a-box/traffic_ops/run.sh
@@ -62,8 +62,11 @@ export PERL5LIB=$TO_DIR/lib:$TO_DIR/local/lib/perl5
 export PATH=/usr/local/go/bin:/opt/traffic_ops/go/bin:$PATH
 export GOPATH=/opt/traffic_ops/go
 
-cd $TO_DIR && ./db/admin.pl --env=production reset || echo "DB reset failed!"
-./db/adduser.pl $TO_ADMIN_USER $TO_ADMIN_PASSWORD | psql -U$DB_USER -h$DB_SERVER $DB_NAME || echo "adding traffic_ops admin user failed!"
+cd $TO_DIR && \
+	./db/admin.pl --env=production reset && \
+	./db/admin.pl --env=production seed || echo "db setup failed!"
+
+./db/adduser.pl $TO_ADMIN_USER $TO_ADMIN_PASSWORD admin | psql -U$DB_USER -h$DB_SERVER $DB_NAME || echo "adding traffic_ops admin user failed!"
 
 cd $TO_DIR && $TO_DIR/local/bin/hypnotoad script/cdn
 exec tail -f /var/log/traffic_ops/traffic_ops.log

-- 
To stop receiving notification emails like this one, please contact
dewrich@apache.org.