aboutsummaryrefslogtreecommitdiffstats
path: root/qtip/scripts
diff options
context:
space:
mode:
authorwu.zhihui <wu.zhihui1@zte.com.cn>2017-03-13 17:16:50 +0800
committerwu.zhihui <wu.zhihui1@zte.com.cn>2017-03-13 18:14:50 +0800
commit57ec2e7a9757cbb1da8a1f73f0c55e8a5cb67bec (patch)
tree71675cd658f79bedbd64f7b91d8ae2382a5156af /qtip/scripts
parenta5145885c7a43622f803534ed97890ef9acb852d (diff)
add the cleanup step in runner.py
Add the cleanup step in runner.py Change-Id: I0016986485eab5d7ab45d4a7a393bea5fb6f96b5 Signed-off-by: wu.zhihui <wu.zhihui1@zte.com.cn>
Diffstat (limited to 'qtip/scripts')
-rwxr-xr-xqtip/scripts/cleanup_creds.sh11
1 files changed, 10 insertions, 1 deletions
diff --git a/qtip/scripts/cleanup_creds.sh b/qtip/scripts/cleanup_creds.sh
index b4eee924..1a7ddc1a 100755
--- a/qtip/scripts/cleanup_creds.sh
+++ b/qtip/scripts/cleanup_creds.sh
@@ -1,11 +1,20 @@
#! /bin/bash
+##############################################################################
+# Copyright (c) 2017 ZTE corp. and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
DEST_IP=$1
+PRIVATE_KEY=$2
HOSTNAME=$(hostname)
sshoptions="-o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
case "$INSTALLER_TYPE" in
fuel)
- ssh $sshoptions -i ./config/QtipKey root@$DEST_IP "sed -i '/root@$HOSTNAME/d' /root/.ssh/authorized_keys"
+ ssh $sshoptions -i $PRIVATE_KEY root@$DEST_IP "sed -i '/root@$HOSTNAME/d' /root/.ssh/authorized_keys"
;;
esac