Skip to content

TLS and HTTP/2

Serve Arcane over HTTPS through a reverse proxy or your own TLS certificates.

For most installations, let a reverse proxy handle HTTPS (Option A). Otherwise Arcane can serve HTTPS itself with your certificate (Option B).

Option A: HTTPS handled by a reverse proxy

Section titled “Option A: HTTPS handled by a reverse proxy”
  1. Set up your proxy (Nginx, Caddy, Traefik, or another) to forward WebSockets. See Reverse Proxy Setup.

  2. Set these on Arcane:

    Terminal window
    ARCANE_TLS_ENABLED=false
    ARCANE_APP_URL=https://your-domain.com
  3. Optional: set ARCANE_PORT (default 3552).

You need a domain name, a valid certificate and private key, and access to Arcane’s .env or container settings.

  1. Set these in your .env file or container environment:

    Terminal window
    ARCANE_TLS_ENABLED=true
    ARCANE_TLS_CERT_FILE=/full/path/to/your/certificate.pem
    ARCANE_TLS_KEY_FILE=/full/path/to/your/private-key.pem
    ARCANE_APP_URL=https://your-domain.com

    Arcane won’t start with ARCANE_TLS_ENABLED=true unless both the cert and key files are set.

  2. Optional: set ARCANE_PORT (default 3552) and ARCANE_LISTEN (empty binds all interfaces).

  3. Restart Arcane.

  4. Open your https:// URL and check the browser reports a valid certificate.

With ARCANE_TLS_ENABLED=false, Arcane accepts HTTP/1.1 and h2c (HTTP/2 without encryption) on one port. Proxies use h2c to forward gRPC, such as the agent tunnel. Keep h2c internal and use HTTPS for public access.

Turn on HTTP Strict Transport Security under System → Authentication, or set ARCANE_HSTS_ENABLED=true. It’s off by default and applies to the manager only.

When on, Arcane sends Strict-Transport-Security: max-age=31536000 on HTTPS responses, so browsers use HTTPS for that hostname for one year. A request counts as HTTPS when Arcane serves TLS itself, or when it comes from a trusted proxy with X-Forwarded-Proto: https.