]> git.ipfire.org Git - ipfire-3.x.git/blob - quota/patches/quota-4.01-warnquota.patch
git: Update to 2.23.0
[ipfire-3.x.git] / quota / patches / quota-4.01-warnquota.patch
1 From d2f7a6be1526a6f46cbf37aa27587a51e4d5990f Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
3 Date: Tue, 23 Aug 2011 13:45:15 +0200
4 Subject: [PATCH] warnquota configuration tunes
5
6 Rest of changes (378a64006bb1e818e84a1c77808563b802b028fa) not
7 accepted by upstream (we had root@... addresses and more enterprise
8 wordings usually there).
9 ---
10 warnquota.c | 2 +-
11 warnquota.conf | 17 ++++++++---------
12 2 files changed, 9 insertions(+), 10 deletions(-)
13
14 diff --git a/warnquota.c b/warnquota.c
15 index 08827f2..c7ca6f2 100644
16 --- a/warnquota.c
17 +++ b/warnquota.c
18 @@ -806,7 +806,7 @@ static int readconfigfile(const char *filename, struct configparams *config)
19 verify_format(config->group_signature, "GROUP_SIGNATURE");
20 }
21 else if (!strcmp(var, "LDAP_MAIL")) {
22 - if(strcasecmp(value, "true") == 0)
23 + if(strncasecmp(value, "true", 4) == 0)
24 config->use_ldap_mail = 1;
25 else
26 config->use_ldap_mail = 0;
27 diff --git a/warnquota.conf b/warnquota.conf
28 index 2a72b78..77f6a75 100644
29 --- a/warnquota.conf
30 +++ b/warnquota.conf
31 @@ -4,17 +4,16 @@
32 # and even blank lines
33
34 # values can be quoted:
35 -#MAIL_CMD = "/usr/my/sendmail/instead/sendmail -t"
36 -MAIL_CMD = "/bin/echo"
37 -FROM = "bas@example.com"
38 +MAIL_CMD = "/usr/sbin/sendmail -t"
39 +FROM = "root@example.com"
40 # but they don't have to be:
41 -SUBJECT = Hey, user, clean up your account!
42 -CC_TO = "sysadm@example.com"
43 +SUBJECT = NOTE: You are exceeding your allocated disk space limits
44 +CC_TO = "root@example.com"
45 # If you set this variable CC will be used only when user has less than
46 # specified grace time left (examples of possible times: 5 seconds, 1 minute,
47 # 12 hours, 5 days)
48 # CC_BEFORE = 2 days
49 -SUPPORT = "support@example.com"
50 +SUPPORT = "root@example.com"
51 PHONE = "(123) 456-1111 or (222) 333-4444"
52 # Text in the beginning of the mail (if not specified, default text is used)
53 # This way text can be split to more lines
54 @@ -22,11 +21,11 @@ PHONE = "(123) 456-1111 or (222) 333-4444"
55 # The expressions %i, %h, %d, and %% are substituted for user/group name,
56 # host name, domain name, and '%' respectively. For backward compatibility
57 # %s behaves as %i but is deprecated.
58 -MESSAGE = Hello user %i, I've noticed you use too much space\
59 - on my disk in %h.%d.|Delete your files on the following filesystems:|
60 +MESSAGE = Your disk usage has exceeded the agreed limits\
61 + on this server|Please delete any unnecessary files on following filesystems:|
62 # Text in the end of the mail (if not specified, default text using SUPPORT and PHONE
63 # is created)
64 -SIGNATURE = See you!| Your admin of %h|
65 +SIGNATURE = root@example.com
66 # Following text is used for mails about group exceeding quotas
67 GROUP_MESSAGE = Hello, a group '%i' you're member of use too much space at %h.|\
68 I chose you to do the cleanup.|Delete group files on the following filesystems:|
69 --
70 1.7.11.4
71