Ruby Script for deploying from Git via FTP
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


chmod the deploy script to make it executable and place it wherever you'd like.  I put mine in /usr/bin. 

You'll want to create any tags manually for whatever server groups you set up.  So if the code from "master" is already on both staging and production, run "git tag staging master" and "git tag production master".  This will get those setup for the script to create diffs from later.

Create a file named "deploy.yml" in the root of your project w/ the following sytax.

  servers: [
  { host:, directory: /var/sites/staging/sitefolder }

  servers: [
  { host:, directory: /var/sites/sitefolder },
  { host:, directory: /var/sites/staging/sitefolder }

The deploy script uses FTP credentials so if you can FTP to the servers, you can use the script.

As shown above, you may add multiple servers to a group.

Example usage:
deploy production master user pass

This uses a diff from the current "production" tag and "master", FTPs the files up, and recreates the "production" tag.