Scala Play 2.2 application crashes after deploying in Heroku: target/start No such file or directory

前端 未结 3 769
难免孤独
难免孤独 2021-01-11 18:32

I\'ve been fighting with this for hours and I can\'t figure out why after deploying my Scala Play 2.2 application in Heroku I get this stacktrace:

2013-09-30         


        
3条回答
  •  说谎
    说谎 (楼主)
    2021-01-11 18:57

    I solved it as follows (possibly already answered but here are my steps)

    $ heroku local web
    

    Got the following output in the console

    forego | starting web.1 on port 5000
    web.1  | /bin/bash: target/bin/Service: Permission denied
    

    Then I did

    $chmod 777 target/bin/Service
    

    and problem resolved.

    Here, Service is the name of my application (as specified in pom.xml org.codehaus.mojo plugin) and here is what my Procfile file content looks like

    web: target/bin/Service -Dhttp.port=${PORT} ${JAVA_OPTS} -DapplyEvolutions.default=true -Ddb.default.driver=org.postgresql.Driver -Ddb.default.url=${DATABASE_URL}
    

提交回复
热议问题