2017-11-23 13 views
0

프로덕션 모드에서 서버를 시작하지 못하고 다음 로그를 인쇄합니다. 웹 페이지에 액세스 할 수 없습니다. 그러나 코드는 개발 모드에서 정상적으로 실행됩니다. 문제를 해결하는 방법?요청이 없습니다. 스칼라에서 '호스트'헤더 오류가 발생했습니다. 2.6.7 Akka

2017-11-23T10:04:07+08 [INFO] from play.core.server.AkkaHttpServer [main] 
     Listening for HTTP on /0:0:0:0:0:0:0:0:9000 
2017-11-23T10:04:08+08 [WARN] from akka.actor.ActorSystemImpl [application-akka.actor.default-dispatcher-4] 
     Illegal request, responding with status '400 Bad Request': Request is 
     missing required `Host` header: Cannot establish effective URI of request 
     to `/`, request has a relative URI and is missing a `Host` header; 
     consider setting `akka.http.server.default-host-header` 

2017-11-23T10:04:08+08 [WARN] from akka.actor.ActorSystemImpl [application-akka.actor.default-dispatcher-3] 
     Illegal request, responding with status '400 Bad Request': Request is 
     missing required `Host` header: Cannot establish effective URI of request 
     to `/`, request has a relative URI and is missing a `Host` header; 
     consider setting `akka.http.server.default-host-header` 

답변

1

haproxy 서버 상태 확인은 서버

haproxy httpchk이로 수정해야

option httpchk GET/HTTP/1.1\r\nHost:localhost 
에 호스트 헤더를 보내지 않았다