mirror of
https://github.com/appleboy/drone-ssh.git
synced 2026-06-14 22:11:36 +08:00
Add sync mode. (#101)
* Add sync mode. Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com> * close channel in sync mode. Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com> * close channel in sync mode. Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
This commit is contained in:
@@ -66,6 +66,11 @@ func main() {
|
||||
EnvVar: "PLUGIN_PORT,SSH_PORT",
|
||||
Value: 22,
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "sync",
|
||||
Usage: "sync mode",
|
||||
EnvVar: "PLUGIN_SYNC",
|
||||
},
|
||||
cli.DurationFlag{
|
||||
Name: "timeout,t",
|
||||
Usage: "connection timeout",
|
||||
@@ -195,6 +200,7 @@ func run(c *cli.Context) error {
|
||||
Secrets: c.StringSlice("secrets"),
|
||||
Envs: c.StringSlice("envs"),
|
||||
Debug: c.Bool("debug"),
|
||||
Sync: c.Bool("sync"),
|
||||
Proxy: easyssh.DefaultConfig{
|
||||
Key: c.String("proxy.ssh-key"),
|
||||
KeyPath: c.String("proxy.key-path"),
|
||||
|
||||
Reference in New Issue
Block a user