0

I have a package to maintain, which has a WantedBy dependency. It must also save it's state after being updated (enabled/disabled, active/inactive after package was updated).
Suddenly I needed to change WantedBy dependency from one service to another (WantedBy A.service to WantedBy B.service) and I felt puzzled when I tried to find debhelper options for that. I did not find any way to delete previous dependency on update autoamtically without meddling with postinst script.

Is there a proper way to do so via debhelper auto-generated scripts?
ATM I'm using dh_installsystemd like that to save service state:

override_dh_installsystemd: dh_installsystemd --no-enable --restart-after-upgrade --no-start 

It updates service and saves it's state and overall works fine except for removing excessive service dependencies.

If there is no way to do that via dh, is there any other good standard way? It seems strange that it was not implemented by default. Why isn't it done on deb-systemd-helper enable my_package.service?

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.