Support X-Forwarded-Proto header in ResponseUtils.baseURL

Description

https://github.com/geoserver/geoserver/blob/master/src/ows/src/main/java/org/geoserver/ows/util/ResponseUtils.java#L427
ResponseUtils.baseURL use req.getScheme() but if tomcat run http and run inside SSL proxy server, req.getScheme() return "http".
This problem raise mix-contents error in Layer Preview in Style Editor.
This problem will resolve to check "X-Forwarded-Proto" header.

example:

nginx config example:

Environment

Ubuntu 16.04 + nginx + tomcat8

Assignee

Unassigned

Reporter

Taro Matsuzawa

Triage

Fix versions

Affects versions

Priority

Medium
Configure