Linux 在后台运行Web服务器
为了让我的网站在Web服务器上运行,我必须使用以下命令手动登录:Linux 在后台运行Web服务器,linux,bash,webserver,Linux,Bash,Webserver,为了让我的网站在Web服务器上运行,我必须使用以下命令手动登录: ssh IP add password cd chn source bin/activate cd chn python3 manage.py runserver IP:80 就这样!如何在后台运行所有这些过程? 另外,我想服务器是在Linux/Ubuntu14.0上运行的。如果我把&放在每行的末尾,我会在我的终端中看到它们,但我担心当我关闭我的mac/终端时,它会停止所有操作 root@localhost:~# ps aux
ssh IP
add password
cd chn
source bin/activate
cd chn
python3 manage.py runserver IP:80
就这样!如何在后台运行所有这些过程?
另外,我想服务器是在Linux/Ubuntu14.0上运行的。如果我把&
放在每行的末尾,我会在我的终端中看到它们,但我担心当我关闭我的mac/终端时,它会停止所有操作
root@localhost:~# ps aux | grep 1373
root 30873 0.0 0.0 11724 680 pts/1 S+ 14:35 0:00 grep --color=auto 1373
root@localhost:~# ps aux | grep 30827
root 30875 0.0 0.0 11724 676 pts/1 S+ 14:36 0:00 grep --color=auto 30827
root@localhost:~# ps aux | grep 30835
root 30835 0.2 3.0 100644 31024 pts/0 S 14:33 0:00 python3 manage.py runserver IP:80
root 30877 0.0 0.0 11724 676 pts/1 S+ 14:36 0:00 grep --color=auto 30835
谢谢大家! 它使用了这个命令
Nohup python3 manage.py runserver 5.83.45.64:80&
问题不清楚,我如何在后台运行所有这些过程代码>登录过程或启动app?savior为了运行服务器,我必须使用ssh登录添加密码启动virtualenv并运行服务器。我需要让我的服务器一直在后台运行,即使当我关闭终端时,也不需要每次启动笔记本电脑时都打开它。非常感谢。希望我是清楚的!PS请记住,我必须首先运行我的虚拟环境,使服务器运行。PS是我第一次这样做,所以请理解我缺乏经验!您可以使用nohup命令,甚至可以编写初始化脚本