-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun_debug.sh
executable file
·22 lines (21 loc) · 924 Bytes
/
run_debug.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh
set -e
instance="instance-postgres"
#atlas-clean
find target -name "proman-*" -exec rm -rf {} \; || true
rm -rf target/classes
# -Datlassian.webresource.disable.minification=true
atlas-debug --version 6.4.12 --product jira -DskipTests=true -Dmaven.test.skip=true --instanceId $instance $* 2>&1|tee atlas-debug.log
atlas-create-home-zip
d=`date "+%Y%m%d-%H%M%S"`_$instance
b=backup/$d
mkdir -p $b
mv atlas-debug.log $b
mv target/$instance/generated-test-resources.zip $b
cat >$b/dump_postgresql.sh <<__EOF__
#!/bin/sh
/Applications/pgAdmin3.app/Contents/SharedSupport/pg_dump --host macmini-rb --port 5432 --username "jira-amps" --role "jira-amps" --no-password --format custom --blobs --encoding UTF8 --inserts --column-inserts --verbose --file "dump_postgresql.bin.sql" "jira-amps" 2>&1|tee dump_postgresql.log
__EOF__
(cd $b && sh dump_postgresql.sh)
rm -f backup/last_$instance
ln -s $d backup/last_$instance