aboutsummaryrefslogtreecommitdiffstats
path: root/www/tntnet/files/patch-etc
blob: 8e9d92f3debe451815627e2777e36c2b74161724 (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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
--- a/etc/Makefile.am
+++ b/etc/Makefile.am
@@ -1,31 +1,36 @@
 nobase_dist_noinst_DATA = \
     tntnet/tntnet.conf.in \
-    init.d/tntnet.in
+    init.d/tntnet.in \
+    tntnet/mime.conf
 
 nobase_sysconf_DATA = \
-    tntnet/tntnet.conf \
-    init.d/tntnet
+    tntnet/tntnet.conf.sample \
+    tntnet/tntnet
 
 nobase_dist_sysconf_DATA = \
-    tntnet/mime.conf
+    tntnet/mime.conf.sample
 
 nobase_nodist_sysconf_DATA = \
-    tntnet/tntnet.properties
+    tntnet/tntnet.properties.sample
+
+tntnet/mime.conf.sample: tntnet/mime.conf
+   cp tntnet/mime.conf $@
 
-tntnet/tntnet.conf: tntnet/tntnet.conf.in
+tntnet/tntnet.conf.sample: tntnet/tntnet.conf.in
    sed -e 's,@libdir\@,@libdir@,g;' \
        -e 's,@pkglibdir\@,@pkglibdir@,g;' \
        -e 's,@sysconfdir\@,@sysconfdir@,g;' \
        -e 's,@localstatedir\@,@localstatedir@,g;' \
-       -e 's,@datadir\@,@datadir@,g;' <tntnet/tntnet.conf.in >tntnet/tntnet.conf
+       -e 's,@datadir\@,@datadir@,g;' <tntnet/tntnet.conf.in >tntnet/tntnet.conf.sample
 
-init.d/tntnet: init.d/tntnet.in
+tntnet/tntnet: init.d/tntnet.in
    sed -e 's,@libdir\@,@libdir@,g;' \
        -e 's,@pkglibdir\@,@pkglibdir@,g;' \
        -e 's,@sysconfdir\@,@sysconfdir@,g;' \
        -e 's,@localstatedir\@,@localstatedir@,g;' \
-       -e 's,@datadir\@,@datadir@,g;' <init.d/tntnet.in >init.d/tntnet
+       -e 's/^function //;' \
+       -e 's,@datadir\@,@datadir@,g;' <init.d/tntnet.in >tntnet/tntnet
 
-tntnet/tntnet.properties:
+tntnet/tntnet.properties.sample:
    ../tntnet-config --properties tntnet | \
        sed -e 's,^#file=tntnet.log,file=@localstatedir@/log/tntnet/tntnet.log,' >$@
--- a/etc/Makefile.in
+++ b/etc/Makefile.in
@@ -206,17 +206,18 @@ top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 nobase_dist_noinst_DATA = \
     tntnet/tntnet.conf.in \
-    init.d/tntnet.in
+    init.d/tntnet.in \
+    tntnet/mime.conf
 
 nobase_sysconf_DATA = \
-    tntnet/tntnet.conf \
-    init.d/tntnet
+    tntnet/tntnet.conf.sample \
+    tntnet/tntnet
 
 nobase_dist_sysconf_DATA = \
-    tntnet/mime.conf
+    tntnet/mime.conf.sample
 
 nobase_nodist_sysconf_DATA = \
-    tntnet/tntnet.properties
+    tntnet/tntnet.properties.sample
 
 all: all-am
 
@@ -483,21 +484,25 @@ uninstall-am: uninstall-nobase_dist_sysc
    uninstall-nobase_sysconfDATA
 
 
-tntnet/tntnet.conf: tntnet/tntnet.conf.in
+tntnet/mime.conf.sample: tntnet/mime.conf
+   cp tntnet/mime.conf $@
+
+tntnet/tntnet.conf.sample: tntnet/tntnet.conf.in
    sed -e 's,@libdir\@,@libdir@,g;' \
        -e 's,@pkglibdir\@,@pkglibdir@,g;' \
        -e 's,@sysconfdir\@,@sysconfdir@,g;' \
        -e 's,@localstatedir\@,@localstatedir@,g;' \
-       -e 's,@datadir\@,@datadir@,g;' <tntnet/tntnet.conf.in >tntnet/tntnet.conf
+       -e 's,@datadir\@,@datadir@,g;' <tntnet/tntnet.conf.in >tntnet/tntnet.conf.sample
 
-init.d/tntnet: init.d/tntnet.in
+tntnet/tntnet: init.d/tntnet.in
    sed -e 's,@libdir\@,@libdir@,g;' \
        -e 's,@pkglibdir\@,@pkglibdir@,g;' \
        -e 's,@sysconfdir\@,@sysconfdir@,g;' \
        -e 's,@localstatedir\@,@localstatedir@,g;' \
-       -e 's,@datadir\@,@datadir@,g;' <init.d/tntnet.in >init.d/tntnet
+       -e 's/^function //;' \
+       -e 's,@datadir\@,@datadir@,g;' <init.d/tntnet.in >tntnet/tntnet
 
-tntnet/tntnet.properties:
+tntnet/tntnet.properties.sample:
    ../tntnet-config --properties tntnet | \
        sed -e 's,^#file=tntnet.log,file=@localstatedir@/log/tntnet/tntnet.log,' >$@
 
--- a/etc/tntnet/tntnet.conf.in
+++ b/etc/tntnet/tntnet.conf.in
@@ -2,12 +2,15 @@
 #
 
 PropertyFile   @sysconfdir@/tntnet/tntnet.properties
-Listen     0.0.0.0 80
+#Listen        0.0.0.0 80
+Listen     127.1 80
 #SslListen  0.0.0.0 443 @sysconfdir@/tntnet/tntnet.pem
 
 Daemon     1
-User       www-data
-Group      www-data
+#User      www-data
+#Group     www-data
+User       www
+Group      www
 CompPath    @libdir@/tntnet
 
 # set some limit to prevent DoS-attacks