debian build 3.0.11 logrotate.d why still radius #1510

Closed
whyname opened this Issue Jan 27, 2016 · 5 comments

Comments

Projects
None yet
4 participants

whyname commented Jan 27, 2016

debian build 3.0.11 logrotate.d why still radius not freeradius, i found in debian file this is fixed, why build not auto fix?

Owner

alandekok commented Jan 27, 2016

Please say which file is wrong, and what is wrong with it.

If you have general questions about FreeRADIUS, they belong on the freeradius-users mailing list.

Contributor

matsimon commented Mar 8, 2016

I think I found the issue... took me some reading about Debian packaging details:

  • debian/patches/logrotate-path.diff correctly patches scripts/logrotate/freeradius, I do see the patch getting applied when building the package without errors on both 3.0.x and 3.1.x
  • However the file that gets eventually installed is the one with the content of debian/freeradius.logrotate which is set to rotate files /var/log/radius, not /var/log/freeradius

It looks like the patched file is never going to be installed since dh_installlogrotate in debian/rules will always install freeeradius.logrotate to /etc/logrotate.d

So yes, @whyname is right about the fact there is an issue with logrotate on Debian, but I agree with @alandekok that the description doesn't contain enough details.

I'd propose the following path to fix this issue similar to what the Red Hat packaging does (it also uses redhat/freeradius-logrotate not scripts/logrotate/freeradius).

  • Drop debian/patches/logrotate-path.diff
  • Copy scripts/logrotate/freeradius to debian/freeradius.logrotate and apply the fixes we previously had in the patch for Debian.

I haven't found an example where dh_installlogrotate was used to with --name= pointing to a file outside of the /debian folder, that's why I thought this way might be more reliable.

Looking forward to your feedback so I can go forward and prepare pull requests.

Contributor

matsimon commented Mar 8, 2016

Once this issue is fixed I'll likely cherry-pick that fix to the 3.0.11 release packages for my Debian (1Labs) repository. Actually this might be of interest to @fajarnugraha as well who uploads to the Ubuntu PPA.

Owner

alandekok commented Mar 8, 2016

sounds good to me.

@matsimon matsimon added a commit to matsimon/freeradius-server that referenced this issue Mar 10, 2016

@matsimon matsimon Fix Debian logrotate, closes #1510
- Remove the patch to scripts/logrotate/freeradius as it isn't
  anyway the file that the Debian package eventually installs.
- Instead apply the Debian-specific locations to debian/freeradius.logrotate
  so deb packages should now come with a working logrotate config.
6f782c1

@alandekok alandekok added a commit that referenced this issue Mar 10, 2016

@alandekok alandekok Merge pull request #1562 from matsimon/1510-debian-logrotate-30x
Fix Debian logrotate, closes #1510 (on 3.0.x)
169e497

alandekok closed this in df0be79 Mar 10, 2016

@alandekok alandekok added a commit that referenced this issue Mar 10, 2016

@alandekok alandekok Merge pull request #1561 from matsimon/1510-debian-logrotate-31x
Fix Debian logrotate, closes #1510 (on 3.1.x)
413dad2
Member

fajarnugraha commented Mar 15, 2016

Thanks @alandekok and @matsimon , ppa:freeradius/stable-3.0 updated with df0be79

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment