Managed vs self-managed PostgreSQL on Digital Ocean

TL;DR Managed PostgreSQL is more expensive if we consider resources being assigned (CPU+RAM+DISK), but Digital Ocean provides features that makes availability and maintainability much easier compared to self-managed. For testing and development environment, and proof of concepts, and if costs is very important, it can makes sense to choose the self-managed approach. Overall comparison Managed PostgreSQL General 1 GB RAM 1vCPU 10 GB Disk PostgreSQL 15 15€/mo PROS: Automatic updates Daily point-in-time backups High availability with automated failover (extra cost) Read-only nodes (extra cost) End-to-end security Cluster metrics and alerting CONS: Impossible to SSH into instance Some restrictions (available extensions, PostgreSQL versions, etc) Self-managed PostgreSQL General 1 GB RAM 1 vCPU 25GB Disk PostgreSQL 16 (or any version, it’s up to you) $7/mo PROS: Full control CONS: Managing a database instances requires knowledge, experience and time....

October 7, 2023 · 3 min · 502 words · Horacio G. de Oro

Install PostgreSQL 16 on Digital Ocean droplet

Create the droplet for the DB I haven’t used Terraform with DigitalOcean yet. To iterate more quickly I just created the droplet using the web UI. Since it’s my first time with Digital Ocean, I considered that better make some quick progress to be able to evaluate the platform, and leave automation for a second iteration. I already have my ssh public key in Digital Ocean, so bringing the droplet up was quick and easy....

October 6, 2023 · 6 min · 1092 words · Horacio G. de Oro