Open jamesadevine opened 1 year ago
Allowing to set permissions for the directories as well as adding empty directories like /var/lib/app
is a need indeed. Right now, I'm looking for a hacky way to achieve this.
I know it would be useful, but as far as I can tell, the deb
format doesn't support this.
People use postinst
script for this, and I'm not sure if cargo-deb
should be generating bash scripts automatically. What if the package already has a postinst
script?
Hi!
I have the need to create a directory with read and write permissions as part of package set up. The directory is already created by the cargo-deb generated package as it is where the systemd unit binary (
app
) lives:A separate configuration binary (
app-configure
) allows users to configureapp
and the configuration files reside in/etc/abcdef
. Because the default permissions of/etc/abcdef
are set to read only, I need to modify the directory permissions so thatapp-configure
can write files to/etc/abcdef
.I've read that there are two ways this can be achieved:
override_dh_fixperms
/execute_after_dh_fixperms
followed bychmod <perms> <some directory>
postinst
script withchmod <perms> <some directory>
I've opted for (2), with this postinst script:
I have two questions: