Play framework 2 development configuration

前端 未结 2 1079
抹茶落季
抹茶落季 2021-02-15 22:37

How I can setup different configuration for development and production mode in Play 2 application?

I\'ve try to use JVM arguments on application start in development mod

2条回答
  •  广开言路
    2021-02-15 23:28

    That should work:

    play -Dconfig.resource=dev.conf "run"
    

    Anyway I had some problems with -Dconfig.resource so I'm using -Dconfig.file instead

    play -Dconfig.file=/full/path/to/your/project_folder/conf/alt_conf.conf "run"
    

提交回复
热议问题