summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvarac <varacanero@zeromail.org>2014-09-09 09:58:13 +0000
committervarac <varacanero@zeromail.org>2014-09-09 09:58:13 +0000
commitf52bf9d41f4d50ff8e70b80a7e51db52628e8a5f (patch)
treed04fb4e73809887174ee8108b1176b10e90d1e0a
parente4119e73bc71c690dcb20b9adcf3182bab4cd7e9 (diff)
fix IP parsing and leap_cli option parsing
-rwxr-xr-xleap-platform-test24
1 files changed, 12 insertions, 12 deletions
diff --git a/leap-platform-test b/leap-platform-test
index 96f6d78..6d8ce55 100755
--- a/leap-platform-test
+++ b/leap-platform-test
@@ -56,12 +56,12 @@ add_nodes() {
bootstrap_nodes() {
for vm in "$@"
do
- $LEAP_CMD "$OPTS" local start "$vm"
+ $LEAP_CMD $OPTS local start "$vm"
wait_for_node "$vm"
- $LEAP_CMD "$OPTS" node init "$vm"
+ $LEAP_CMD $OPTS node init "$vm"
# set hostname + do dist-upgrade
- $LEAP_CMD "$OPTS" deploy "$vm" --tags site_apt::dist_upgrade,site_config::hosts,site_squid_deb_proxy::client
- $LEAP_CMD "$OPTS" local save "$vm"
+ $LEAP_CMD $OPTS deploy "$vm" --tags site_apt::dist_upgrade,site_config::hosts,site_squid_deb_proxy::client
+ $LEAP_CMD $OPTS local save "$vm"
done
}
@@ -75,7 +75,7 @@ create_provider() {
mkdir -p "$PROVIDERDIR"
cd "$PROVIDERDIR"
- $LEAP_CMD "$OPTS" new --contacts "$CONTACTS" --domain "$DOMAIN" --name "$PROVIDER" --platform="$PLATFORMDIR" .
+ $LEAP_CMD $OPTS new --contacts "$CONTACTS" --domain "$DOMAIN" --name "$PROVIDER" --platform="$PLATFORMDIR" .
cd "$PLATFORMDIR"
git checkout "$PLATFORM_BRANCH"
git submodule sync
@@ -83,12 +83,12 @@ create_provider() {
cd "$PROVIDERDIR"
# for now, we use the vagrant pubkey until https://leap.se/code/issues/2039 is solved
- $LEAP_CMD "$OPTS" add-user --self --ssh-pub-key="$SSHKEY"
- $LEAP_CMD "$OPTS" cert ca && leap cert csr
+ $LEAP_CMD $OPTS add-user --self --ssh-pub-key="$SSHKEY"
+ $LEAP_CMD $OPTS cert ca && leap cert csr
# copy for faster testing
#cp $ROOTDIR/dh.pem.test $PROVIDERDIR/files/ca/dh.pem
- $LEAP_CMD "$OPTS" cert dh
+ $LEAP_CMD $OPTS cert dh
add_nodes "$NODES"
}
@@ -118,7 +118,7 @@ deploy() {
ERRLOG2="$LOGDIR/deploy-error.log"
echo "Deploying \"$vm\" on $( date )"|tee -a "$LOG1" "$LOG2"
- $LEAP_CMD "$OPTS" -v 2 deploy "$vm" 2>&1 | tee -a "$LOG1" "$LOG2" | egrep -v "$FILTER_ALL" | tee -a "$ERRLOG1" "$ERRLOG2" > /dev/null
+ $LEAP_CMD $OPTS -v 2 deploy "$vm" 2>&1 | tee -a "$LOG1" "$LOG2" | egrep -v "$FILTER_ALL" | tee -a "$ERRLOG1" "$ERRLOG2" > /dev/null
if [ -s "$ERRLOG1" ]
then
@@ -149,7 +149,7 @@ deploy() {
}
get_ip () {
- grep ip_address "$PROVIDERDIR/nodes/$1.json" |cut -f 2 -d:|sed 's/[",]//g'
+ grep ip_address "$PROVIDERDIR/nodes/$1.json" |cut -f 2 -d:|sed 's/[ ",]//g'
}
ip_pingable () {
@@ -177,7 +177,7 @@ reset_deploy() {
for i in $nodes
do
- $LEAP_CMD "$OPTS" local reset "$i"
+ $LEAP_CMD $OPTS local reset "$i"
wait_for_node "$i"
deploy "$i" &
done
@@ -231,7 +231,7 @@ run_tests () {
echo -e "\nRunning leap test on $date" | tee -a "$TEST_LOG1" "$TEST_LOG2"
- $LEAP_CMD "$OPTS" test 2>&1 | egrep -v "$TEST_FILTER" | tee -a "$TEST_LOG1" "$TEST_LOG2"
+ $LEAP_CMD $OPTS test 2>&1 | egrep -v "$TEST_FILTER" | tee -a "$TEST_LOG1" "$TEST_LOG2"
test_failure=${PIPESTATUS[0]}
if [ "$test_failure" -ne 0 ]