Merge "fix ssh tunnel creation"
authorRyota MIBU <r-mibu@cq.jp.nec.com>
Thu, 18 Aug 2016 13:21:05 +0000 (13:21 +0000)
committerGerrit Code Review <gerrit@172.30.200.206>
Thu, 18 Aug 2016 13:21:05 +0000 (13:21 +0000)
1  2 
tests/run.sh

diff --combined tests/run.sh
@@@ -139,13 -139,12 +139,13 @@@ register_image() 
  }
  
  create_test_user() {
 -    openstack user list | grep -q " $DOCTOR_USER " || {
 -        openstack user create "$DOCTOR_USER" --password "$DOCTOR_PW"
 -    }
      openstack project list | grep -q " $DOCTOR_PROJECT " || {
          openstack project create "$DOCTOR_PROJECT"
      }
 +    openstack user list | grep -q " $DOCTOR_USER " || {
 +        openstack user create "$DOCTOR_USER" --password "$DOCTOR_PW" \
 +                              --project "$DOCTOR_PROJECT"
 +    }
      openstack user role list "$DOCTOR_USER" --project "$DOCTOR_PROJECT" \
      | grep -q " $DOCTOR_ROLE " || {
          openstack role add "$DOCTOR_ROLE" --user "$DOCTOR_USER" \
@@@ -211,7 -210,7 +211,7 @@@ start_consumer() 
      # NOTE(r-mibu): create tunnel to the installer node, so that we can
      # avoid some network problems dpends on infra and installers.
      # This tunnel will be terminated by stop_consumer() or after 10 mins passed.
-     TUNNEL_COMMAND="sudo ssh $ssh_opts $INSTALLER_IP -R $CONSUMER_PORT:localhost:$CONSUMER_PORT 'sleep 600'"
+     TUNNEL_COMMAND="sudo ssh $ssh_opts $INSTALLER_IP -R $CONSUMER_PORT:localhost:$CONSUMER_PORT sleep 600"
      $TUNNEL_COMMAND > ssh_tunnel.log 2>&1 < /dev/null &
  }