mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-15 09:24:52 +03:00
Set CELERY_BROKER_URL to build docs
This commit is contained in:
parent
0e46096c3e
commit
bd5e459f3e
|
@ -17,9 +17,6 @@ import django
|
|||
if os.getenv("READTHEDOCS", default=False) == "True":
|
||||
sys.path.insert(0, os.path.abspath(".."))
|
||||
os.environ["DJANGO_READ_DOT_ENV_FILE"] = "True"
|
||||
{%- if cookiecutter.use_celery == 'y' %}
|
||||
os.environ["CELERY_BROKER_URL"] = os.getenv("REDIS_URL", "redis://redis:6379")
|
||||
{%- endif %}
|
||||
os.environ["USE_DOCKER"] = "no"
|
||||
else:
|
||||
{%- if cookiecutter.use_docker == 'y' %}
|
||||
|
@ -28,6 +25,9 @@ else:
|
|||
sys.path.insert(0, os.path.abspath(".."))
|
||||
{%- endif %}
|
||||
os.environ["DATABASE_URL"] = "sqlite:///readthedocs.db"
|
||||
{%- if cookiecutter.use_celery == 'y' %}
|
||||
os.environ["CELERY_BROKER_URL"] = os.getenv("REDIS_URL", "redis://redis:6379")
|
||||
{%- endif %}
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "config.settings.local")
|
||||
django.setup()
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user