Fail2ban fxd.
This commit is contained in:
parent
4d5411d5fc
commit
b1cc8e35c6
|
@ -42,7 +42,6 @@ src_prepare() {
|
||||||
# Fix bashisms and do not direct useful output to /dev/null (bug #536320)
|
# Fix bashisms and do not direct useful output to /dev/null (bug #536320)
|
||||||
# Remove global logrotate settings (bug #549856)
|
# Remove global logrotate settings (bug #549856)
|
||||||
epatch \
|
epatch \
|
||||||
"${FILESDIR}"/${PN}-0.9.2-initd.patch \
|
|
||||||
"${FILESDIR}"/${PN}-0.9.2-logrotate.patch
|
"${FILESDIR}"/${PN}-0.9.2-logrotate.patch
|
||||||
|
|
||||||
distutils-r1_src_prepare
|
distutils-r1_src_prepare
|
||||||
|
|
|
@ -1,25 +0,0 @@
|
||||||
--- a/files/gentoo-initd
|
|
||||||
+++ b/files/gentoo-initd
|
|
||||||
@@ -38,19 +38,19 @@
|
|
||||||
# bug 347477
|
|
||||||
rm -rf /run/fail2ban/fail2ban.sock || return 1
|
|
||||||
fi
|
|
||||||
- ${FAIL2BAN} start &> /dev/null
|
|
||||||
+ ${FAIL2BAN} start
|
|
||||||
eend $? "Failed to start fail2ban"
|
|
||||||
}
|
|
||||||
|
|
||||||
stop() {
|
|
||||||
ebegin "Stopping fail2ban"
|
|
||||||
- ${FAIL2BAN} stop &> /dev/null
|
|
||||||
+ ${FAIL2BAN} stop
|
|
||||||
eend $? "Failed to stop fail2ban"
|
|
||||||
}
|
|
||||||
|
|
||||||
reload() {
|
|
||||||
ebegin "Reloading fail2ban"
|
|
||||||
- ${FAIL2BAN} reload > /dev/null
|
|
||||||
+ ${FAIL2BAN} reload
|
|
||||||
eend $? "Failed to reload fail2ban"
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
--- a/files/fail2ban-logrotate
|
--- a/files/fail2ban-logrotate
|
||||||
+++ b/files/fail2ban-logrotate
|
+++ b/files/fail2ban-logrotate
|
||||||
@@ -9,9 +9,7 @@
|
@@ -6,10 +6,8 @@
|
||||||
# http://pkgs.fedoraproject.org/cgit/fail2ban.git/tree/fail2ban-logrotate
|
# https://github.com/fail2ban/fail2ban/blob/debian/debian/fail2ban.logrotate
|
||||||
|
|
||||||
/var/log/fail2ban.log {
|
/var/log/fail2ban.log {
|
||||||
- rotate 7
|
- rotate 7
|
||||||
|
@ -10,3 +10,4 @@
|
||||||
- compress
|
- compress
|
||||||
postrotate
|
postrotate
|
||||||
/usr/bin/fail2ban-client flushlogs 1>/dev/null || true
|
/usr/bin/fail2ban-client flushlogs 1>/dev/null || true
|
||||||
|
endscript
|
||||||
|
|
Loading…
Reference in New Issue