File tree Expand file tree Collapse file tree 3 files changed +38
-14
lines changed
Expand file tree Collapse file tree 3 files changed +38
-14
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
2-
3- function die() {
4- if [ ! -z " $1 " ]; then
5- echo $1 > /dev/stderr
6- fi
7- exit 1
8- }
9-
10- SERVICES=" ca
11- sa
12- policy"
13- DBENVS=" development
14- test
15- integration"
2+ cd $( dirname $0 ) /..
3+ source test/db-common.sh
164
175for svc in $SERVICES ; do
186 for dbenv in $DBENVS ; do
Original file line number Diff line number Diff line change 1+ # Common variables used by Goose-related scripts.
2+ set -o errexit
3+ set -o xtrace
4+
5+ function die() {
6+ if [ ! -z " $1 " ]; then
7+ echo $1 > /dev/stderr
8+ fi
9+ exit 1
10+ }
11+
12+ SERVICES=" ca
13+ sa
14+ policy"
15+ DBENVS=" development
16+ test
17+ integration"
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ #
3+ # Run this script after pulling changes that have migrations, to migrate your
4+ # local DB.
5+ #
6+ cd $( dirname $0 ) /..
7+
8+ source test/db-common.sh
9+
10+ for svc in $SERVICES ; do
11+ for dbenv in $DBENVS ; do
12+ db=" boulder_${svc} _${dbenv} "
13+
14+ goose -path=./$svc /_db/ -env=$dbenv up || die " unable to migrate ${db} "
15+ echo " migrated ${db} database"
16+ done
17+ done
18+ echo " migrated all databases"
19+
You can’t perform that action at this time.
0 commit comments