INSTALL GUIDE · GOOGLE CLOUD
Blue Folder Mail on Google Cloud
Run it on a Compute Engine VM with a persistent disk. (Cloud Run looks tempting but its stateless, scale-to-zero model fights the local SQLite index — see the caveat below.)
Compute Engine
- Create the VM An e2-small on Debian or Ubuntu is plenty. Add a persistent disk (or use the boot disk) for data.
- Firewall
Allow tcp:80,443 (and 22) via a firewall rule or the "Allow HTTP/HTTPS traffic" checkboxes. Keep 8080 internal.
- Install Docker, then the app
curl -fsSL https://get.docker.com | sh curl -fsSL https://raw.githubusercontent.com/gordonvividtone/bluefolder-mail/main/install.sh | bash
Set INBOUND_SECRET and RESEND_API_KEY. Data persists in the bfm-data volume on the disk.
This is the Docker guide on a GCE VM — see it for S3/GCS storage and Caddy TLS.
Why not Cloud Run?
Cloud Run containers are stateless and scale to zero — local disk is ephemeral and there's no mounted volume that survives. The SQLite metadata index needs somewhere durable, so Cloud Run is a poor fit unless you re-architect storage.
Storage & sending
- Storage — local disk by default; or STORAGE_BACKEND=s3 with Google Cloud Storage (S3-compatible endpoint) or any S3 bucket. Sealed ciphertext only.
- Sending — verify your domains at resend.com and set RESEND_API_KEY.
Receiving mail — the honest part
Recommended — webhook
Point a provider (Mailgun, SendGrid, Postal, Resend inbound) at https://your-host/_inbound with the secret as the x-inbound-secret header or ?secret=…, forwarding full raw MIME.
Built-in SMTP — not on GCP
HTTPS & the front door
Terminate TLS with Caddy on the VM (automatic Let's Encrypt), or front it with a Google HTTPS load balancer:
mail.example.com {
reverse_proxy localhost:8080
}
Add a login with BASIC_AUTH_USER / BASIC_AUTH_PASS, or keep the port on a private VPC / IAP.