Kaydet (Commit) 141fc930 authored tarafından Batuhan Taşkaya's avatar Batuhan Taşkaya

Get rid of crons

üst c7eab392
......@@ -15,7 +15,6 @@ gunicorn = "*"
whitenoise = "*"
docker = "*"
evality = "==0.2.1"
django-cron = "*"
[scripts]
start = "gunicorn aspava.wsgi:application --bind localhost:8000"
......
{
"_meta": {
"hash": {
"sha256": "99500a84e640f527b14abf69b834ae7c8dc17600ae81655272680cf080d79540"
"sha256": "f7d5f6bc4fbca2893bd56d1a4941e33a77186a659547c40ffcc69188771f1deb"
},
"pipfile-spec": 6,
"requires": {
......@@ -53,19 +53,6 @@
"index": "pypi",
"version": "==0.0.8"
},
"django-common-helpers": {
"hashes": [
"sha256:2d56be6fa261d829a6a224f189bf276267b9082a17d613fe5f015dd4d65c17b4"
],
"version": "==0.9.2"
},
"django-cron": {
"hashes": [
"sha256:08d22708c8b2ecab8cda989019a66c7e1e2424c59d822796fd45abf7731d261d"
],
"index": "pypi",
"version": "==0.5.1"
},
"django-ranged-response": {
"hashes": [
"sha256:f71fff352a37316b9bead717fc76e4ddd6c9b99c4680cdf4783b9755af1cf985"
......
......@@ -41,7 +41,6 @@ INSTALLED_APPS = [
"bootstrap4",
"django_ace",
"captcha",
"django_cron",
]
MIDDLEWARE = [
......@@ -122,6 +121,3 @@ AUTH_USER_MODEL = "social.SocialUser"
MAX_POST_LENGTH = 144 * 2
AVATAR_BASE = "img/avatars/avatar_{}.png"
DESC = "Apparently, this user prefers to keep an air of mystery about them."
# Crons
CRON_CLASSES = ["social.cronjobs.RenewEvalityCron"]
from social.cronjobs.renew_evality import RenewEvalityCron
from django_cron import CronJobBase, Schedule
from social.utils import quit_evality
class RenewEvalityCron(CronJobBase):
RUN_EVERY_MINS = 1
schedule = Schedule(run_every_mins=RUN_EVERY_MINS)
code = 'social.cronjobs.RenewEvalityCron'
def do(self):
quit_evality()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment