PocketBase is an open-source backend written in Go that bundles a real-time SQLite database, authentication, file uploads, and an admin dashboard into a single binary. This guide deploys PocketBase using Docker Compose with Traefik handling automatic HTTPS, admin credentials injected via environment variables, and a sample collection queried through the REST API. By the end, you'll have PocketBase serving a working backend securely at your domain.

Set Up the Directory Structure

1. Create the project folder and data directory:

$ mkdir -p ~/pocketbase/pb_data

$ cd ~/pocketbase