mirror of
				https://github.com/cookiecutter/cookiecutter-django.git
				synced 2025-11-01 00:17:54 +03:00 
			
		
		
		
	Add instuction to run celery beat (#4162)
* add instuction to run celery beat * Extend explanations for celery beat --------- Co-authored-by: Bruno Alla <browniebroke@users.noreply.github.com>
This commit is contained in:
		
							parent
							
								
									ad1edba711
								
							
						
					
					
						commit
						b74af5b1d1
					
				|  | @ -63,6 +63,20 @@ celery -A config.celery_app worker -l info | ||||||
| 
 | 
 | ||||||
| Please note: For Celery's import magic to work, it is important *where* the celery commands are run. If you are in the same folder with *manage.py*, you should be right. | Please note: For Celery's import magic to work, it is important *where* the celery commands are run. If you are in the same folder with *manage.py*, you should be right. | ||||||
| 
 | 
 | ||||||
|  | To run [periodic tasks](https://docs.celeryq.dev/en/stable/userguide/periodic-tasks.html), you'll need to start the celery beat scheduler service. You can start it as a standalone process: | ||||||
|  | 
 | ||||||
|  | ``` bash | ||||||
|  | cd {{cookiecutter.project_slug}} | ||||||
|  | celery -A config.celery_app beat | ||||||
|  | ``` | ||||||
|  | 
 | ||||||
|  | or you can embed the beat service inside a worker with the `-B` option (not recommended for production use): | ||||||
|  | 
 | ||||||
|  | ``` bash | ||||||
|  | cd {{cookiecutter.project_slug}} | ||||||
|  | celery -A config.celery_app worker -B -l info | ||||||
|  | ``` | ||||||
|  | 
 | ||||||
| {%- endif %} | {%- endif %} | ||||||
| {%- if cookiecutter.use_mailhog == "y" %} | {%- if cookiecutter.use_mailhog == "y" %} | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue
	
	Block a user