Quote:
Originally Posted by fkitdco
hi
i want to run a command while starting up debian
(no need sh file , just command)
please help me
|
I haven't used systemd in awhile, but if memory serves this should do. Maybe have to verify location of command.
Code:
cat /etc/systemd/system/opensips.service
[Unit]
Description=Starts opensips
[Service]
Type=oneshot
ExecStart=/usr/sbin/opensips
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Code:
systemctl enable opensips
Code:
systemctl start opensips