fix: remove port, add sni

when setting the port, alloy sends host:port as Host header and confuses
nginx
This commit is contained in:
2026-06-12 17:48:13 -03:00
parent a2f1636ed4
commit bf8af312eb
+2 -1
View File
@@ -35,11 +35,12 @@ prometheus.scrape "forgejo" {
job_name = "forgejo"
scheme = "https"
targets = [{ __address__ = "{{ env "FORGEJO_METRICS_HOSTNAME" }}:443" }]
targets = [{ __address__ = "{{ env "FORGEJO_METRICS_HOSTNAME" }}" }]
forward_to = [prometheus.remote_write.prometheus.receiver]
tls_config {
insecure_skip_verify = {{ env "FORGEJO_INSECURE_SKIP_VERIFY" }}
server_name = "{{ env "FORGEJO_METRICS_HOSTNAME" }}"
}
}
{{ end }}