-
Notifications
You must be signed in to change notification settings - Fork 0
/
start
executable file
·33 lines (25 loc) · 1.09 KB
/
start
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash -xe
demossm() {
aws --profile uneet-demo ssm get-parameters --names $1 --with-decryption --query Parameters[0].Value --output text
}
mongo --version
mysql --version
aws configure set profile.uneet-demo.aws_access_key_id $AWS_ACCESS_KEY_ID &&
aws configure set profile.uneet-demo.aws_secret_access_key $AWS_SECRET_ACCESS_KEY &&
aws configure set profile.uneet-demo.region ap-southeast-1 &&
aws configure --profile uneet-demo list
export AWS_PROFILE=uneet-demo
echo "select login_name from profiles;" | ./connect.sh -d
./stop-services.sh
# Relies on MEFE's migration scripts on startup to prime the dropped collection
./reset-mongo.sh
# Alter URL at DEMO_BASELINE_SQL to update seed/prime script
curl -o demo-baseline.sql -O $(demossm DEMO_BASELINE_SQL)
md5sum demo-baseline.sql
./restore.sh -d demo-baseline.sql
# secret for MEFE BUGZILLA_ADMIN_KEY to have Administrator access
demossm BUGZILLA_ADMIN_KEY_SQL > demo-BUGZILLA_ADMIN_KEY.sql
md5sum demo-BUGZILLA_ADMIN_KEY.sql
./restore.sh -d demo-BUGZILLA_ADMIN_KEY.sql
./start-services.sh
echo "select login_name from profiles;" | ./connect.sh -d