Following my previous post A Play Framework server setup I'm going to write on how to automate the whole Play build-deploy cycle.
In a nutcase, we have two servers (ci and play hosts), jenkins, an ANT script and a Bash script which will handle the servers restart in the host machines
Here's much of the ANT script in all its glory:
So, what we basically want here is to setup Jenkins to call a single ANT tasks, in this case "jenkins-play-build" and set some properties as shown here:
The script used to finish the deploy process will restart the Play apps and update the symlink pointing to the latest version we deployed
For this to work, you'll need to configure SSH password-less authentication between you CI server and the target servers.