Interactive, safety-focused installer for building and running Proton Mail Bridge without a GUI on a systemd-based Linux server.
The project targets Debian/Ubuntu and Fedora/RHEL-family systems on x86_64. It builds Proton Mail Bridge from Proton's official source repository with the upstream build-nogui target.
Warning
This is an independent community project. Proton designs Bridge for local connections. Direct LAN exposure is unsupported and disabled by default.
./install.shperforms a read-only inspection by default.- Installation requires
sudo ./install.sh --applyand an exactINSTALLconfirmation. - Localhost and private-tunnel modes preserve the upstream
127.0.0.1binding. - Direct LAN mode requires
EXPOSE-LAN, a private bind address, an allowlisted private CIDR, and active firewalld. - Proton credentials and 2FA codes are entered only in Proton Bridge's own CLI.
- The service uses a locked system account, a dedicated GPG key, a
passstore, and systemd hardening. - Unknown distributions, unsupported architectures, unexpected upstream source layouts, and failed service checks are rejected.
- A paid Proton Mail plan that includes Bridge.
- x86_64 Linux with systemd.
- Internet access during dependency installation and compilation.
- Disk space for the source build and local encrypted mailbox cache.
./install.shsudo ./install.sh --applyThe installer asks for a network mode and release tag, installs build dependencies, verifies or installs the required Go toolchain from go.dev, creates a dedicated service account and keychain, builds Bridge, opens the CLI for login, and optionally enables the service.
- Localhost — recommended; upstream binding is unchanged.
- Private tunnel — recommended; Bridge still binds to localhost. Use SSH, WireGuard, or Tailscale.
- Direct LAN — unsupported; patches the selected source tag to one private IPv4 address and adds source-restricted firewalld rules.
Example SSH tunnel from a client:
ssh -N \
-L 1143:127.0.0.1:1143 \
-L 1025:127.0.0.1:1025 \
user@bridge-serverNever expose Bridge's IMAP or SMTP ports to the public internet.
sudo ./bridge-cli.shInside the CLI:
login
info
exit
The info command displays Bridge-generated IMAP and SMTP credentials. They are not the Proton account password.
sudo systemctl status proton-bridge
sudo journalctl -u proton-bridge -f./update.sh
sudo ./update.sh --applyPreserve account data and cache:
sudo ./uninstall.shPermanently delete the service account, vault, GPG key, credentials, and cache:
sudo ./uninstall.sh --purgePurge mode requires two confirmations.
/etc/systemd/system/proton-bridge.service
/etc/headless-proton-bridge-installer.conf
/opt/proton-bridge/releases/<version>/bridge
/usr/local/bin/proton-bridge
/usr/local/src/proton-bridge
/var/lib/proton-bridge
https://github.com/ProtonMail/proton-bridgehttps://proton.me/support/bridge-for-linuxhttps://ndo.dev/blog/headless_protonbridge/
GNU GPL v3.0 or later.