Compare commits

...

4 Commits

Author SHA1 Message Date
Dragan Filipovic
a3d2df0501 [version] Add author 2019-10-03 01:17:24 +02:00
Dragan Filipovic
7d63f7f134 [version] Description update 2019-10-03 01:07:28 +02:00
Dragan Filipovic
5fdc019220 [version] version bump 2019-10-03 00:52:55 +02:00
Dragan Filipovic
177ffc3a2a [version] Readme update 2019-10-03 00:51:32 +02:00
3 changed files with 19 additions and 4 deletions

View File

@@ -1,5 +1,9 @@
# ssh deployments
Deploy code with rsync over ssh, using NodeJS.
NodeJS version is more than a minute `faster` than simple Docker version.
This GitHub Action deploys specific directory from `GITHUB_WORKSPACE` to a folder on a server via rsync over ssh, using NodeJS.
This action would usually follow a build/test action which leaves deployable code in `GITHUB_WORKSPACE`, eg `dist`;
@@ -9,27 +13,37 @@ This action would usually follow a build/test action which leaves deployable cod
Pass configuration with `env` vars
1. `SSH_PRIVATE_KEY` [required]
This should be the private key part of an ssh key pair. The public key part should be added to the authorized_keys file on the server that receives the deployment.
2. `REMOTE_HOST` [required]
eg: mydomain.com
3. `REMOTE_USER` [required]
2. `ARGS` (optional)
eg: myusername
2. `ARGS` (optional, default '-rltgoDzvO')
For any initial/required rsync flags, eg: `-avzr --delete`
3. `SOURCE` (optional, default '')
The source directory, path relative to `$GITHUB_WORKSPACE` root, eg: `dist/`
4. `TARGET` (optional, default '/home/REMOTE_USER/')
The target directory
# Usage
```
- name: Deploy to Staging server
uses: easingthemes/ssh-deploy@v2.0.2
env:
SSH_PRIVATE_KEY: ${{ secrets.SERVER_SSH_KEY }}
ARGS: "-rltgoDzvO --delete"
ARGS: "-rltgoDzvO"
SOURCE: "dist/"
REMOTE_HOST: ${{ secrets.REMOTE_HOST }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}

View File

@@ -1,5 +1,6 @@
name: 'ssh deploy'
description: 'For deploying code over ssh'
description: 'NodeJS action for FAST deployment with rsync/ssh'
author: 'easingthemes'
inputs:
SSH_PRIVATE_KEY: # Private Key
description: 'Private Key'

View File

@@ -1,6 +1,6 @@
{
"name": "ssh-deploy",
"version": "2.0.3",
"version": "2.0.7",
"description": "This GitHub Action deploys specific directory from `GITHUB_WORKSPACE` to a folder on a server via rsync over ssh.",
"main": "src/index.js",
"dependencies": {