Re: How to run an external command that must run with the server

2018-04-03 Thread 'Alex' via Django users
Yes, it runs constantly, whenever the server is up. Ok, I'll stick with the management command as a supervisor process, thank you! On Tuesday, 3 April 2018 14:09:40 UTC+1, Ken Whitesell wrote: > > There's an aspect of your situation which isn't entirely clear to me - is > this management command

Re: How to run an external command that must run with the server

2018-04-03 Thread Ken Whitesell
There's an aspect of your situation which isn't entirely clear to me - is this management command one that remains running all the time, like a Celery task would be; or is it one that starts, runs a process for a period of time, and then ends - only to be restarted at a later time? If the former

Re: How to run an external command that must run with the server

2018-04-03 Thread 'Alex' via Django users
That makes sense. So leave the source as a management command (as it is now), and just run python manage.py source through supervisor? On Sunday, 1 April 2018 13:16:38 UTC+1, Ken Whitesell wrote: > > We set up all our Django-related processes as a group under supervisor. > This includes our cel

Re: How to run an external command that must run with the server

2018-04-01 Thread Ken Whitesell
We set up all our Django-related processes as a group under supervisor. This includes our celery-based processes. (We have some long-running tasks that are kicked off by the web site.) By setting it up as a group, we can manage all the different processes as a set. Whether or not that's the "b

How to run an external command that must run with the server

2018-04-01 Thread 'Alex' via Django users
I have a daphne server running a django channels application. I also have a python script that aggregates data from various sources, and sticks it into the channel layer (called source.py). At the moment, I run it as a management command (python manage.py source). It is nearly time for deployme