From 08f97ff39fd4e70c0c07e9f17f387c3fc7629427 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Daher?= Date: Fri, 5 Feb 2021 17:33:26 -0300 Subject: [PATCH] Use a more dedicated name to get the service URL --- README.md | 2 ++ django_cloud_tasks/apps.py | 2 +- pyproject.toml | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 260299c..505407c 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,8 @@ The following APIs must be enabled in your project(s): ## How it works +> Add ``GOOGLE_CLOUD_TASKS_ENDPOINT`` to your Django settings or as an environment variable + ![image](https://user-images.githubusercontent.com/9717144/100749131-00cce780-33c3-11eb-8f2a-b465bc0a45bb.png) ## Setup diff --git a/django_cloud_tasks/apps.py b/django_cloud_tasks/apps.py index bd35b2e..db23648 100644 --- a/django_cloud_tasks/apps.py +++ b/django_cloud_tasks/apps.py @@ -17,7 +17,7 @@ def __init__(self, *args, **kwargs): self.on_demand_tasks = {} self.periodic_tasks = {} self.subscriber_tasks = {} - self.domain = self._fetch_config(name='DOMAIN_URL', default='http://localhost:8080') + self.domain = self._fetch_config(name='GOOGLE_CLOUD_TASKS_ENDPOINT', default='http://localhost:8080') def _fetch_config(self, name, default): return getattr(settings, name, os.environ.get(name, default)) diff --git a/pyproject.toml b/pyproject.toml index 546837d..b3a2f8a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "django-google-cloud-tasks" -version = "0.3.6" +version = "0.3.7" description = "Async Tasks with HTTP endpoints" authors = ["Joao Daher "] packages = [