]> git.pld-linux.org Git - packages/maradns.git/blob - maradns.spec
- removed all Group fields translations (oure rpm now can handle translating
[packages/maradns.git] / maradns.spec
1 Summary:        A (currently) authoritative-only DNS server made with security in mind
2 Summary(pl):    Tylko autorytatywny (na razie) serwer DNS zrobiony z my¶l± o bezpieczeñstwie
3 Name:           maradns
4 Version:        0.8.35
5 Release:        2
6 License:        Public domain
7 Group:          Networking/Daemons
8 Source0:        http://www.maradns.org/download/%{name}-%{version}.tar.bz2
9 Source1:        %{name}.init
10 Source2:        zoneserver.init
11 Source3:        mararc
12 Prereq:         /sbin/chkconfig
13 Prereq:         fileutils
14 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
15 Conflicts:      bind
16 Conflicts:      djbdns
17
18 %description
19 MaraDNS is (currently) an authoritative-only DNS server made with
20 security in mind.
21
22 %description -l pl
23 MaraDNS jest (na razie) tylko autorytatywnym serwerem DNS zrobionym z
24 my¶l± o bezpieczeñstwie.
25
26 %package zoneserver
27 Summary:        Handle zone transfers for MaraDNS
28 Summary(pl):    Obs³uga transferów stref dla MaraDNS
29 Group:          Networking/Daemons
30 Requires:       maradns = %{version}
31 Prereq:         /sbin/chkconfig
32 Prereq:         fileutils
33
34 %description zoneserver
35 zoneserver listens on port 53/tcp and handles dns zone transfers.
36 zoneserver uses a configuration file, /etc/mararc by default, to
37 determine various parameters, such as the IP to bind to, who is
38 allowed to perform zone transfers, etc.
39
40 %description zoneserver -l pl
41 zoneserver s³ucha na porcie 53/tcp i obs³uguje transfery stref DNS.
42 U¿ywa domy¶lnie pliku konfiguracyjnego /etc/mararc aby uzyskaæ
43 parametry takie jak na jakim adresie ma s³uchaæ, kto mo¿e robiæ
44 transfery stref itp.
45
46 %prep
47 %setup -q 
48
49 %build
50 %{__make} \
51         CC=%{__cc} \
52         FLAGS="%{rpmcflags}"
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_bindir},%{_mandir}/man{1,5,8}} \
57         $RPM_BUILD_ROOT{%{_sysconfdir}/maradns,/etc/rc.d/init.d} \
58         $RPM_BUILD_ROOT%{_localstatedir}/log
59
60 install server/maradns tuzona/zoneserver tuzona/getzone $RPM_BUILD_ROOT%{_sbindir}
61 install tools/askmara $RPM_BUILD_ROOT%{_bindir}
62 install tools/benchmark $RPM_BUILD_ROOT%{_bindir}
63 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/maradns
64 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/zoneserver
65 install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/mararc
66 install doc/example_csv1 $RPM_BUILD_ROOT%{_sysconfdir}/maradns/db.example.com
67
68 > $RPM_BUILD_ROOT%{_localstatedir}/log/maradns
69 > $RPM_BUILD_ROOT%{_localstatedir}/log/zoneserver
70
71 install doc/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1/
72 install doc/man/*.5 $RPM_BUILD_ROOT%{_mandir}/man5/
73 install doc/man/*.8 $RPM_BUILD_ROOT%{_mandir}/man8/
74
75 rm -rf doc/{man,detailed/man_macros}
76
77 gzip -9nf 0QuickStart TODO.* 00README.FIRST CREDITS \
78         `find doc -type f -a -not -name \*.html`
79
80 %clean
81 rm -rf $RPM_BUILD_ROOT
82
83 %pre
84 if ! id -g maradns > /dev/null 2>&1 ; then
85         %{_sbindir}/groupadd -g 58 maradns
86 fi
87 if ! id -u maradns > /dev/null 2>&1 ; then
88         %{_sbindir}/useradd -u 58 -g 58 -d /dev/null -s /bin/false -c "maraDNS user" maradns
89 fi
90
91 %post
92 /sbin/chkconfig --add maradns
93 if [ -f /var/lock/subsys/maradns ]; then
94         /etc/rc.d/init.d/maradns restart 1>&2
95 else
96         echo "Type \"/etc/rc.d/init.d/maradns start\" to start maradns" 1>&2
97 fi
98 touch %{_localstatedir}/log/maradns
99 chmod 640 %{_localstatedir}/log/maradns
100
101 %post zoneserver
102 /sbin/chkconfig --add zoneserver
103 if [ -f /var/lock/subsys/zoneserver ]; then
104         /etc/rc.d/init.d/zoneserver restart 1>&2
105 else
106         echo "Type \"/etc/rc.d/init.d/zoneserver start\" to start zoneserver" 1>&2
107 fi
108 touch %{_localstatedir}/log/zoneserver
109 chmod 640 %{_localstatedir}/log/zoneserver
110
111 %preun
112 if [ "$1" = "0" ]; then
113         if [ -f /var/lock/subsys/maradns ]; then
114                 /etc/rc.d/init.d/maradns stop 1>&2
115         fi
116         /sbin/chkconfig --del maradns
117 fi
118
119 %preun zoneserver
120 if [ "$1" = "0" ]; then
121         if [ -f /var/lock/subsys/zoneserver ]; then
122                 /etc/rc.d/init.d/zoneserver stop 1>&2
123         fi
124         /sbin/chkconfig --del zoneserver
125 fi
126
127 %postun
128 if [ "$1" = "0" ]; then
129         %{_sbindir}/userdel maradns
130         %{_sbindir}/groupdel maradns
131 fi
132
133 %files
134 %defattr(644,root,root,755)
135 %doc *.gz doc changelog.html
136
137 %attr(754,root,root) /etc/rc.d/init.d/maradns
138 %attr(755,root,root) %{_sbindir}/getzone
139 %attr(755,root,root) %{_sbindir}/maradns
140 %attr(755,root,root) %{_bindir}/*
141 %attr(0640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mararc
142 %attr(0640,root,root) %config %verify(not size mtime md5) %{_sysconfdir}/maradns/db.example.com
143 %attr(0640,root,root) %ghost %{_localstatedir}/log/maradns
144 %{_mandir}/man1/*
145 %{_mandir}/man5/*
146 %{_mandir}/man8/maradns*
147
148 %files zoneserver
149 %defattr(644,root,root,755)
150 %attr(754,root,root) /etc/rc.d/init.d/zoneserver
151 %attr(755,root,root) %{_sbindir}/zoneserver
152 %attr(640,root,root) %ghost %{_localstatedir}/log/zoneserver
153 %{_mandir}/man8/zoneserver*
This page took 0.048084 seconds and 4 git commands to generate.