DH-IT-Portal-Development / ethics

Ethical Committee web application in Django
http://fetc.hum.uu.nl
MIT License
2 stars 1 forks source link

Email changes #614

Closed tymees closed 6 months ago

tymees commented 9 months ago

This PR addresses #529. It was a pain, but I think I got everything right.

As a bonus, I also implemented #623, as it was kinda related.

I cannot wait till we have the new mailing code. Keeping multiple versions in sync is a pain

tymees commented 6 months ago

How do cron jobs work though? Where do these reside for ethics?

Cron jobs are set on the server OS; Under the hood, it's a program that runs in the background, that just fires off 'shell commands' depending on the configured interval. We configure it to run a django management command ('send-reminders').

As described in #315, we run this: 0 7 * * * /<snip>/data/env/bin/python /<snip>/data/source/manage.py send_reminders >/dev/null 2>&1

This means 'on minute 0, hour 7, any day, any month and any year, execute the following command'.

(So, 15 7 1 3 2025 would be 'run this command on the first of march, 2025 at 7:15'. Nobody would do this, as this would only run once ever)