Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #4026 - Move the configuration file /etc/logrotate.d/rudder-server-root to /etc/logrotate.d/rudder in Debian way #152

Merged
merged 1 commit into from
Oct 8, 2013
Merged

Fixes #4026 - Move the configuration file /etc/logrotate.d/rudder-server-root to /etc/logrotate.d/rudder in Debian way #152

merged 1 commit into from
Oct 8, 2013

Conversation

nperron
Copy link
Contributor

@nperron nperron commented Oct 8, 2013

Fixes #4026 - Move the configuration file /etc/logrotate.d/rudder-server-root to /etc/logrotate.d/rudder in Debian way

See http://www.rudder-project.org/redmine/issues/4026

@nperron
Copy link
Contributor Author

nperron commented Oct 8, 2013

Seems to work like a charm:

root@server:~# dpkg -L rudder-server-root
[...]
/etc/init.d/rudder-server-root
/etc/logrotate.d
/etc/logrotate.d/rudder
/etc/logrotate.d/rudder-server-root
root@server:~# 
root@server:~# 
root@server:~# dpkg -i /tmp/rudder-server-root_2.8.0~alpha1~git201310081734-squeeze0_all.deb 
(Reading database ... 39816 files and directories currently installed.)
Preparing to replace rudder-server-root 2.6.8~rc1~git201310081219-squeeze0 (using .../rudder-server-root_2.8.0~alpha1~git201310081734-squeeze0_all.deb) ...
Unpacking replacement rudder-server-root ...
Setting up rudder-server-root (2.8.0~alpha1~git201310081734-squeeze0) ...
Installing new version of config file /etc/init.d/rudder-server-root ...
root@server:~# 
root@server:~# 
root@server:~# dpkg -L rudder-server-root
[...]
/etc/init.d/rudder-server-root
/etc/logrotate.d
/etc/logrotate.d/rudder

@@ -0,0 +1,40 @@
#!/bin/sh
# postrm script for normation-openldap-framework
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"normation-openldap-framework"??? What on earth is this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm...I don't know. I just made a copy of the examples files into the same folder. It seems that these files need to be removed or cleaned at least.

@jooooooon
Copy link
Member

The post you quoted to do this (http://raphaelhertzog.com/2010/10/14/correctly-renaming-a-conffile-in-debian-package-maintainer-scripts/) mentions:

You can avoid the preliminary test if you pre-depend on “dpkg (>= 1.15.7.2)”

I'm assuming that this won't work on older OSes, am I right? From which version of Debian is this OK? Please add a comment in the code to clarify.

@nperron
Copy link
Contributor Author

nperron commented Oct 8, 2013

I'm assuming that this won't work on older OSes, am I right? From which version of Debian is this OK? Please add a comment in the code to clarify.

Argg....you're right. I've tested on squeeze which version is:

$ dpkg --version
Debian `dpkg' package management program version 1.15.8.13 (amd64).
This is free software; see the GNU General Public License version 2 or
later for copying conditions. There is NO warranty

But on Lenny, it could not work:

# dpkg --version
Debian `dpkg' package management program version 1.14.31 (amd64).
This is free software; see the GNU General Public License version 2 or
later for copying conditions. There is NO warranty.
See dpkg --license for copyright and license details.

@nperron
Copy link
Contributor Author

nperron commented Oct 8, 2013

But on Lenny, it could not work:

It will not work:

…ver-root to /etc/logrotate.d/rudder in Debian way
@nperron
Copy link
Contributor Author

nperron commented Oct 8, 2013

Validated by Jon

nperron pushed a commit that referenced this pull request Oct 8, 2013
…nffile_of_logrotate

Fixes #4026 - Move the configuration file /etc/logrotate.d/rudder-server-root to /etc/logrotate.d/rudder in Debian way
@nperron nperron merged commit 1ef6731 into Normation:branches/rudder/2.4 Oct 8, 2013
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants