Redirect plain HTTP to HTTPS on direct TLS

Aperta
#440 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
go
Ambito
backend

Direzione di ricerca

Read internal/server/http.go and the TLS guide at site/src/content/docs/docs/guides/tls.mdx; first trace how direct TLS and FANOUT_PUBLIC_URL are configured. The issue is explicitly deferred until users request it, so confirm that demand exists before starting. Done means an opt-in port 80 listener redirects only to the configured HTTPS origin, startup rejects the setting without TLS, and the configuration reference and guide are updated.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

[!NOTE]
Deferred. Reverse proxies and CDNs already do this redirect, and a built-in one needs a second listener, which departs from the one-port design. Pick this up if people running direct TLS ask for it.

What

With direct TLS, the single listener serves only HTTPS, so someone who types a bare hostname into a browser gets a connection failure. An optional listener on port 80 could answer with a redirect to the HTTPS origin.

Acceptance criteria

  • Off by default; the one-port deployment is unchanged unless the setting is present
  • The listener serves only redirects, with no API, UI, MCP, or OTLP on it
  • The redirect target comes from configuration (FANOUT_PUBLIC_URL), never from the request Host header
  • Startup fails with an error naming the setting when TLS is not enabled
  • Configuration reference and TLS guide updated

References

  • internal/server/http.go
  • site/src/content/docs/docs/guides/tls.mdx

One pull request. Use the latest stable version of any dependency added, verified against its registry and pinned exactly.

Lingua principale
Go
Stelle
11
Fork
0
Merge medio
7h 5m
PR unite (30g)
112

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di labstack/fanout

Tutte le issue di labstack/fanout

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.