I coded an application using libpcap and ncurses. Obviously, this application is supposed to run in the terminal.
Therefore, I created a script that launches my application in gnome-terminal with a fixed size:
#!/bin/sh gnome-terminal --geometry=75x36+0+0 --command="myapplication"'
I want to execute that on startup (after the desktop of the current logged in user has shown up). It is important to run this as root. Otherwise, libpcap won't be able to sniff for packets. I am aware of all the risks involved.
I created the following
[Unit] Description=My Application [Service] User=root Type=simple ExecStart=/usr/local/bin/myshellfile [Install] WantedBy=multi-user.target
And I put it in
/etc/systemd/system/myservice.service and preset it with
sudo systemctl preset myservice.service
Nevertheless, it does not work. What am I doing wrong here? Running Ubuntu 16.04 in an updated state.