Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add celery beat service to docker compose #4390

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

chazzhou
Copy link
Contributor

Description

This change adds a new beat service to the docker-compose.yaml file for the self-hosted version of Dify. The beat service is responsible for running scheduled tasks using Celery beat. Previously, the self-hosted version did not have the beat service running, and as a result, scheduled tasks in api/schedule listed in beat_schedule under api/extensions/ext_celery.py were not being executed.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

  • Verified that the beat service starts successfully when running docker-compose up
  • Confirmed that scheduled tasks are being executed as expected with the beat service running

Suggested Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • I ran dev/reformat(backend) and cd web && npx lint-staged(frontend) to appease the lint gods
  • optional I have made corresponding changes to the documentation
  • optional I have added tests that prove my fix is effective or that my feature works
  • optional New and existing unit tests pass locally with my changes

@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. 🐞 bug Something isn't working labels May 14, 2024
@JohnJyong
Copy link
Contributor

JohnJyong commented May 15, 2024

the beat service is used for our SAAS env, so it‘s not necessary to add in the docker-compose.yaml
if you need this service , you are free to execute it locally, thanks @chazzhou

@bowenliang123
Copy link
Contributor

This is an interesting hint for all local deployment users. Maybe celery beat should be mentioned on the docs for Local Source Code Start(https://docs.dify.ai/getting-started/install-self-hosted/local-source-code).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working size:L This PR changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants