diff --git a/web/ProxiesBlock.tsx b/web/ProxiesBlock.tsx index 690ee78..7677813 100644 --- a/web/ProxiesBlock.tsx +++ b/web/ProxiesBlock.tsx @@ -59,7 +59,15 @@ const NEW_HOST = { access_list_id: 0, certificate_id: 0, ssl_forced: false, - http2_support: false, + /* + HTTP/2. Only takes effect once a certificate is attached, which is why it is set here AND in + `attach` — a host created before it was secured would otherwise keep HTTP/1.1 forever, and + nothing in the panel would say so. + + On HTTP/1.1 a browser opens six connections and queues everything else behind them, which on this + site meant the gallery images waited on each other. Lighthouse put it at 900 ms. + */ + http2_support: true, hsts_enabled: false, hsts_subdomains: false, advanced_config: '', @@ -177,6 +185,9 @@ export const ProxiesBlock = ({ servers }: { servers: Server[] }) => { await clientRef.current.put(`/proxy-manager/npm/nginx/proxy-hosts/${host.id}`, { certificate_id: certificateId, ssl_forced: true, + // The moment HTTP/2 becomes possible at all, so this is where it is turned on for a host that + // predates the default above. + http2_support: true, }); };