To deploy a PostgresDB instance on Porter, head to the Community Add-ons tab. Specify a username and password you'd like for the instance. You can optionally configure the amount of resources (i.e. CPU and RAM) assigned to the database instance.
PostgresDB instances deployed on Porter have persistent volumes attached to them to prevent data loss in the case of accidents. See Persistent Volumes for a guide on how to manage these volumes in your cloud provider.
PostgresDB on Porter is by default only exposed to internal traffic - only applications and add-on's that are deployed in the same Kubernetes cluster can connect to the database. The DNS name for the instance can be found on the deployment view as shown below. Note that Postgres listens on port 5432 by default.
Note that the connection URI for the PostgresDB instance follows this format:
For the example above, the connection string would be:
To delete this add-on, navigate to the Settings tab of the deployment. Note that deleting from the Porter dashboard will not delete the persistent volumes that have been attached to your PostgresDB instance. To delete these dangling volumes, see the next section.
By default, Porter creates EBS volumes of type gp2 (general purpose SSD) volumes that are attached to the database. To view the volumes attached to your cluster, navigate to EC2 > Volumes tab in your AWS console.
The unnamed 100GB volumes are attached to your EKS cluster itself. Make sure to not delete them - this will make your cluster not functional.
Click on the volume and navigate to the Tags tab to see which deployment the volume belongs to. You can modify, delete, and make a snapshot of this volume from the AWS console.
Updated 7 months ago