When I was reverse-proxying my connections through Apache, I defined my backend-url as follows:
backend-url:
- "wss://127.0.0.1"
This resulted in the following getting created.
Jan 30 16:39:59 backend-centos-7.vagrantup.com sensu-agent[28926]: {"component":"agent","level":"info","msg":"connecting to backend URL \"wss://127.0.0.1:8081/\"","time":"2020-01-30T16:39:59Z"}
This works as I am defining the port number as part of my config file.
backend-url:
- "wss://127.0.0.1:443"
It should be a documented at minimum.
As an organization, we proxy all connections through Apache/nginx so that we have a parsable access.log to perform log event parsing against. We terminated SSL at Apache, and use mod_rewrite to send websocket traffic to the right place, and do the same with /api/ and / traffic as well.
It is perceivable that in the amount of use-cases and security policies that agents will not always directly connect to the backend.
Thanks for filing this! We'll discuss whether this is a software or doc bug.
We discussed that issue and decided it should be documented because changing the current behavior could provoke breaking changes for users that rely on this functionality.
Most helpful comment
We discussed that issue and decided it should be documented because changing the current behavior could provoke breaking changes for users that rely on this functionality.