Skip to content

Add service healthchecks#578

Merged
mgruner merged 5 commits into
masterfrom
healthchecks
Jun 1, 2026
Merged

Add service healthchecks#578
mgruner merged 5 commits into
masterfrom
healthchecks

Conversation

@mgruner
Copy link
Copy Markdown
Collaborator

@mgruner mgruner commented May 29, 2026

No description provided.

@mgruner mgruner requested review from derpixler and fliebe92 May 29, 2026 09:28
@mgruner
Copy link
Copy Markdown
Collaborator Author

mgruner commented May 29, 2026

@derpixler @fliebe92 what do you think about this? Since @derpixler already added a health check for the railsserver, I think adding more for the base services makes sense. Now all defined depends_on can work on service_healthy instead of service_started.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds container healthchecks for core dependencies (Memcached, PostgreSQL, Redis) and updates depends_on to wait for those services to become healthy before starting Zammad services.

Changes:

  • Switch depends_on entries for Zammad services from simple startup ordering to condition: service_healthy.
  • Add healthchecks for zammad-memcached, zammad-postgresql, and zammad-redis.
  • Simplify the zammad-railsserver healthcheck definition formatting.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docker-compose.yml Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

@fliebe92
Copy link
Copy Markdown
Contributor

Looks good to me and - for sure - a step into the right direction! Thanks for addressing the point CoPilot mentioned.

@mgruner mgruner marked this pull request as ready for review May 29, 2026 11:20
@mgruner
Copy link
Copy Markdown
Collaborator Author

mgruner commented May 29, 2026

Would you like to approve, @fliebe92?

@mgruner
Copy link
Copy Markdown
Collaborator Author

mgruner commented May 29, 2026

PostgreSQL start_period: 30s zu knapp (docker-compose.yml:179)

  • Bei erster Initialisierung (Datenbank-Anlage) braucht Postgres oft >30s. Mit 5 Retries à 10s = ~80s Gesamtzeit. Kann bei langsamen Disks knapp werden.

@derpixler good point. I increased it to 60 seconds. For initializing an empty DB this sounds reasonable to me.

Comment thread docker-compose.yml
Comment thread docker-compose.yml Outdated
Copy link
Copy Markdown
Contributor

@fliebe92 fliebe92 left a comment

Choose a reason for hiding this comment

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

-z sounds good for the nc command.

@mgruner
Copy link
Copy Markdown
Collaborator Author

mgruner commented Jun 1, 2026

Can you have a look again, guys? I noticed more things, maybe for the future:

  • zammad-init only depends on postgresql. This looks wrong at first sight, but there might be reasons for this - we need to clarify this before changing (not in this MR).
  • There is no health check for ES and no dependency as well. Might also be historically works as designed (to run without ES). Maybe something for later.

Copy link
Copy Markdown
Contributor

@fliebe92 fliebe92 left a comment

Choose a reason for hiding this comment

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

Looks good to me, thanks for the changes 💪🏻

@mgruner mgruner merged commit 7d4472d into master Jun 1, 2026
12 checks passed
@mgruner mgruner deleted the healthchecks branch June 1, 2026 06:17
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.

4 participants