docker-library / docker-library/docs

PostgreSQL: Document how a dependent service/container should detect when the database has started

Open
#2,467 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
5.3k
Forks
2.2k
Avg merge
1d 18h
Merged PRs (30d)
11

Description

The postgres images provide an RDBMS which is usually a dependency of other services. The Compose depends_on attribute allows to express that, but its conditions attribute defaults to service_started, which does not work properly (the dependency is satisfied too early).

Lots of webpages deal with that issue, such as the docker-compose-healthcheck project, usually suggesting the service_healthy condition instead. It would be great to either provide a proper/reliable way for PostgreSQL to signal dependents that it is actually started, or at least mitigate by documenting the best way to workaround.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the PostgreSQL image documentation and the Compose depends_on documentation linked in the issue. Determine whether PostgreSQL can provide a reliable readiness signal; otherwise document the recommended healthcheck and service_healthy workaround, with an example that clearly shows when the dependent service may start.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, docker-compose, postgres
Domain
databases, devops, documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.