blob: 5c54d21287d8a96c43da8ee29495106b5408963b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
Index: tools/mkimap
diff -u tools/mkimap.orig tools/mkimap
--- tools/mkimap.orig Mon Mar 10 03:39:36 2003
+++ tools/mkimap Fri Mar 21 17:24:10 2003
@@ -61,6 +61,9 @@
$imapdconf = shift || "/etc/imapd.conf";
+$cyrus_user = $ENV{CYRUS_USER} || "%%CYRUS_USER%%";
+$cyrus_group = $ENV{CYRUS_GROUP} || "%%CYRUS_GROUP%%";
+
open CONF, $imapdconf or die "can't open $imapdconf";
print "reading configure file...\n";
while (<CONF>) {
@@ -86,6 +89,7 @@
print "configuring $d...\n";
+mkdir $d, 0755;
chdir $d or die "couldn't change to $d";
mkdir "proc", 0755;
@@ -95,11 +99,14 @@
mkdir "msg", 0755;
mkdir "ptclient", 0755;
+system "/usr/sbin/chown -R $cyrus_user:$cyrus_group .";
+
while ($part = shift @parts) {
print "creating $part...\n";
mkdir $part, 0755;
chdir $part or die "couldn't change to partition $part";
mkdir "stage.", 0755;
+ system "/usr/sbin/chown -R $cyrus_user:$cyrus_group $part";
}
print "done\n";
|