-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcelerybeat.j2
39 lines (33 loc) · 1.42 KB
/
celerybeat.j2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Where to chdir at start.
CELERYBEAT_CHDIR="{{ django_codebase_path }}"
# Python interpreter from environment, if using virtualenv
ENV_PYTHON="{{ django_venv_path }}/bin/python"
CELERY_BIN="{{ django_venv_path }}/bin/celery"
# Name of the celery config module, don't change this.
CELERY_APP="{{ django_celery_app }}"
# %n will be replaced with the nodename.
# Workers should run as an unprivileged user.
CELERYBEAT_USER="{{ django_system_user }}"
CELERYBEAT_GROUP="{{ django_system_group }}"
# Set any other env vars here too!
PROJET_ENV="{{ django_env_name }}"
C_FORCE_ROOT=1
CELERYBEAT_LOG_LEVEL="{{ django_celerybeat_log_level }}"
CELERYBEAT_LOG_FILE="/var/log/{{ django_system_user }}/celerybeat.log"
CELERY_CREATE_DIRS=1
CELERYBEAT_SCHEDULE="/var/run/{{ django_system_user }}/celerybeat-schedule"
CELERYBEAT_STATE_DIR="/var/run/{{ django_system_user }}/celerybeat"
{% if django_celery_beat_pid_file %}
CELERYBEAT_PID_FILE="{{ django_celery_beat_pid_file }}"
{% else %}
CELERYBEAT_PID_FILE="/var/run/{{ django_system_user }}/celerybeat.pid"
{% endif %}
# Name of the projects settings module.
# in this case is just settings and not the full path because it will change the dir to
# the project folder first.
DJANGO_SETTINGS_MODULE="{{ django_settings_module }}"
{% if django_celerybeat_extra_env_vars | length > 0 %}
{% for var_name,var_value in django_celerybeat_extra_env_vars.items() %}
{{ var_name }}={{ var_value }}
{% endfor %}
{% endif %}