Grafana Loki - Bad Gateway when using https

Hi, we already have loki installed, however it’s running on http.

we tried to edit the loki config to listen to https but we got this error line 4: field https_listen_port not found in type server.Config

And on the explore of grafana/loki ui we set the server to https://localhost:3100 however it’s returning bad gateway error message.

http: server gave HTTP response to HTTPS client

is it possible to run loki to a https? Thanks!

Hi @sanlupam03, thanks for the question.

is it possible to run loki to a https? Thanks!

Unfortunately it is not. You’ll need to setup a proxy in front of Loki.
This blog post describes how to enable such a proxy using nginx.

1 Like