Opened 4 weeks ago

Last modified 3 weeks ago

#2402 new defect

All conffiles should be in /etc

Reported by: mhatta Owned by: zzz
Priority: minor Milestone: 0.9.39
Component: package/debian Version: 0.9.38
Keywords: Cc: mhatta, zzz
Parent Tickets:

Description (last modified by mhatta)

1) All files under /etc are marked as conffile automatically, so you don't need debian/i2p.conffiles (since it only contains /etc/i2p/wrapper.config).

2) All files needed to be modified locally should be in /etc.

https://www.debian.org/doc/debian-policy/ch-files.html#location

Also, sometimes /usr might be mounted read-only. Even in such cases, the local sysadmin can fix things if files are under /etc.

So the use of debian/i2p-router.conffiles is not appropriate, I guess we need to move needed files from /usr/share/i2p to /etc/i2p. Or, we can symlink files from /usr/share/i2p to /etc/i2p.

Subtickets (add)

Attachments (1)

diff (3.5 KB) - added by mhatta 3 weeks ago.

Download all attachments as: .zip

Change History (11)

comment:1 Changed 4 weeks ago by mhatta

  • Description modified (diff)

comment:2 Changed 4 weeks ago by mhatta

  • Description modified (diff)

comment:3 Changed 4 weeks ago by zzz

will need to discuss this. might not be so easy to move things around, or maybe the conffiles was a bad idea.

comment:5 Changed 4 weeks ago by zzz

Nothing in i2p-router.conffiles is expected to change, but I think it's good to have it in conffiles in case they do.

Alternatively, we could move them all to /etc/i2p and symlink them.

I don't understand the bug report above, we don't modify wrapper.config do we? Or when? During the build?

comment:6 Changed 4 weeks ago by zzz

oh, I see, in i2p.postinst the file is modified. That's all kytv stuff from 2011. You'll have to tell me the best way to fix that, I have no idea what the rules are, let me know.

comment:7 Changed 4 weeks ago by zzz

I don't see any reason why wrapper.config can't be anywhere. By putting it in /usr/share/i2p, it's in the "base" directory, just like it is for non-package installs.

We'd have to change the following files under debian/ (and debian-alt/* if applicable):

i2p.init, i2p.install, ip.postinst, i2p.service, apparmor/i2p, patches/0001-path-substitution.patch; and i2p.conffiles.

In our code, we'd have to enhance the method at the bottom of OOMListener.

All this could be avoided if we change the way i2p.postinst works, or remove the memory limit dialog? let me know what our options are.

comment:8 Changed 3 weeks ago by mhatta

I modified postinst & postrm to use ucf (https://manpages.debian.org/unstable/ucf/ucf.1.en.html). Looks like working, I uploaded 0.9.38-2 to Debian sid. Let's see if it's ok with piuparts.

comment:9 Changed 3 weeks ago by zzz

ok, ucf in trusty+, jessie+. let's see how it goes.

Is "piuparts" checker run automatically on your upload, and you can find the results somewhere? Or do you have to ask the person that filed the ticket to see if you did it right?

Changed 3 weeks ago by mhatta

comment:10 Changed 3 weeks ago by mhatta

0.9.38-2 still had the problem. Seems 0.9.38-3 is okay, diff attached. The point is, not install /etc/i2p/wrapper.config, not modify /usr/share/i2p/wrapper.config, copy & change it and let ucf handle it.

piuparts is run automatically on piuparts.debian.org (I think once a day after upload), we can see the result at https://piuparts.debian.org/sid/source/i/i2p.html. I found I can run it locally (sudo apt-get install piuparts; sudo piuparts i2p_0.9.38-3_all.deb)

Note: See TracTickets for help on using tickets.