# ssh-scp-deploy
**Repository Path**: dawningw/ssh-scp-deploy
## Basic Information
- **Project Name**: ssh-scp-deploy
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: main
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2023-10-19
- **Last Updated**: 2023-10-19
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# ssh-scp-deploy
## β Why should I use this action?
Because this action provide an easy and highly customizable way to upload files via scp and execute a set of command via ssh before or/and after.
I use this action to deploy my personal projects to remote server, restarting the needed services or to do a simple upload via scp.
## π Supported runners
[](https://docs.github.com/en/actions/creating-actions/about-actions#docker-container-actions)
## π€ Author
**Marco Dalla Santa**
* Twitter: [@marcodallasanta](https://twitter.com/marcodallasanta)
* Github: [@marcodallasanta](https://github.com/marcodallasanta)
* LinkedIn: [@marcodallasanta](https://linkedin.com/in/marcodallasanta)
## βοΈ Usage
```yaml
- uses: mdallasanta/ssh-scp-deploy@{version}
with:
local: './' # Local file path - REQUIRED false - DEFAULT ./
remote: '~/' # Remote file path - REQUIRED false - DEFAULT ~/
host: ${{secrets.HOST}} # Remote server address - REQUIRED true
port: ${{secrets.PORT}} # Remote server port - REQUIRED false - DEFAULT 22
user: ${{secrets.USER}} # Remote server user - REQUIRED true
password: ${{secrets.PASSWORD}} # User password - REQUIRED at least one of "password" or "key"
key: ${{secrets.KEY}} # Remote server private key - REQUIRED at least one of "password" or "key"
pre_upload: echo "This will be executed before the upload!" # Command to run via ssh before scp upload - REQUIRED false
post_upload: echo "This will be executed after the upload!" # Command to run via ssh after scp upload - REQUIRED false
ssh_options: -o StrictHostKeyChecking=no # A set of ssh_option separated by -o - REQUIRED false - DEFAULT -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null
scp_options: -v # Flags to use during scp - REQUIRED false - DEFAULT ''
```
## π€ Contributing
Contributions, issues and feature requests are welcome!
Feel free to check [issues page](https://github.com/mdallasanta/ssh-scp-deploy/issues).
## π Thanks
Thanks to:
- [RaphaΓ«l Bussa](https://github.com/raphaelbussa) for help in testing.
- [jamesremuscat](https://github.com/jamesremuscat) for resolving [issue#15](https://github.com/marcodallasanta/ssh-scp-deploy/issues/15)
- [Blake Drumm](https://github.com/x-limitless-x) for resolving [issue#19](https://github.com/marcodallasanta/ssh-scp-deploy/issues/19)
## π License
Copyright Β© 2020-2022 [Marco Dalla Santa](https://github.com/marcodallasanta)
The source code, scripts and documentation in this project are released under the [MIT License](LICENSE)