mirror of
https://github.com/cross-the-world/scp-pipeline.git
synced 2025-09-10 19:48:17 +08:00
use local var
This commit is contained in:
4
entrypoint.sh
Normal file → Executable file
4
entrypoint.sh
Normal file → Executable file
@@ -23,7 +23,7 @@ createKeyFile() {
|
|||||||
check_remote_dir() {
|
check_remote_dir() {
|
||||||
local USEPASS=$1
|
local USEPASS=$1
|
||||||
local REMOTE=$2
|
local REMOTE=$2
|
||||||
CMD="ssh"
|
local CMD="ssh"
|
||||||
if $USEPASS; then
|
if $USEPASS; then
|
||||||
CMD="sshpass -p $INPUT_PASS ssh"
|
CMD="sshpass -p $INPUT_PASS ssh"
|
||||||
fi
|
fi
|
||||||
@@ -41,7 +41,7 @@ executeSCP() {
|
|||||||
local LINES=$2
|
local LINES=$2
|
||||||
local COMMAND=
|
local COMMAND=
|
||||||
|
|
||||||
CMD="scp"
|
local CMD="scp"
|
||||||
if $USEPASS; then
|
if $USEPASS; then
|
||||||
CMD="sshpass -p $INPUT_PASS scp"
|
CMD="sshpass -p $INPUT_PASS scp"
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user