mirror of
https://github.com/dokku/dokku.git
synced 2025-12-29 00:25:08 +01:00
handle config with spaces over ssh
This commit is contained in:
9
dokku
9
dokku
@@ -21,8 +21,13 @@ fi
|
||||
|
||||
if [[ -n "$SSH_ORIGINAL_COMMAND" ]]; then
|
||||
export -n SSH_ORIGINAL_COMMAND
|
||||
$0 $SSH_ORIGINAL_COMMAND
|
||||
exit $?
|
||||
if [[ $1 =~ config-* ]];then
|
||||
xargs $0 <<<$SSH_ORIGINAL_COMMAND
|
||||
exit $?
|
||||
else
|
||||
$0 $SSH_ORIGINAL_COMMAND
|
||||
exit $?
|
||||
fi
|
||||
fi
|
||||
|
||||
case "$1" in
|
||||
|
||||
@@ -11,14 +11,14 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "config:set" {
|
||||
run dokku config:set $TEST_APP test_var=true test_var2='hello world'
|
||||
run ssh dokku@dokku.me config:set $TEST_APP test_var=true test_var2=\"hello world\"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
assert_success
|
||||
}
|
||||
|
||||
@test "config:get" {
|
||||
run dokku config:set $TEST_APP test_var=true test_var2='hello world'
|
||||
run ssh dokku@dokku.me config:set $TEST_APP test_var=true test_var2=\"hello world\"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
run dokku config:get $TEST_APP test_var2
|
||||
@@ -28,7 +28,7 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "config:unset" {
|
||||
run dokku config:set $TEST_APP test_var=true test_var2='hello world'
|
||||
run ssh dokku@dokku.me config:set $TEST_APP test_var=true test_var2=\"hello world\"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
run dokku config:get $TEST_APP test_var
|
||||
|
||||
Reference in New Issue
Block a user