Skip to content

Conversation

DAcodedBEAT
Copy link
Contributor

@DAcodedBEAT DAcodedBEAT commented Jun 24, 2025

Description

Changed the restart policy to unless-stopped to ensure containers automatically restart after failures or reboots but allow manual stop without immediate restart.

This is preferable over always because it prevents containers from restarting automatically after a manual stop, enabling controlled shutdowns and maintenance without unintended restarts.

How Has This Been Tested?

Case 1:

  1. start docker containers
  2. stop docker containers
  3. restart docker engine
  4. see that it doesnt automatically restart

Case 2:

  1. start docker containers
  2. restart docker engine
  3. see that it automatically restarts (like before)

Backporting (check the box to trigger backport action)

Note: You have to check that the action passes, otherwise resolve the conflicts manually and tag the patches.

  • This PR should be backported (make sure to check that the backport attempt succeeds)
  • [Optional] Override Linear Check

Changed the restart policy to unless-stopped to ensure containers
automatically restart after failures or reboots but allow manual stop
without immediate restart.

This is preferable over always because it prevents containers from
restarting automatically after a manual stop, enabling controlled
shutdowns and maintenance without unintended restarts.
@DAcodedBEAT DAcodedBEAT requested a review from a team as a code owner June 24, 2025 19:14
Copy link

vercel bot commented Jun 24, 2025

@DAcodedBEAT is attempting to deploy a commit to the Danswer Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

Updates Docker Compose restart policies from 'always' to 'unless-stopped' across all deployment configurations, enabling better operational control while maintaining system reliability.

  • Changed restart policy to unless-stopped in 7 Docker Compose files, allowing manual stops without auto-restart while preserving auto-recovery after crashes/reboots
  • Maintained on-failure policy for inference and indexing model servers, preserving their existing behavior for optional disablement
  • Implementation consistent across all environments (dev, prod, GPU, multitenant, testing)
  • Well-tested for both automatic restart after Docker engine restart and manual stop scenarios
  • Update promotes safer maintenance operations by preventing unwanted container restarts

7 files reviewed, no comments
Edit PR Review Bot Settings | Greptile

@Weves Weves merged commit e74a039 into onyx-dot-app:main Jun 24, 2025
4 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants