My Play 2.0 application runs under different directories during development and in production:
During dev we use /, in production it runs as /crm/.
Is it possible to define a “root directory” of some sort for play?
This article suggests using the isDev() sort of methods and this one to use a config variable, but it seems like the routes file no longer allows code inclusion: adding %{ }—style tags to the routes file results in compilation errors.
As there seems to be no other solution, I decided to go with a shell script that modifies the routes file on deployment and adds the necessary prefix to every route.