Hello,
I have a Python Django application runing on my droplet. I run it via command
python manage.py runserver 127.0.0.1:8001
And i have nginx server forwarding requests to that local server. Everything is runing smoothly.
The problem is: When i run
python manage.py runserver 127.0.0.1:8001
command, i can’t do anything else, or if i reconnect it using ssh my local server stops. How can i make it run all the time at background?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
You can do this with screen. This tutorial walks you through the details.
In short you can install screen with:
apt-get update;
apt-get install screen;
Then run
screen -S "my service"
And run your Django app. Once it is up and running press ctrl+a d to disconnect from the screen session. This leaves your app running while freeing up the console for other work. When you want to reconnect to your screen session to manage your running Django app or to stop it you can run
screen -R
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.