Skip to content

Postgresql guide#24068

Open
igor-alexandrov wants to merge 31 commits intodocker:mainfrom
igor-alexandrov:postgresql-guide
Open

Postgresql guide#24068
igor-alexandrov wants to merge 31 commits intodocker:mainfrom
igor-alexandrov:postgresql-guide

Conversation

@igor-alexandrov
Copy link
Contributor

@igor-alexandrov igor-alexandrov commented Feb 3, 2026

Description

  • Add comprehensive PostgreSQL containerization guide with 4 modules covering setup, configuration, networking, and ecosystem tools
  • Include practical Docker and Docker Compose examples for each topic
  • Cover data persistence strategies (named volumes, bind mounts), initialization scripts, performance tuning, and connection pooling

This PR introduces a new PostgreSQL-specific guide to help users containerize PostgreSQL databases using Docker. The guide is structured into four progressive modules:

  1. Immediate Setup & Data Persistence - Covers running PostgreSQL containers with proper data persistence using named volumes, bind mounts, and Docker Compose configurations.

  2. Advanced Configuration and Initialization - Explains initialization scripts (/docker-entrypoint-initdb.d/), performance tuning parameters (memory settings, connection limits, I/O
    configuration), and timezone/locale settings.

  3. Networking and Connectivity - Details how to configure networking for containerized PostgreSQL deployments.

  4. Companions for PostgreSQL - Introduces ecosystem tools including pgAdmin 4 for visual management, PgBouncer and Pgpool-II for connection pooling, and pgbench for performance testing.

Examples include tabs showing both Docker Hardened Images (DHI) and Docker Official Images (DOI) variants where applicable.

The guide is prepared by @igor-alexandrov, @edithturn, and @Expeto.

Reviews

  • Technical review
  • Editorial review
  • Product review

@netlify
Copy link

netlify bot commented Feb 3, 2026

Deploy Preview for docsdocker ready!

Name Link
🔨 Latest commit d89eae6
🔍 Latest deploy log https://app.netlify.com/projects/docsdocker/deploys/69a60208b60d1c00080d6c95
😎 Deploy Preview https://deploy-preview-24068--docsdocker.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@igor-alexandrov igor-alexandrov marked this pull request as draft February 3, 2026 22:50
@igor-alexandrov igor-alexandrov marked this pull request as ready for review February 13, 2026 19:59
Copy link
Contributor

@tippexs tippexs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a small remark. Other then that, Great Work LGTM

```yaml
services:
postgres:
image: postgres:17.7
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why we do use 17.7 instead of 18 as in the rest of the guide?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We fixed! Thank you @tippexs

Copy link
Contributor

@craig-osterhout craig-osterhout left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @igor-alexandrov and all.
It looks great!
I left mostly style nits, not any technical blockers.

edithturn and others added 3 commits March 2, 2026 11:20
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
edithturn and others added 10 commits March 2, 2026 11:21
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: Craig Osterhout <craig.osterhout@docker.com>
Co-authored-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
…ation.md

Co-authored-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
…ation.md

Co-authored-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
@igor-alexandrov
Copy link
Contributor Author

@craig-osterhout @dvdksn we resolved all your comments. Thank you for finding a time to review this.

@dvdksn
Copy link
Contributor

dvdksn commented Mar 3, 2026

/review

Copy link
Contributor

@docker-agent docker-agent bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review Summary

This comprehensive PostgreSQL containerization guide is well-structured and provides clear, practical examples for users. The content accurately explains Docker concepts, PostgreSQL configuration, and networking patterns.

The guide successfully covers:

  • Data persistence with named volumes and bind mounts
  • Initialization scripts and performance tuning
  • Container networking for both internal and external access
  • Ecosystem tools like pgAdmin and PgBouncer

All commands are correct, examples are functional, and the progressive structure (from quick start to advanced topics) makes this approachable for users at different skill levels.

No blocking issues found. Great work! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants