Play! Framework + App Engine Tutorial

Published on July 9, 2011

This is a tutorial: creating a barebone Play! app and deploying on the free Google App Engine.


Steps to setting up Play! with App Engine

  1. Download Play framework (latest is 1.2.1)

  2. Unzip and add path

export PATH=$PATH:/YOURPATH/play-1.2.1

  1. Install GAE module (latest is 1.4)

play install gae

  1. Install siena module (latest is 1.5)

play install siena

  1. Edit /YOURAPP/conf/dependencies.yml

require:
    – play
    – play -> gae 1.4
    – play -> siena 1.5

  1. Add to conf/application.conf

# —- Google app engine module —-
module.gae=${play.path}/modules/gae-1.4
# —- Siena module —-
module.siena=${play.path}/modules/siena-1.5

  1. Restart your app. GAE will start and a /war will be created

  2. Edit /war/WEB-INF/appengine-web.xml and enter your appengine appid

  3. Deploy

play war MyFirstApp -o MyFirstApp-War
/Applications/eclipse/plugins/appengine-java-sdk-1.5.0/bin/appcfg.sh update MyFirstApp-War/

Go to http://yourapp.appspot.com, and it should run!

Note: This tutorial is only a basic to getting a barebone Play! app to run on Google’s App Engine. Developing a Play! app on App Engine still require your effort. Here is an Easy Bookmark example.