From 87aec8c9cd3355dfa20c059f5d9518cb6f34a19a Mon Sep 17 00:00:00 2001 From: Javi Fontan Date: Thu, 25 Jun 2015 16:21:44 -0400 Subject: [PATCH] feature #3782: make tm qcow2 snap commands use ssh --- src/tm_mad/qcow2/snap_create | 29 +++++++++++++++++++---------- src/tm_mad/qcow2/snap_delete | 8 +++++--- src/tm_mad/qcow2/snap_revert | 10 +++++++--- 3 files changed, 31 insertions(+), 16 deletions(-) diff --git a/src/tm_mad/qcow2/snap_create b/src/tm_mad/qcow2/snap_create index bbe734b6ee..b5f0f595e9 100755 --- a/src/tm_mad/qcow2/snap_create +++ b/src/tm_mad/qcow2/snap_create @@ -1,4 +1,4 @@ -#!/bin/bash -x +#!/bin/bash # -------------------------------------------------------------------------- # # Copyright 2002-2015, OpenNebula Project (OpenNebula.org), C12G Labs # @@ -35,7 +35,8 @@ DRIVER_PATH=$(dirname $0) . $TMCOMMON -SRC_PATH=`arg_path $SRC` +SRC_PATH=$(arg_path $SRC) +SRC_HOST=$(arg_host $SRC) #------------------------------------------------------------------------------- # Get Image information @@ -72,15 +73,18 @@ SNAP_PATH="${SNAP_DIR}/${SNAP_ID}" SNAP_PATH_RELATIVE=$(basename ${SNAP_PATH}) CURRENT_PATH=${DISK_PATH} -if [ ! -d ${SNAP_PATH} ]; then - mkdir ${SNAP_DIR} +CMD=$(cat <