2016-03-25 5 views
1

私は開始lagomアプリケーションを作成しましたhttp://www.lagomframework.com/documentation/1.0.x/GettingStarted.htmllogomアプリケーションでサービスゲートウェイのポートを変更するにはどうすればよいですか?

システムは正常に起動しています。

[info] Service locator is running at http://localhost:8000 
[info] Service gateway is running at http://localhost:9000 
[info] application - Signalled start to ConductR 
[info] application - Signalled start to ConductR 
[info] Service hellostream-impl listening for HTTP on 0:0:0:0:0:0:0:0:26230 
[info] Service helloworld-impl listening for HTTP on 0:0:0:0:0:0:0:0:24266 

0.0.0.0:8080でリッスンするサービスゲートウェイのホストとポートを変更するにはどうすればよいですか。

答えて

4
  1. ホスト名が正常であるようです。別のマシンからサービスにアクセスすることは可能です。 localhostはハードコードされています。

    def serviceGatewayAddress: URI = { 
        new URI(s"http://localhost:${gateway.address.getPort}") 
    } 
    

    メインbuild.sbtでプロパティlagomServiceGatewayPortを設定し、サービスゲートウェイのポートを設定するにはhttps://github.com/lagom/lagom/blob/1.0.0-M1/dev/service-locator/src/main/scala/com/lightbend/lagom/discovery/ServiceLocatorServer.scala#L71

  2. を参照してください。

    lagomServiceGatewayPort in ThisBuild := 8080 
    
関連する問題