Showing posts with label GlobalSettings. Show all posts
Showing posts with label GlobalSettings. Show all posts

Tuesday, May 19, 2015

Separate Configuration for Play Framework / Play2 production, testing and development environment

Working on Play Framework configuration is easy. In this article, I'll walk you through simple implementation where you are able to create a generic application.conf and a dedicated application.conf for each environment.


Objective: To be able to easily manage your Play2 application configuration separately for production, testing and development.

Solution: Override GlobalSettings onLoadConfig to point to a commong configuration and a fallback configuration specific for your current environment. Your code should look like below.