Merge "move gate hooks to gate/"

This commit is contained in:
Jenkins
2017-01-10 20:08:48 +00:00
committed by Gerrit Code Review
3 changed files with 22 additions and 21 deletions

21
gate/post_test_hook.sh Executable file
View File

@@ -0,0 +1,21 @@
#!/bin/bash -x
MANAGE="/usr/local/bin/nova-manage"
function archive_deleted_rows {
# NOTE(danms): Run this a few times to make sure that we end
# up with nothing more to archive
for i in `seq 30`; do
$MANAGE db archive_deleted_rows --verbose --max_rows 1000
RET=$?
if [[ $RET -gt 1 ]]; then
echo Archiving failed with result $RET
return $RET
elif [[ $RET -eq 0 ]]; then
echo Archiving Complete
break;
fi
done
}
archive_deleted_rows

View File

@@ -1,21 +0,0 @@
#!/bin/bash -x
MANAGE="/usr/local/bin/nova-manage"
function archive_deleted_rows {
# NOTE(danms): Run this a few times to make sure that we end
# up with nothing more to archive
for i in `seq 30`; do
$MANAGE db archive_deleted_rows --verbose --max_rows 1000
RET=$?
if [[ $RET -gt 1 ]]; then
echo Archiving failed with result $RET
return $RET
elif [[ $RET -eq 0 ]]; then
echo Archiving Complete
break;
fi
done
}
archive_deleted_rows

View File

@@ -0,0 +1 @@
../../gate/post_test_hook.sh