1

I'm trying to launch a python script in a lxterminal window using supervisord. I'm stuck on using supervisord than a .desktop file. I'd like to keep the process running on loop Below is my config:

[program:video_serve]
user=pi
environment=PYTHONPATH=/home/pi/.local/lib/python3.5/site-packages/
command=/home/pi/jack-harper/video-server.sh
directory=/home/pi/jack-harper/
autostart=true
autorestart=true
startsecs=5
log_stdout=true             ; if true, log program stdout (default true)
log_stderr=true             ; if true, log program stderr (default false)
stderr_logfile=/home/pi/jack-harper/video.err
logfile=/home/pi/jack-harper/video.log


[supervisord]
; When resorting to send SIGKILL to the program to terminate it
; send SIGKILL to its whole process group instead,
; taking care of its children as well.
killasgroup=true
nodaemon=true
logfile_maxbytes=2MB 
stdout_logfile_maxbytes=1MB
stdout_logfile_backups=0

I get the following error in my log file, which means the script ran and the config is okay ? But I still don't see a lxterminal window running the script:

(lxterminal:3223): Gtk-WARNING **: cannot open display:

  • I have tried running this from Desktop GUI directly after failing to do so via ssh
  • These also did not work: export DISPLAY=:0.0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.