]>
Commit | Line | Data |
---|---|---|
a493773b | 1 | Summary: A (currently) authoritative-only DNS server made with security in mind |
88076dd0 | 2 | Summary(pl.UTF-8): Tylko autorytatywny (na razie) serwer DNS zrobiony z myślą o bezpieczeństwie |
a493773b | 3 | Name: maradns |
8f82cc4f MM |
4 | Version: 1.3.07.09 |
5 | Release: 0.1 | |
0c98cd76 | 6 | License: Public Domain |
a493773b | 7 | Group: Networking/Daemons |
8f82cc4f MM |
8 | Source0: http://www.maradns.org/download/1.3/%{version}/%{name}-%{version}.tar.bz2 |
9 | # Source0-md5: 1d221438fb4d9317263555262b9c652c | |
7f131a65 | 10 | Source1: %{name}.init |
d276b9d3 | 11 | Source2: zoneserver.init |
12 | Source3: mararc | |
b0a404a2 | 13 | Patch0: %{name}-default_uid.patch |
622c3f75 | 14 | URL: http://www.maradns.org/ |
d6a4b8ee | 15 | BuildRequires: rpmbuild(macros) >= 1.268 |
47534733 ER |
16 | Requires(post): fileutils |
17 | Requires(post,preun): /sbin/chkconfig | |
18 | Requires(postun): /usr/sbin/groupdel | |
19 | Requires(postun): /usr/sbin/userdel | |
1dab4293 | 20 | Requires(pre): /bin/id |
b0a404a2 | 21 | Requires(pre): /usr/bin/getgid |
1dab4293 | 22 | Requires(pre): /usr/sbin/groupadd |
b0a404a2 | 23 | Requires(pre): /usr/sbin/groupmod |
1dab4293 | 24 | Requires(pre): /usr/sbin/useradd |
b0a404a2 | 25 | Requires(pre): /usr/sbin/usermod |
47534733 | 26 | Requires: rc-scripts |
b0a404a2 | 27 | Provides: group(named) |
a9ec4311 | 28 | Provides: nameserver |
b0a404a2 | 29 | Provides: user(named) |
af89ec0b | 30 | Obsoletes: nameserver |
b0a404a2 | 31 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
a493773b | 32 | |
33 | %description | |
a493773b | 34 | MaraDNS is (currently) an authoritative-only DNS server made with |
35 | security in mind. | |
36 | ||
b42ae77d | 37 | %description -l pl.UTF-8 |
7d251ab2 | 38 | MaraDNS jest (na razie) tylko autorytatywnym serwerem DNS zrobionym z |
b42ae77d | 39 | myślą o bezpieczeństwie. |
7d251ab2 | 40 | |
00f09138 | 41 | %package zoneserver |
7d251ab2 | 42 | Summary: Handle zone transfers for MaraDNS |
88076dd0 | 43 | Summary(pl.UTF-8): Obsługa transferów stref dla MaraDNS |
00f09138 | 44 | Group: Networking/Daemons |
1dab4293 | 45 | Requires(post): fileutils |
47534733 | 46 | Requires(post,preun): /sbin/chkconfig |
1f2c89a7 | 47 | Requires: %{name} = %{version}-%{release} |
47534733 | 48 | Requires: rc-scripts |
00f09138 | 49 | |
50 | %description zoneserver | |
9433a235 | 51 | zoneserver listens on port 53/tcp and handles dns zone transfers. |
52 | zoneserver uses a configuration file, /etc/mararc by default, to | |
53 | determine various parameters, such as the IP to bind to, who is | |
54 | allowed to perform zone transfers, etc. | |
00f09138 | 55 | |
b42ae77d JR |
56 | %description zoneserver -l pl.UTF-8 |
57 | zoneserver słucha na porcie 53/tcp i obsługuje transfery stref DNS. | |
58 | Używa domyślnie pliku konfiguracyjnego /etc/mararc aby uzyskać | |
59 | parametry takie jak na jakim adresie ma słuchać, kto może robić | |
7d251ab2 JB |
60 | transfery stref itp. |
61 | ||
a493773b | 62 | %prep |
ad6f3c2f | 63 | %setup -q |
8f82cc4f | 64 | #%patch0 -p1 |
1f2c89a7 | 65 | |
a493773b | 66 | %build |
9433a235 | 67 | %{__make} \ |
61476c65 | 68 | CC="%{__cc}" \ |
9433a235 | 69 | FLAGS="%{rpmcflags}" |
a493773b | 70 | |
71 | %install | |
72 | rm -rf $RPM_BUILD_ROOT | |
8f82cc4f | 73 | install -d $RPM_BUILD_ROOT{%{_sbindir},%{_bindir},%{_mandir}/man{1,5,8}} \ |
9433a235 | 74 | $RPM_BUILD_ROOT{%{_sysconfdir}/maradns,/etc/rc.d/init.d} \ |
00f09138 | 75 | $RPM_BUILD_ROOT%{_localstatedir}/log |
9433a235 | 76 | |
685edb0a | 77 | install server/maradns tcp/zoneserver tcp/getzone $RPM_BUILD_ROOT%{_sbindir} |
a493773b | 78 | install tools/askmara $RPM_BUILD_ROOT%{_bindir} |
bc66ed76 | 79 | install tools/benchmark $RPM_BUILD_ROOT%{_bindir} |
9433a235 | 80 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/maradns |
81 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/zoneserver | |
72f7580e | 82 | install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/mararc |
685edb0a | 83 | install doc/en/examples/example_csv1 $RPM_BUILD_ROOT%{_sysconfdir}/maradns/db.example.com |
00f09138 | 84 | |
9433a235 | 85 | > $RPM_BUILD_ROOT%{_localstatedir}/log/maradns |
86 | > $RPM_BUILD_ROOT%{_localstatedir}/log/zoneserver | |
87 | ||
1dab4293 JB |
88 | install doc/en/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1 |
89 | install doc/en/man/*.5 $RPM_BUILD_ROOT%{_mandir}/man5 | |
90 | install doc/en/man/*.8 $RPM_BUILD_ROOT%{_mandir}/man8 | |
9433a235 | 91 | |
a493773b | 92 | %clean |
93 | rm -rf $RPM_BUILD_ROOT | |
94 | ||
7f131a65 | 95 | %pre |
ab71e0a9 | 96 | %groupadd -g 58 named |
b0684b8d | 97 | if [ "`/bin/id -u maradns 2>/dev/null`" = "58" ]; then |
ab71e0a9 | 98 | /usr/sbin/usermod -d /tmp -l named maradns |
7f131a65 | 99 | fi |
ab71e0a9 | 100 | %useradd -u 58 -g 58 -d /tmp -s /bin/false -c "maraDNS user" named |
7f131a65 | 101 | |
102 | %post | |
103 | /sbin/chkconfig --add maradns | |
d6a4b8ee | 104 | %service maradns restart |
9433a235 | 105 | touch %{_localstatedir}/log/maradns |
106 | chmod 640 %{_localstatedir}/log/maradns | |
00f09138 | 107 | |
1dab4293 JB |
108 | %postun |
109 | if [ "$1" = "0" ]; then | |
b0a404a2 | 110 | %userremove named |
111 | %groupremove named | |
1dab4293 JB |
112 | fi |
113 | ||
00f09138 | 114 | %post zoneserver |
115 | /sbin/chkconfig --add zoneserver | |
d6a4b8ee | 116 | %service zoneserver restart |
9433a235 | 117 | touch %{_localstatedir}/log/zoneserver |
118 | chmod 640 %{_localstatedir}/log/zoneserver | |
7f131a65 | 119 | |
120 | %preun | |
121 | if [ "$1" = "0" ]; then | |
d6a4b8ee | 122 | %service maradns stop |
a9ec4311 | 123 | /sbin/chkconfig --del maradns |
00f09138 | 124 | fi |
125 | ||
126 | %preun zoneserver | |
127 | if [ "$1" = "0" ]; then | |
d6a4b8ee | 128 | %service zoneserver stop |
a9ec4311 | 129 | /sbin/chkconfig --del zoneserver |
7f131a65 | 130 | fi |
131 | ||
a493773b | 132 | %files |
133 | %defattr(644,root,root,755) | |
e85adb1a | 134 | %doc 0QuickStart 00README.FIRST CREDITS CHANGELOG doc/{README,en} |
00f09138 | 135 | %attr(754,root,root) /etc/rc.d/init.d/maradns |
136 | %attr(755,root,root) %{_sbindir}/getzone | |
137 | %attr(755,root,root) %{_sbindir}/maradns | |
a493773b | 138 | %attr(755,root,root) %{_bindir}/* |
622c3f75 | 139 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mararc |
f323a461 | 140 | %dir %{_sysconfdir}/maradns |
622c3f75 | 141 | %attr(640,root,root) %config %verify(not md5 mtime size) %{_sysconfdir}/maradns/db.example.com |
1f2c89a7 | 142 | %attr(640,root,root) %ghost %{_localstatedir}/log/maradns |
00f09138 | 143 | %{_mandir}/man1/* |
144 | %{_mandir}/man5/* | |
145 | %{_mandir}/man8/maradns* | |
40a03a7d | 146 | %{_mandir}/man8/duende* |
00f09138 | 147 | |
148 | %files zoneserver | |
9433a235 | 149 | %defattr(644,root,root,755) |
00f09138 | 150 | %attr(754,root,root) /etc/rc.d/init.d/zoneserver |
151 | %attr(755,root,root) %{_sbindir}/zoneserver | |
9433a235 | 152 | %attr(640,root,root) %ghost %{_localstatedir}/log/zoneserver |
00f09138 | 153 | %{_mandir}/man8/zoneserver* |