Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Reporting/Documentation] Fix Reporting+Reverse Proxy documentation #26670

Closed
tsullivan opened this issue Dec 4, 2018 · 11 comments · Fixed by #51113
Closed

[Reporting/Documentation] Fix Reporting+Reverse Proxy documentation #26670

tsullivan opened this issue Dec 4, 2018 · 11 comments · Fixed by #51113
Assignees
Labels
(Deprecated) Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead Team:Docs v7.6.0

Comments

@tsullivan
Copy link
Member

Documentation for the xpack.reporting.kibanaServer.* settings has a sentence:

However, if you use a reverse-proxy to access Kibana, you must set the proxy port, protocol, and hostname.

That recommends that users to use the xpack.reporting.kibanaServer.* when doing so may cause more problems than solutions.

The sentence should say something like:

If you use a reverse-proxy to access Kibana, you can set the proxy port, protocol, and hostname to have Reporting use the proxy. In most cases, that is only required if the proxy is responsible for modifying requests to make them work with Kibana; for example a reverse proxy can remove a base from requests so Kibana will properly serve the requests.

@tsullivan
Copy link
Member Author

@kobelb can you check my facts and comment about this?

@cjcenizal
Copy link
Contributor

Would it make sense to elaborate on what you mean by "have Reporting use the proxy"? For example, "have Reporting use the proxy to... (do something)".

@tsullivan
Copy link
Member Author

tsullivan commented Dec 7, 2018

Would it make sense to elaborate on what you mean by "have Reporting use the proxy"? For example, "have Reporting use the proxy to... (do something)".

The xpack.reporting.kibanaServer.* settings exist to configure a proxy URL: hostname, protocol and port.

When you change the settings, it tells the Reporting headless browser to open a URL other than the default localhost URL that Kibana server listens on. The reason you would want to do this is to make the headless browser talk to a proxy, which an administrator has configured as a gateway for talking to the actual Kibana server.

You would want to do that when the Kibana server requires a gateway between it and outside connections. The best example of that being the case is if the proxy has rewrite rules to make Kibana appear to have a base path. For example, if users to access Kibana at https://my-host/my-kibana/app/kibana then you'd need a proxy to take off my-kibana from the path before the Kibana server can understand how to handle requests.

"have Reporting use the proxy to... (do something)".

have Reporting use the proxy to load Kibana URLs

@cjcenizal
Copy link
Contributor

Thanks @tsullivan! That clears things up for me. Reporting works by loading up Kibana in a headless browser and essentially taking screenshots. It loads up Kibana the same way that users do, so if users access Kibana through a reverse proxy, Reporting will need to do that as well.

have Reporting use the proxy to load Kibana URLs

Sounds good to me.

@kobelb
Copy link
Contributor

kobelb commented Dec 7, 2018

I think the new wording is fine. There are likely other situations outside of a "base path" that require the traffic be routed through the reverse proxy as opposed to hitting Kibana directly (custom auth at the reverse proxy comes to mind) but we can expand this recommendation if need be.

@tsullivan
Copy link
Member Author

if users access Kibana through a reverse proxy, Reporting will need to do that as well.

Not necessarily. I filed this issue mainly to take the word must out of the documentation for these settings. Instead of saying:

if you use a reverse-proxy to access Kibana, you must set the proxy port, protocol, and hostname

we should say

if you have a reverse-proxy to access Kibana, you can set the proxy port, protocol, and hostname

meaning: if it helps you, you can do it. You will only have to do it if Kibana doesn't work without it.

There are likely other situations outside of a "base path" that require the traffic be routed through the reverse proxy as opposed to hitting Kibana directly (custom auth at the reverse proxy comes to mind) but we can expand this recommendation if need be.

Another situation: if the proxy is responsible for logging all the Kibana requests. In that case, have Reporting use the proxy so the logs will include the requests made by the headless browser.

@tsullivan
Copy link
Member Author

The basic point here is, Kibana server must be able to make a connection to itself for Reporting to work. That goes for:

  • With a reverse proxy, if connections must go through the proxy first, then Kibana server must be able to make a connection to the proxy
  • With encryption, if Kibana server communications are encrypted with a PKI where a client needs a certificate distributed from a key server, then the Kibana server must be able to make a connection to the key server.

The 2nd point came up recently in a customer case, but I am really not familiar with the terminology here to add documentation for this.

@tsullivan
Copy link
Member Author

cc @lucabelluccini would you feel ok taking ownership of this?

@tsullivan tsullivan removed their assignment Mar 15, 2019
@lucabelluccini
Copy link
Contributor

👍 I'll try to submit a PR associated to this issue.

@KOTungseth
Copy link
Contributor

@lucabelluccini did you still want to address this one?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
(Deprecated) Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead Team:Docs v7.6.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants