You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Download the latest linux_amd64 zip file (e.g., pocketbase_0.8.0_linux_amd64.zip)
Extract and upload the binary to your droplet
Unzip the downloaded file on your local machine; it will produce two files: LICENSE and the executable “pocketbase”
Use rsync (or your preferred upload method) to transfer the binary to your droplet directory. For example:
• rsync -avz -e ssh /local/path/to/pocketbase root@YOUR_DROPLET_IP:/root/pb
The example above uploads the binary into the /root/pb directory on your droplet.
Create a systemd service to run PocketBase continually
Open or create a new service file:
• sudo vi /lib/systemd/system/pocketbase.service
Paste in the following content (replace yourdomain.com with your actual domain or subdomain):
Enable and start the service:
• sudo systemctl enable pocketbase.service --now
Assign a readable URL
Instead of using an IP address, point your domain/subdomain to the droplet’s IP by configuring DNS via Digital Ocean’s networking tools (see DigitalOcean docs for adding domains)
PocketBase’s built-in HTTPS handling (via Let’s Encrypt) will work when your actual domain name is used in the service config.
Backup your PocketBase data
PocketBase stores data in the pb_data directory (by default in /root/pb/pb_data/)
For regular backups, consider using a tool like rclone combined with a cron job to periodically sync your pb_data folder to backup storage (such as DO Spaces)
Alternatively, tools like Litestream (for SQLite backups) can be explored
Tips
Make sure to leave SSH (port 22) open when configuring UFW/firewall rules. For example: sudo ufw allow 22/tcp
Although some may suggest using nginx or Apache as a reverse proxy, PocketBase includes its own HTTP/HTTPS server with automated certificate provisioning; you don’t need an additional web server for basic setups.
Test your installation locally before deploying to production by running:
• ./pocketbase serve
This will start a local server on 127.0.0.1:8090 for exploration.
Next Steps
Monitor the logs in /root/pb/errors.log to catch any issues early
Experiment with PocketBase features locally and adjust your production configuration as needed
Enhance security (e.g., update system packages, restrict file permissions) for a production environment