主管命令不会启动铬

2024-05-18 15:34:24 发布

您现在位置:Python中文网/ 问答频道 /正文

编辑:显然脚本确实在运行,但它不能启动我的浏览器。还是不知道为什么这样。

我试图使用supervisor来运行命令/脚本,但我似乎无法使其正常工作。在

我想到了Pi_Video_looper,它对下面的脚本执行相同的操作:

# Supervisord configuration to run video looper at boot and
# ensure it runs continuously.
[program:video_looper]
command=python -u -m Adafruit_Video_Looper.video_looper
autostart=true
autorestart=unexpected
startsecs=5

所以我把它修改成这样:

^{pr2}$

我还用它来命令:

python /home/pi/Startup/Script.py

它执行一些测试,然后调用浏览器,但也不执行任何操作,尽管它完全可以从命令行运行。我错过什么了吗?在

编辑:重新启动后不工作,sudo service supervisor restart后不工作

编辑2: Logfile显示它应该在运行,所以显然它没有在我的GUI中打开它?公司名称:

2016-01-27 16:40:43,569 INFO daemonizing the supervisord process
2016-01-27 16:40:43,573 INFO supervisord started with pid 4767
2016-01-27 16:40:44,583 INFO spawned: 'video_looper' with pid 4773
2016-01-27 16:40:49,593 INFO success: video_looper entered RUNNING state, process has stayed up for > than 5 seconds (startsecs)

Tags: 命令info脚本编辑videowithpi浏览器
1条回答
网友
1楼 · 发布于 2024-05-18 15:34:24

工作版本如下: 这里的主要问题是由于一些不明确的原因,铬不能作为根来运行

# Supervisord configuration to run chromium at boot and
# ensure it runs continuously.
[program:chromiumbrowser]
command=chromium-browser http://google.be  incognito
user=pi
autostart=true
autorestart=unexpected
startsecs=5

相关问题 更多 >

    热门问题