Re: Running dpkg -r foo from a postinst script?
What you really want to do is to implement
Recommanded-Conflicts: brokenmailer, etcpassoire, trivialtohackftpd
Suggested-Conflicts: easyr00ted, lametelnetd
Well, creates an
that conflicts with brokenmailer, etcpassoire, trivialtohackftpd
and a harden-suggested-conflicts package
that conflicts with easyr00ted, lametelnetd
Then make task-harden to Recommands: harden-recommanded-conflicts and
It is not the real things, but closer than removing packages, because
it last after installation.(your scheme does not prevend etcpassoire too
be installed after task-harden)
(the real thing woud be to have a handful of packages
harden-conflict-trivialtohackftpd etc... that each conflicts with the
named package, but it lead to half dozen stupid virtual package more.)
Also consider how works task-packages:
It is an empty package. We install it. We got all the Depended, Recommended
packages. Afterward we can remove it safely, without affecting these packages.
So if tasken-harden conflicts with easyr00ted and I really need/want
easyr00ted, I can remove task-harden after it has been successfully installed
and install easyr00ted.
If too many people object that conflict in task package are evil, then
use an intermediate package as described above.