This is a pure Bash Drone >= 0.5 plugin to sync files to remote hosts.
To build the Docker image from source:
docker build -t andreipoe/drone-rsync .
This is intended to be used a Drone plugin, but you can run the image from the working directory:
docker run --rm \
-e PLUGIN_KEY=$(cat some-private-key) \
-e PLUGIN_HOSTS="127.0.0.1, 127.0.0.2, 127.0.0.3" \
-e PLUGIN_PORTS="22, 23, 24" \
-e PLUGIN_TARGET="./" \
-e PLUGIN_PRESCRIPT="echo \"Prescript Done!\"" \
-e PLUGIN_SCRIPT="echo \"Postscript Done!\"" \
-e PLUGIN_ARGS="--blocking-io" \
-v $(pwd):$(pwd) \
-w $(pwd) \
andreipoe/drone-rsync