mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Split out the configuration more
This commit is contained in:
29
app/conf/celeryschedule.py
Normal file
29
app/conf/celeryschedule.py
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
from datetime import timedelta
|
||||||
|
|
||||||
|
CELERYBEAT_SCHEDULE = {
|
||||||
|
"reddit-validations": {
|
||||||
|
"task": "reddit.tasks.process_validations",
|
||||||
|
"schedule": timedelta(minutes=10),
|
||||||
|
},
|
||||||
|
"eveapi-update": {
|
||||||
|
"task": "eve_api.tasks.account.queue_apikey_updates",
|
||||||
|
"schedule": timedelta(minutes=10),
|
||||||
|
},
|
||||||
|
"alliance-update": {
|
||||||
|
"task": "eve_api.tasks.alliance.import_alliance_details",
|
||||||
|
"schedule": timedelta(hours=6),
|
||||||
|
},
|
||||||
|
"api-log-clear": {
|
||||||
|
"task": "eve_proxy.tasks.clear_old_logs",
|
||||||
|
"schedule": timedelta(days=1),
|
||||||
|
},
|
||||||
|
"blacklist-check": {
|
||||||
|
"task": "hr.tasks.blacklist_check",
|
||||||
|
"schedule": timedelta(days=1),
|
||||||
|
},
|
||||||
|
"reddit-update": {
|
||||||
|
"task": "reddit.tasks.queue_account_updates",
|
||||||
|
"schedule": timedelta(minutes=15),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -1,18 +1,9 @@
|
|||||||
import os
|
import os
|
||||||
import djcelery
|
import djcelery
|
||||||
from datetime import timedelta
|
|
||||||
|
|
||||||
# Django settings for login project.
|
|
||||||
|
|
||||||
|
# Debug settings
|
||||||
DEBUG = False
|
DEBUG = False
|
||||||
TEMPLATE_DEBUG = DEBUG
|
TEMPLATE_DEBUG = DEBUG
|
||||||
INTERNAL_IPS = ('127.0.0.1','91.121.180.45')
|
|
||||||
|
|
||||||
ADMINS = (
|
|
||||||
('Andrew Williams', 'andy@tensixtyone.com'),
|
|
||||||
)
|
|
||||||
|
|
||||||
MANAGERS = ADMINS
|
|
||||||
|
|
||||||
# Zone Settings
|
# Zone Settings
|
||||||
TIME_ZONE = 'UTC'
|
TIME_ZONE = 'UTC'
|
||||||
@@ -97,32 +88,7 @@ LOGIN_URL = "/login"
|
|||||||
|
|
||||||
### Celery Schedule
|
### Celery Schedule
|
||||||
|
|
||||||
CELERYBEAT_SCHEDULE = {
|
from celeryschedule import CELERYBEAT_SCHEDULE
|
||||||
"reddit-validations": {
|
|
||||||
"task": "reddit.tasks.process_validations",
|
|
||||||
"schedule": timedelta(minutes=10),
|
|
||||||
},
|
|
||||||
"eveapi-update": {
|
|
||||||
"task": "eve_api.tasks.account.queue_apikey_updates",
|
|
||||||
"schedule": timedelta(minutes=10),
|
|
||||||
},
|
|
||||||
"alliance-update": {
|
|
||||||
"task": "eve_api.tasks.alliance.import_alliance_details",
|
|
||||||
"schedule": timedelta(hours=6),
|
|
||||||
},
|
|
||||||
"api-log-clear": {
|
|
||||||
"task": "eve_proxy.tasks.clear_old_logs",
|
|
||||||
"schedule": timedelta(days=1),
|
|
||||||
},
|
|
||||||
"blacklist-check": {
|
|
||||||
"task": "hr.tasks.blacklist_check",
|
|
||||||
"schedule": timedelta(days=1),
|
|
||||||
},
|
|
||||||
"reddit-update": {
|
|
||||||
"task": "reddit.tasks.queue_account_updates",
|
|
||||||
"schedule": timedelta(minutes=15),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
CELERY_SEND_TASK_ERROR_EMAILS = True
|
CELERY_SEND_TASK_ERROR_EMAILS = True
|
||||||
CELERY_RESULT_BACKEND = "amqp"
|
CELERY_RESULT_BACKEND = "amqp"
|
||||||
|
|||||||
@@ -42,3 +42,9 @@ FULL_API_CHARACTER_ID = 246102445
|
|||||||
## Django
|
## Django
|
||||||
DEBUG = True
|
DEBUG = True
|
||||||
SECRET_KEY = '8i2+dd-b2tg9g%mq$&i$-8beh4i5^2mm=e-nh^$p47^w=z1igr'
|
SECRET_KEY = '8i2+dd-b2tg9g%mq$&i$-8beh4i5^2mm=e-nh^$p47^w=z1igr'
|
||||||
|
|
||||||
|
ADMINS = (
|
||||||
|
('Andrew Williams', 'andy@tensixtyone.com'),
|
||||||
|
)
|
||||||
|
MANAGERS = ADMINS
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user