ssh-deploy/action.yml

63 lines
1.9 KiB
YAML
Raw Permalink Normal View History

name: "ssh deploy"
description: "NodeJS action for FAST deployment with rsync/ssh and remote script execution before/after rsync"
author: "easingthemes"
2019-10-02 21:52:52 +00:00
inputs:
SSH_PRIVATE_KEY:
description: "Private key part of an SSH key pair"
2019-10-02 21:52:52 +00:00
required: true
REMOTE_HOST:
description: "Remote host"
2019-10-02 21:52:52 +00:00
required: true
REMOTE_USER:
description: "Remote user"
2019-10-02 21:52:52 +00:00
required: true
REMOTE_PORT:
description: "Remote port"
2020-04-11 14:27:09 +00:00
required: false
default: "22"
2019-10-02 21:52:52 +00:00
SOURCE:
description: "Source directory, path relative to `$GITHUB_WORKSPACE` root, eg: `dist/`"
2020-04-11 14:27:09 +00:00
required: false
default: ""
2019-10-02 21:52:52 +00:00
TARGET:
description: "Target directory"
2020-04-11 14:27:09 +00:00
required: false
2023-02-21 14:36:29 +00:00
default: ""
ARGS:
description: "Arguments to pass to rsync"
required: false
default: "-rlgoDzvc -i"
SSH_CMD_ARGS:
description: "An array of ssh arguments, they must be prefixed with -o and separated by a comma, for example: -o SomeArgument=no, -o SomeOtherArgument=5 "
required: false
default: "-o StrictHostKeyChecking=no"
EXCLUDE:
description: "paths to exclude separated by `,`, ie: `/dist/, /node_modules/`"
required: false
default: ""
SCRIPT_BEFORE:
description: "Script to run on host machine before rsync"
required: false
default: ""
SCRIPT_BEFORE_REQUIRED:
description: "If not an empty string, the action will fail if the before script fails. Note: The string 'false' will be treated as true"
required: false
default: ""
SCRIPT_AFTER:
description: "Script to run on host machine after rsync"
2021-03-12 06:26:41 +00:00
required: false
default: ""
SCRIPT_AFTER_REQUIRED:
description: "If not an empty string, the action will fail if the after script fails. Note: The string 'false' will be treated as true"
required: false
default: ""
2019-10-02 21:52:52 +00:00
outputs:
status:
description: "Status"
2019-10-02 21:52:52 +00:00
runs:
using: "node20"
main: "dist/index.js"
2019-10-02 21:52:52 +00:00
branding:
color: "green"
icon: "truck"