2019-05-15 06:47:53 +08:00
|
|
|
workflow "Remote ssh commands" {
|
2019-05-15 06:32:43 +08:00
|
|
|
on = "push"
|
|
|
|
resolves = [
|
|
|
|
"Executing remote ssh commands",
|
2019-05-15 06:47:53 +08:00
|
|
|
"Support Private Key",
|
2019-05-15 06:32:43 +08:00
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
action "Executing remote ssh commands" {
|
|
|
|
uses = "appleboy/ssh-action@master"
|
|
|
|
secrets = [
|
|
|
|
"HOST",
|
|
|
|
"PASSWORD",
|
|
|
|
]
|
|
|
|
args = [
|
2019-05-15 06:36:27 +08:00
|
|
|
"--user", "actions",
|
2019-05-15 06:32:43 +08:00
|
|
|
"--script", "whoami",
|
|
|
|
]
|
|
|
|
}
|
2019-05-15 06:47:53 +08:00
|
|
|
|
|
|
|
action "Support Private Key" {
|
|
|
|
uses = "appleboy/ssh-action@master"
|
|
|
|
secrets = [
|
|
|
|
"HOST",
|
|
|
|
"KEY",
|
|
|
|
]
|
|
|
|
args = [
|
|
|
|
"--user", "actions",
|
|
|
|
"--script", "ls -al",
|
|
|
|
]
|
|
|
|
}
|