kestra
kestra copied to clipboard
`io.kestra.plugin.fs.ssh.Command` has so many issues..
Describe the issue
issue 1:
Each supported languages have a pair of Script
& Commands
tasks.
io.kestra.plugin.scripts.python.Commands
io.kestra.plugin.scripts.python.Script
io.kestra.plugin.scripts.r.Commands
io.kestra.plugin.scripts.r.Script
io.kestra.plugin.scripts.julia.Commands
io.kestra.plugin.scripts.julia.Script
io.kestra.plugin.scripts.ruby.Commands
io.kestra.plugin.scripts.ruby.Script
io.kestra.plugin.scripts.node.Commands
io.kestra.plugin.scripts.node.Script
io.kestra.plugin.scripts.shell.Commands
io.kestra.plugin.scripts.shell.Script
io.kestra.plugin.scripts.powershell.Commands
io.kestra.plugin.scripts.powershell.Script
where is the io.kestra.plugin.fs.ssh.Script
?
issue 2:
if allowFailure: true
is not set in step1
tasks:
- id: step1
type: "io.kestra.plugin.fs.ssh.Command"
host: 10.0.0.1
port: "22"
authMethod: PUBLIC_KEY
username: user
privateKey: "{{ secret('SSH_RSA_PRIVATE_KEY') }}"
commands: ['exit 1']
- id: step2
type: io.kestra.plugin.core.log.Log
message: "{{ outputs['command'] }}"
step2 won't be executed because of the exception
SSH command fails with exit status 1
java.lang.Exception: SSH command fails with exit status 1
if allowFailure: true
is set in step1
tasks:
- id: step1
type: "io.kestra.plugin.fs.ssh.Command"
host: 10.0.0.1
port: "22"
authMethod: PUBLIC_KEY
username: user
privateKey: "{{ secret('SSH_RSA_PRIVATE_KEY') }}"
allowFailure: true
commands: ['exit 1']
- id: step2
type: io.kestra.plugin.core.log.Log
message: "{{ outputs['command'] }}"
step2 will return empty json {}
issue 3:
tasks:
- id: command
type: "io.kestra.plugin.fs.ssh.Command"
host: 10.0.0.1
port: "22"
authMethod: PUBLIC_KEY
username: user
privateKey: "{{ secret('SSH_RSA_PRIVATE_KEY') }}"
commands: ['echo foobar']
- id: use-output
type: io.kestra.plugin.core.log.Log
message: The previous task output is {{ outputs['command'] }}
Even with zero exit code, one of the output, vars
is not working
According to the document
io.kestra.plugin.fs.ssh.Command
has two outputs, exitCode
& vars
I hope kestra solve these CRITICAL issue as soon as possible because basically it affects and interrupts all actions on remote host.
Environment
- Kestra Version: 0.17.0
- Operating System (OS/Docker/Kubernetes): Docker
- Java Version (if you don't run kestra in Docker):