Skip to content
copy

GitHub Action

Use Proxy to SSH and Rsync

v2.1 Latest version

Use Proxy to SSH and Rsync

copy

Use Proxy to SSH and Rsync

Github -> proxy -> server

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Use Proxy to SSH and Rsync

uses: pranksteess/[email protected]

Learn more about this action in pranksteess/ssh-rsync-action

Choose a version

SSH Rsync Action

Action on GH marketplace   GitHub release   GitHub

Description

Copy files from github workstation to a proxy, then copy them from proxy to your online server

Usage

- name: Copy bin
  uses: pranksteess/[email protected]
          
  with:
    key: ${{ secrets.RSYNC_KEY }}
    rsync_flags: ' -avzr --delete --progress '
    dst_host: 1.1.1.1
    dst_user: root
    proxy_host: 2.2.2.2
    proxy_user: root
    src_file: xxx.bin
    proxy_file_path: /tmp/proxy_file_save/
    dst_file_path: /usr/local/service/xxx/bin/
    ssh_after: |
      cd /usr/local/service/xxx/bin/
      md5sum xxx.new
      mv xxx xxx.old
      mv xxx.new xxx
      supervisorctl restart xxx

more details see action.yml