2012-04-04 19 views
1

私はサーバーをセットアップするのが好きです。私は一晩中さまざまなSQLの問題に苦しんでいます。私と私との間に唯一のものは、正常に実行されているプレイアプリケーションです。エラーHerokuにPlay 2.0アプリをデプロイする

Starting process with command `target/start -Dhttp.port=80 ` 
2012-04-04T05:58:52+00:00 app[web.1]: Play server process ID is 1 
2012-04-04T05:58:53+00:00 app[web.1]: [info] play - database [default] connected at jdbc:mysql://us-cdbr-east.cleardb.com/heroku_cd914b667dae168 
2012-04-04T05:58:56+00:00 app[web.1]: [info] play - Application started (Prod) 
2012-04-04T05:58:56+00:00 app[web.1]: Oops, cannot start the server. 
2012-04-04T05:58:56+00:00 app[web.1]: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:80 
... more errors 

誰に問題がありますか? Javaオプション引数が必要ですか?

私はProcfileにユーザポートを指定してみました、と別のエラーメッセージました:私は何が起こっているか見当がつかない

2012-04-04T07:01:36+00:00 heroku[web.1]: Starting process with command `target/start -Dhttp.port=2000` 
2012-04-04T07:01:37+00:00 app[web.1]: Play server process ID is 1 
2012-04-04T07:01:40+00:00 app[web.1]: [info] play - database [default] connected at jdbc:mysql://us-cdbr-east.cleardb.com/heroku_cd914b667dae168 
2012-04-04T07:01:45+00:00 app[web.1]: [info] play - Application started (Prod) 
2012-04-04T07:01:45+00:00 app[web.1]: [info] play - Listening for HTTP on port 2000... 
2012-04-04T07:01:46+00:00 heroku[web.1]: Error R11 (Bad bind) -> Process bound to port 2000, should be 47248 (see environment variable PORT) 
2012-04-04T07:01:46+00:00 heroku[web.1]: Stopping process with SIGKILL 
2012-04-04T07:01:47+00:00 heroku[web.1]: Process exited with status 137 
2012-04-04T07:01:47+00:00 heroku[web.1]: State changed from starting to crashed 

を。この環境変数を変更するにはどうすればよいですか?このherokuのプロセスモデルは私にとって非常に混乱しています。

答えて

5

私は、Herokuがポートを指定することを許可していないという問題があると思います。あなたのエラーをグーグルで私は見つける:https://devcenter.heroku.com/articles/error-codes#r11__bad_bind

ので、代わりにこれをやって:

ウェブ:ターゲット/ -Dhttp.port = 80

この

ウェブを行うために、開始を: target/start -Dhttp.port = $ PORT

Jamesは、より高度なPlay 2.0アプリをデプロイするにあたり、hereを配備して素晴らしい記事を書いています。

+0

ありがとうございます!!!!!!!!! – wbarksdale

関連する問題