On Mon, Aug 14, 2017 at 6:23 AM, Harke Smits <[email protected]> wrote:
> Thank you very much, I keep on learning. My application now runs fine
> manually from XTerminal. Now I want to run the application on boot. I
> figured out a systemd service is problably the way to go. I managed to
> define that (ac.service) and run it on boot up. I wrote:
> [Unit]
> After = grafical.target
> [Service]
> Type = idle
> ExecStart = /home/debian/eme {*etc to run Python script and make log
> file}*
> [Install]
> WantedBy=multi-user.target
>
> This sort of works but the application does not start: the log file gives
> the famous $DISPLAY error. I try to start my application last, so after the
> X server has been started. Maybe the "WantedBy" statement is wrong?
>
> The default setup in systemd starts the graphical target (btw, graphical
not grafical), and runs the login manager which then runs graphical desktop
manager which allows you to run your app.
The simplest way to handle it is to use the 'autostart' feature of the
display manager.
You can replace the whole setup in systemd by doing what you are doing, but
you have to take out the display/login manager.
You will also need to add
Environment="DISPLAY=:0"
and maybe XAUTHORITY to the [Service} section
--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/beagleboard/CAC%3D1GgHE3pQKSpH4gq1V2N_PJWiZVoZMFtgT0FjOUdGP_GtebQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.