How to run a program at boot on minimal Ubuntu image

Post Reply
Sebas_Ledesma
Posts: 85
Joined: Thu Jun 08, 2017 2:49 am
languages_spoken: english
ODROIDs: c2
Has thanked: 4 times
Been thanked: 2 times
Contact:

How to run a program at boot on minimal Ubuntu image

Unread post by Sebas_Ledesma » Wed Aug 14, 2019 4:22 am

Hi:

We are using Odroid C1 for a new project.
We want to use the minimal distribution.
No monitor will used, instead an 3.2 OLE display managed through SPI, so I have 2 questions:

- How autologin a user? (and then autorun a program)
- How can i run a program at startup? (launch the process under a specific user, no need to pass the login )

Thanks in advance
Sebas

User avatar
odroid
Site Admin
Posts: 32166
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 122 times
Been thanked: 297 times
Contact:

Re: How to run a program at boot on minimal Ubuntu image

Unread post by odroid » Wed Aug 14, 2019 11:02 am

This wiki page might be helpful even the page was written for ODROID-N2.
Try it and let us know the result.
https://wiki.odroid.com/odroid-n2/ubunt ... mi_console
These users thanked the author odroid for the post:
Sebas_Ledesma (Tue Aug 20, 2019 4:40 am)

Sebas_Ledesma
Posts: 85
Joined: Thu Jun 08, 2017 2:49 am
languages_spoken: english
ODROIDs: c2
Has thanked: 4 times
Been thanked: 2 times
Contact:

Re: How to run a program at boot on minimal Ubuntu image

Unread post by Sebas_Ledesma » Tue Aug 20, 2019 1:08 am

Thanks, both worked!

In the first point "Auto login on HDMI console" I've changed root to myUser.
[Service]
ExecStart=
ExecStart=-/sbin/agetty --noissue --autologin myUser %I $TERM
Type=idle
In the second part "How to start your application software automatically", I've added myApp that act as discovery service successfully.


Sebas

User avatar
odroid
Site Admin
Posts: 32166
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 122 times
Been thanked: 297 times
Contact:

Re: How to run a program at boot on minimal Ubuntu image

Unread post by odroid » Tue Aug 20, 2019 10:09 am

Thank you for the confirmation and sharing what you did.

Post Reply

Return to “Ubuntu”

Who is online

Users browsing this forum: No registered users and 1 guest