Open farrukhnajmi opened 4 years ago
Would also like to see native systemd
services supported.
As for your first question: While Debian is Ubuntu's foundation, Ubuntu used its own upstart
as init system, while Debian used sysv-init
. That might explain your svc error.
However, having systemd supported would solve that problem, since ALL major distributions have switched to it completely.
This is what we do currently for these:
https://github.com/nebula-plugins/gradle-ospackage-plugin/issues/404#issuecomment-915698202
I tried out the nebula.ospackage to create a debian package for Ubuntu 18.04 server successfully and it rock! Thank you.
I then tried using nebula.ospackage-daemon plugin to extend my debian package to create a service for my app. I was not successful.
My daemon DSL looked like this:
The package installed fine and created files as expected under /service and /etc/init.d.
However, I could not get the service to start. It complained about an svc error:
Nov 06 18:13:59 ubuntu-factory my-app[714]: my-app: svc: warning: unable to control /service/my-app
This even though the
/service/my-app
file existed and had correct permissions.Learning more about services in linux I learned that systemd is the new way to define services rather than init.d..
I was able to manually setup my app as a service using systemd easily following this resource and this resource.
I have two questions: