Reputation: 2622
I want to be able to execute some shell commands like mkvirtualenv
and createdb
and such from a Django app, these processes will likely go into a Django celery task later. I would think using system() would be insecure to execute shell commands from Django/Apache, so my question is what is the best way to execute shell commands from a django app?
Upvotes: 0
Views: 662
Reputation: 18982
To start a shell process in the background you can use the subprocess
module.
Upvotes: 1