无法在Python 2中的单独进程中启动ngrok

时间:2018-04-11 07:55:32

标签: python shell ngrok

直到几个月前,这个命令以前工作得很好。现在它没有。怎么了?

bashCommand = "nohup /Users/myname/ngrok http 8889 </dev/null >/dev/null 2>&1 &"
process = subprocess.Popen(bashCommand.split(), stdout=subprocess.PIPE)
output, error = process.communicate()

导致以下错误 -

ERROR:  You must specify a single argument: a port or address to tunnel to.
ERROR:  You specified 5 arguments: [8889 </dev/null >/dev/null 2>&1 &]
ERROR:  For example, to expose port 80, run 'ngrok http 80'.

0 个答案:

没有答案