]> git.pld-linux.org Git - packages/nginx.git/blob - nginx.spec
- working on
[packages/nginx.git] / nginx.spec
1 # TODO
2 # - /etc/sysconfig/nginx file
3 # - missing perl build/install requires
4 # - prepare pld style like nginx.conf
5 # - split into nginx-common, nginx, nginx-perl packages
6 #
7 # Conditional build for nginx:
8 %bcond_without  light           # don't build light version
9 %bcond_without  mail            # don't build imap/mail proxy
10 %bcond_without  perl            # don't build with perl module
11 %bcond_without  addition        # adds module
12 %bcond_without  dav             # WebDAV
13 %bcond_without  flv             # FLV stream
14 %bcond_without  poll            # poll
15 %bcond_without  realip          # real ip (behind proxy)
16 %bcond_without  rtsig           # rtsig
17 %bcond_without  select          # select
18 %bcond_without  status          # stats module
19 %bcond_without  ssl             # ssl support
20 %bcond_with     http_browser    # header "User-agent" parser
21 #
22 Summary:        High perfomance HTTP and reverse proxy server
23 Summary(pl.UTF-8):      Serwer HTTP i odwrotne proxy o wysokiej wydajności
24 Name:           nginx
25 Version:        0.5.33
26 Release:        0.2
27 License:        BSD-like
28 Group:          Networking/Daemons
29 Source0:        http://sysoev.ru/nginx/%{name}-%{version}.tar.gz
30 # Source0-md5:  a78be74b4fd8e009545ef02488fcac86
31 Source1:        %{name}.init
32 Source2:        %{name}-mime.types.sh
33 Source3:        http://www.nginx.eu/favicon.ico
34 # Source3-md5:  2aaf2115c752cbdbfb8a2f0b3c3189ab
35 Source4:        http://www.nginx.eu/download/proxy.conf
36 # Source4-md5:  f5263ae01c2edb18f46d5d1df2d3a5cd
37 Source5:        http://www.nginx.eu/download/%{name}.monitrc
38 # Source5-md5:  1d3f5eedfd34fe95213f9e0fc19daa88
39 Source6:        http://www.nginx.eu/download/%{name}.conf
40 # Source6-md5:  1c112d6f03d0f365e4acc98c1d96261a
41 Source7:        %{name}.logrotate
42 Patch0:         %{name}-config.patch
43 URL:            http://nginx.net/
44 BuildRequires:  mailcap
45 BuildRequires:  openssl-devel
46 BuildRequires:  pcre-devel
47 %{?with_perl:BuildRequires: perl-CGI}
48 %{?with_perl:BuildRequires: perl-devel}
49 %{?with_perl:BuildRequires: rpm-perlprov}
50 BuildRequires:  rpmbuild(macros) >= 1.268
51 BuildRequires:  zlib-devel
52 Requires(post,preun):   /sbin/chkconfig
53 Requires(postun):       /usr/sbin/groupdel
54 Requires(postun):       /usr/sbin/userdel
55 Requires(pre):  /bin/id
56 Requires(pre):  /usr/bin/getgid
57 Requires(pre):  /usr/sbin/groupadd
58 Requires(pre):  /usr/sbin/useradd
59 Requires:       %{name}-common = %{version}-%{release}
60 Requires:       openssl
61 Requires:       pcre
62 Requires:       rc-scripts >= 0.2.0
63 Requires:       zlib
64 Provides:       group(http)
65 Provides:       group(nginx)
66 Provides:       user(nginx)
67 Provides:       webserver
68 Conflicts:      logrotate < 3.7-4
69 Conflicts:      %{name}-light
70 Conflicts:      %{name}-mail
71 Conflicts:      %{name}-perl
72 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
73
74 %define         _sysconfdir     /etc/%{name}
75 %define         _nginxdir       /home/services/%{name}
76
77 %description
78 Nginx ("engine x") is a high-performance HTTP server and reverse
79 proxy, as well as an IMAP/POP3 proxy server. Nginx was written by Igor
80 Sysoev for Rambler.ru, Russia's second-most visited website, where it
81 has been running in production for over two and a half years. Igor has
82 released the source code under a BSD-like license. Although still in
83 beta, Nginx is known for its stability, rich feature set, simple
84 configuration, and low resource consumption.
85
86 This is standard nginx version, without perl support and imap, pop3,
87 smtp proxy.
88
89 %description -l pl.UTF-8
90 Nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
91 a także IMAP/POP3 proxy. Nginx został napisany przez Igora Sysoev'a
92 na potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
93 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
94 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle
95 w fazie beta, już zasÅynÄÅ dzieki stabilnoÅi, bogactwu dodatków,
96 prostej konfiguracji oraz maÅej "zasobożernoÅi".
97
98 To jest standardowa wersja nginx, bez obs³ugi perla oraz proxy dla
99 imap, pop3, smtp.
100
101 %package light
102 Summary:        High perfomance HTTP and reverse proxy server
103 Summary(pl.UTF-8):      Serwer HTTP i odwrotne proxy o wysokiej wydajno�~[ci
104 License:        BSD-like
105 Group:          Networking/Daemons
106 URL:            http://nginx.net/
107 Requires(post,preun):   /sbin/chkconfig
108 Requires(postun):       /usr/sbin/groupdel
109 Requires(postun):       /usr/sbin/userdel
110 Requires:       %{name}-common = %{version}-%{release}
111 Requires:       openssl
112 Requires:       pcre
113 Requires:       zlib
114 Provides:       group(http)
115 Provides:       group(nginx)
116 Provides:       user(nginx)
117 Provides:       webserver
118 Conflicts:      %{name}
119 Conflicts:      %{name}-mail
120 Conflicts:      %{name}-perl
121
122 %description light
123 Nginx ("engine x") is a high-performance HTTP server and reverse
124 proxy, as well as an IMAP/POP3 proxy server. Nginx was written by Igor
125 Sysoev for Rambler.ru, Russia's second-most visited website, where it
126 has been running in production for over two and a half years. Igor has
127 released the source code under a BSD-like license. Although still in
128 beta, Nginx is known for its stability, rich feature set, simple
129 configuration, and low resource consumption.
130
131 The smallest, but also the fastest nginx edition. No additional
132 modules, no perl, no dav, no flv, no imap, pop3, smtp proxy.
133
134 %description light -l pl.UTF-8
135 Nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
136 a także IMAP/POP3 proxy. Nginx zostaÅ<82> napisany przez Igora Sysoev'a
137 na potrzeby serwisu Rambler.ru. Jest to drugi pod wzglÄ<99>dem iloÅ<9B>ci
138 odwiedzin serwis w Rosji i dziaÅ<82>a od ponad dwóch i póÅ<82> roku. Igor
139 opublikowaÅ<82> ÅºródÅ<82>a na licencji BSD. Mimo, Å¼e projekt jest ciÄ<85>gle
140 w fazie beta, już zasÅynÄÅ dzieki stabilnoÅi, bogactwu dodatków,
141 prostej konfiguracji oraz maÅej "zasobożernoÅi".
142
143 Najmniejsza i najszybsza wersja nginx. Bez wsparcia dla perla,
144 dav, flv oraz imap, pop3, smtp proxy.
145
146 %package perl
147 Summary:        High perfomance HTTP and reverse proxy server
148 Summary(pl.UTF-8):      Serwer HTTP i odwrotne proxy o wysokiej wydajno�~[ci
149 License:        BSD-like
150 Group:          Networking/Daemons
151 URL:            http://nginx.net/
152 Requires(post,preun):   /sbin/chkconfig
153 Requires(postun):       /usr/sbin/groupdel
154 Requires(postun):       /usr/sbin/userdel
155 Requires:       %{name}-common = %{version}-%{release}
156 Requires:       openssl
157 Requires:       perl-mod_%{mod_name} = %{epoch}:%{version}-%{release}
158 Provides:       group(http)
159 Provides:       group(nginx)
160 Provides:       user(nginx)
161 Provides:       webserver
162 Conflicts:      %{name}
163 Conflicts:      %{name}-light
164 Conflicts:      %{name}-mail
165
166 %description perl
167 Nginx ("engine x") is a high-performance HTTP server and reverse
168 proxy, as well as an IMAP/POP3 proxy server. Nginx was written by Igor
169 Sysoev for Rambler.ru, Russia's second-most visited website, where it
170 has been running in production for over two and a half years. Igor has
171 released the source code under a BSD-like license. Although still in
172 beta, Nginx is known for its stability, rich feature set, simple
173 configuration, and low resource consumption.
174
175 Nginx with perl support. Mail modules not included.
176
177 %description perl -l pl.UTF-8
178 Nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
179 a także IMAP/POP3 proxy. Nginx zostaÅ<82> napisany przez Igora Sysoev'a
180 na potrzeby serwisu Rambler.ru. Jest to drugi pod wzglÄ<99>dem iloÅ<9B>ci
181 odwiedzin serwis w Rosji i dziaÅ<82>a od ponad dwóch i póÅ<82> roku. Igor
182 opublikowaÅ<82> ÅºródÅ<82>a na licencji BSD. Mimo, Å¼e projekt jest ciÄ<85>gle
183 w fazie beta, już zasÅynÄÅ dzieki stabilnoÅi, bogactwu dodatków,
184 prostej konfiguracji oraz maÅej "zasobożernoÅi".
185
186 Nginx z obsluga perla. Bez wsparcia dla modulow poczty.
187
188 %package mail
189 Summary:        High perfomance HTTP and reverse proxy server
190 Summary(pl.UTF-8):      Serwer HTTP i odwrotne proxy o wysokiej wydajno�~[ci
191 License:        BSD-like
192 Group:          Networking/Daemons
193 URL:            http://nginx.net/
194 Requires(post,preun):   /sbin/chkconfig
195 Requires(postun):       /usr/sbin/groupdel
196 Requires(postun):       /usr/sbin/userdel
197 Requires:       %{name}-common = %{version}-%{release}
198 Requires:       openssl
199 Requires:       pcre
200 Requires:       zlib
201 Provides:       group(http)
202 Provides:       group(nginx)
203 Provides:       user(nginx)
204 Provides:       webserver
205 Conflicts:      %{name}
206 Conflicts:      %{name}-light
207 Conflicts:      %{name}-perl
208
209 %description mail
210 Nginx ("engine x") is a high-performance HTTP server and reverse
211 proxy, as well as an IMAP/POP3 proxy server. Nginx was written by Igor
212 Sysoev for Rambler.ru, Russia's second-most visited website, where it
213 has been running in production for over two and a half years. Igor has
214 released the source code under a BSD-like license. Although still in
215 beta, Nginx is known for its stability, rich feature set, simple
216 configuration, and low resource consumption.
217
218 Nginx with mail support. Only mail modules included.
219
220 %description mail -l pl.UTF-8
221 Nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
222 a także IMAP/POP3 proxy. Nginx zostaÅ<82> napisany przez Igora Sysoev'a
223 na potrzeby serwisu Rambler.ru. Jest to drugi pod wzglÄ<99>dem iloÅ<9B>ci
224 odwiedzin serwis w Rosji i dziaÅ<82>a od ponad dwóch i póÅ<82> roku. Igor
225 opublikowaÅ<82> ÅºródÅ<82>a na licencji BSD. Mimo, Å¼e projekt jest ciÄ<85>gle
226 w fazie beta, już zasÅynÄÅ dzieki stabilnoÅi, bogactwu dodatków,
227 prostej konfiguracji oraz maÅej "zasobożernoÅi".
228
229 Nginx ze wsparciem tylko dla modulow poczty.
230
231
232 %package common
233 Summary:        Configuration files and documentation for Nginx
234 Summary(pl.UTF-8):      Pliki konfiguracyjne i dokumentacja dla Nginx
235 Group:          Networking/Daemons
236
237 %description common
238 Nginx ("engine x") is a high-performance HTTP server and reverse
239 proxy, as well as an IMAP/POP3 proxy server. Nginx was written by Igor
240 Sysoev for Rambler.ru, Russia's second-most visited website, where it
241 has been running in production for over two and a half years. Igor has
242 released the source code under a BSD-like license. Although still in
243 beta, Nginx is known for its stability, rich feature set, simple
244 configuration, and low resource consumption.
245
246 Common files for nginx daemon.
247
248 %description common -l pl.UTF-8
249 Nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
250 a także IMAP/POP3 proxy. Nginx zostaÅ<82> napisany przez Igora Sysoev'a
251 na potrzeby serwisu Rambler.ru. Jest to drugi pod wzglÄ<99>dem iloÅ<9B>ci
252 odwiedzin serwis w Rosji i dziaÅ<82>a od ponad dwóch i póÅ<82> roku. Igor
253 opublikowaÅ<82> ÅºródÅ<82>a na licencji BSD. Mimo, Å¼e projekt jest ciÄ<85>gle
254 w fazie beta, już zasÅynÄÅ dzieki stabilnoÅi, bogactwu dodatków,
255 prostej konfiguracji oraz maÅej "zasobożernoÅi".
256
257 Niezbedne pliki dla nginx.
258
259 %package -n monit-rc-nginx
260 Summary:        Nginx  support for monit
261 Summary(pl.UTF-8):      Wsparcie nginx dla monit
262 License:        BSD-like
263 Group:          Applications/System
264 URL:            http://nginx.eu/
265 Requires:       %{name} = %{version}-%{release}
266 Requires:       monit
267
268 %description -n monit-rc-nginx
269 monitrc file for monitoring nginx webserver server.
270
271 %description -n monit-rc-nginx -l pl.UTF-8
272 Plik monitrc do monitorowania serwera www nginx.
273
274
275 %prep
276 %setup -q
277 %patch0 -p0
278
279 # build mime.types.conf
280 sh %{SOURCE2} /etc/mime.types
281
282 %build
283 # NB: not autoconf generated configure
284 cp -f configure auto/
285 #
286 %if %{with perl}
287 ./configure \
288         --prefix=%{_prefix} \
289         --sbin-path=%{_sbindir}/%{name} \
290         --conf-path=%{_sysconfdir}/%{name}.conf \
291         --error-log-path=%{_localstatedir}/log/%{name}/error.log \
292         --pid-path=%{_localstatedir}/run/%{name}.pid \
293         --lock-path=%{_localstatedir}/lock/subsys/%{name} \
294         --user=nginx \
295         --group=nginx \
296         --with-http_perl_module \
297         --without-mail_pop3_module \
298         --without-mail_imap_module \
299         --without-mail_smtp_module \
300         %{?with_addition:--with-http_addition_module} \
301         %{?with_dav:--with-http_dav_module} \
302         %{?with_flv:--with-http_flv_module} \
303         %{?with_poll:--with-poll_module} \
304         %{?with_realip:--with-http_realip_module} \
305         %{?with_rtsig:--with-rtsig_module} \
306         %{?with_select:--with-select_module} \
307         %{?with_status:--with-http_stub_status_module} \
308         %{?with_ssl:--with-http_ssl_module} \
309         %{!?with_http_browser:--without-http_browser_module} \
310         --http-log-path=%{_localstatedir}/log/%{name}/access.log \
311         --http-client-body-temp-path=%{_localstatedir}/cache/%{name}/client_body_temp \
312         --http-proxy-temp-path=%{_localstatedir}/cache/%{name}/proxy_temp \
313         --http-fastcgi-temp-path=%{_localstatedir}/cache/%{name}/fastcgi_temp \
314         --with-cc="%{__cc}" \
315         --with-cc-opt="%{rpmcflags}" \
316         --with-ld-opt="%{rpmldflags}"
317 %{__make}
318 mv -f objs/nginx contrib/nginx.perl
319 %endif
320
321 %if %{with mail}
322 %{__make} clean
323 ./configure \
324         --prefix=%{_prefix} \
325         --sbin-path=%{_sbindir}/%{name} \
326         --conf-path=%{_sysconfdir}/%{name}.conf \
327         --error-log-path=%{_localstatedir}/log/%{name}/error.log \
328         --pid-path=%{_localstatedir}/run/%{name}.pid \
329         --lock-path=%{_localstatedir}/lock/subsys/%{name} \
330         --user=nginx \
331         --group=nginx \
332         --with-imap \
333         --with-mail \
334         --with-mail_ssl_module \
335         %{?with_addition:--with-http_addition_module} \
336         %{?with_poll:--with-poll_module} \
337         %{?with_realip:--with-http_realip_module} \
338         %{?with_rtsig:--with-rtsig_module} \
339         %{?with_select:--with-select_module} \
340         %{!?with_http_browser:--without-http_browser_module} \
341         --http-log-path=%{_localstatedir}/log/%{name}/access.log \
342         --http-client-body-temp-path=%{_localstatedir}/cache/%{name}/client_body_temp \
343         --http-proxy-temp-path=%{_localstatedir}/cache/%{name}/proxy_temp \
344         --http-fastcgi-temp-path=%{_localstatedir}/cache/%{name}/fastcgi_temp \
345         --with-cc="%{__cc}" \
346         --with-cc-opt="%{rpmcflags}" \
347         --with-ld-opt="%{rpmldflags}" \
348         %{?debug:--with-debug}
349 %{__make}
350 mv -f objs/nginx contrib/nginx.mail
351 %endif
352
353 %if %{with light}
354 %{__make} clean
355 ./configure \
356         --prefix=%{_prefix} \
357         --sbin-path=%{_sbindir}/%{name} \
358         --conf-path=%{_sysconfdir}/%{name}.conf \
359         --error-log-path=%{_localstatedir}/log/%{name}/error.log \
360         --pid-path=%{_localstatedir}/run/%{name}.pid \
361         --lock-path=%{_localstatedir}/lock/subsys/%{name} \
362         --user=nginx \
363         --group=nginx \
364         %{?with_poll:--with-poll_module} \
365         %{?with_realip:--with-http_realip_module} \
366         %{?with_rtsig:--with-rtsig_module} \
367         %{?with_select:--with-select_module} \
368         %{?with_status:--with-http_stub_status_module} \
369         %{?with_ssl:--with-http_ssl_module} \
370         --without-http_browser_module \
371         --without-mail_pop3_module \
372         --without-mail_imap_module \
373         --without-mail_smtp_module \
374         --http-log-path=%{_localstatedir}/log/%{name}/access.log \
375         --http-client-body-temp-path=%{_localstatedir}/cache/%{name}/client_body_temp \
376         --http-proxy-temp-path=%{_localstatedir}/cache/%{name}/proxy_temp \
377         --http-fastcgi-temp-path=%{_localstatedir}/cache/%{name}/fastcgi_temp \
378         --with-cc="%{__cc}" \
379         --with-cc-opt="%{rpmcflags}" \
380         --with-ld-opt="%{rpmldflags}" \
381         %{?debug:--with-debug}
382 %{__make}
383 mv -f objs/nginx contrib/nginx.light
384 %endif
385
386 %{__make} clean
387 ./configure \
388         --prefix=%{_prefix} \
389         --sbin-path=%{_sbindir}/%{name} \
390         --conf-path=%{_sysconfdir}/%{name}.conf \
391         --error-log-path=%{_localstatedir}/log/%{name}/error.log \
392         --pid-path=%{_localstatedir}/run/%{name}.pid \
393         --lock-path=%{_localstatedir}/lock/subsys/%{name} \
394         --user=nginx \
395         --group=nginx \
396         %{?with_addition:--with-http_addition_module} \
397         %{?with_dav:--with-http_dav_module} \
398         %{?with_flv:--with-http_flv_module} \
399         %{?with_imap:--with-imap} \
400         %{?with_mail:--with-mail} \
401         %{?with_mail:--with-mail_ssl_module} \
402         %{?with_perl:--with-http_perl_module} \
403         %{?with_poll:--with-poll_module} \
404         %{?with_realip:--with-http_realip_module} \
405         %{?with_rtsig:--with-rtsig_module} \
406         %{?with_select:--with-select_module} \
407         %{?with_status:--with-http_stub_status_module} \
408         %{?with_ssl:--with-http_ssl_module} \
409         %{!?with_http_browser:--without-http_browser_module} \
410         --http-log-path=%{_localstatedir}/log/%{name}/access.log \
411         --http-client-body-temp-path=%{_localstatedir}/cache/%{name}/client_body_temp \
412         --http-proxy-temp-path=%{_localstatedir}/cache/%{name}/proxy_temp \
413         --http-fastcgi-temp-path=%{_localstatedir}/cache/%{name}/fastcgi_temp \
414         --with-cc="%{__cc}" \
415         --with-cc-opt="%{rpmcflags}" \
416         --with-ld-opt="%{rpmldflags}" \
417         %{?debug:--with-debug}
418 %{__make}
419
420
421 %install
422 rm -rf $RPM_BUILD_ROOT
423 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d \
424         $RPM_BUILD_ROOT%{_nginxdir}/{cgi-bin,html,errors} \
425         $RPM_BUILD_ROOT{%{_localstatedir}/log/{%{name},archive/%{name}},%{_localstatedir}/cache/%{name}} \
426         $RPM_BUILD_ROOT%{_localstatedir}/lock/subsys/%{name} \
427         $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir}} \
428         $RPM_BUILD_ROOT/etc/{logrotate.d,monit}
429
430 install conf/* $RPM_BUILD_ROOT%{_sysconfdir}
431 install mime.types $RPM_BUILD_ROOT%{_sysconfdir}/mime.types
432 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
433 install %{SOURCE3} $RPM_BUILD_ROOT%{_nginxdir}/html/favicon.ico
434 install html/index.html $RPM_BUILD_ROOT%{_nginxdir}/html
435 install html/50x.html $RPM_BUILD_ROOT%{_nginxdir}/errors
436 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/proxy.conf
437 install %{SOURCE5} $RPM_BUILD_ROOT/etc/monit/%{name}.monitrc
438 install %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/nginx.conf
439 install %{SOURCE7} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
440 install objs/%{name} $RPM_BUILD_ROOT%{_sbindir}/%{name}
441
442 %if %{with light}
443 install contrib/nginx.light $RPM_BUILD_ROOT%{_sbindir}/%{name}
444 %endif
445
446 %if %{with mail}
447 install contrib/nginx.mail $RPM_BUILD_ROOT%{_sbindir}/%{name}
448 %endif
449
450 %if %{with perl}
451 install -d $RPM_BUILD_ROOT{%{perl_vendorarch},%{perl_vendorarch}/auto/%{name}}
452 install objs/src/http/modules/perl/nginx.pm $RPM_BUILD_ROOT%{perl_vendorarch}/%{name}.pm
453 install objs/src/http/modules/perl/blib/arch/auto/nginx/nginx.so $RPM_BUILD_ROOT%{perl_vendorarch}/auto/%{name}/%{name}.so
454 install objs/src/http/modules/perl/blib/arch/auto/nginx/nginx.bs $RPM_BUILD_ROOT%{perl_vendorarch}/auto/%{name}/%{name}.bs
455 install contrib/nginx.perl $RPM_BUILD_ROOT%{_sbindir}/%{name}
456 %endif
457
458 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/*.default
459 rm -rf $RPM_BUILD_ROOT%{_prefix}/html
460
461 %clean
462 rm -rf $RPM_BUILD_ROOT
463
464 %pre
465 %groupadd -r -g 213 %{name}
466 %groupadd -g 51 http
467 %useradd -r -u 213 -d /usr/share/empty -s /bin/false -c "Nginx HTTP User" -g %{name} %{name}
468 %addusertogroup %{name} http
469
470 %post
471 for a in access.log error.log; do
472         if [ ! -f /var/log/%{name}/$a ]; then
473                 touch /var/log/%{name}/$a
474                 chown nginx:nginx /var/log/%{name}/$a
475                 chmod 644 /var/log/%{name}/$a
476         fi
477 done
478 /sbin/chkconfig --add %{name}
479 %service %{name} restart
480
481 %preun
482 if [ "$1" = "0" ]; then
483         %service -q %{name} stop
484         /sbin/chkconfig --del %{name}
485 fi
486
487 %postun
488 if [ "$1" = "0" ]; then
489         %userremove %{name}
490         %groupremove %{name}
491 fi
492
493 %files
494 %defattr(644,root,root,755)
495 %attr(755,root,root) %{_sbindir}/%{name}
496
497 %files common
498 %defattr(644,root,root,755)
499 %doc CHANGES LICENSE README html/index.html conf/nginx.conf objs/src/http/modules/perl/blib/man3/nginx.3pm
500 %doc %lang(ru) CHANGES.ru
501 %attr(754,root,root) /etc/rc.d/init.d/%{name}
502 %dir %attr(754,root,root) %{_sysconfdir}
503 %dir %{_nginxdir}
504 %dir %{_nginxdir}/cgi-bin
505 %dir %{_nginxdir}/html
506 %dir %{_nginxdir}/errors
507 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.conf
508 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
509 %attr(640,root,root) %{_sysconfdir}/*[_-]*
510 %attr(640,root,root) %{_sysconfdir}/proxy.conf
511 %attr(640,root,root) %{_sysconfdir}/mime.types
512 %attr(770,root,%{name}) /var/cache/%{name}
513 %attr(750,root,root) %dir /var/log/archive/%{name}
514 %attr(750,%{name},logs) /var/log/%{name}
515 %config(noreplace,missingok) %verify(not md5 mtime size) %{_nginxdir}/html/*
516 %config(noreplace,missingok) %verify(not md5 mtime size) %{_nginxdir}/errors/*
517
518 %if %{with mail}
519 %files mail
520 %defattr(644,root,root,755)
521 %attr(755,root,root) %{_sbindir}/%{name}
522 %endif
523
524 %if %{with light}
525 %files light
526 %defattr(644,root,root,755)
527 %attr(755,root,root) %{_sbindir}/%{name}
528 %endif
529
530 %if %{with perl}
531 %files perl
532 %defattr(644,root,root,755)
533 %attr(755,root,root) %{_sbindir}/%{name}
534 %dir %{perl_vendorarch}/auto/%{name}
535 %attr(755,root,root) %{perl_vendorarch}/auto/%{name}/%{name}.so
536 %attr(700,root,root) %{perl_vendorarch}/auto/%{name}/%{name}.bs
537 %attr(700,root,root) %{perl_vendorarch}/%{name}.pm
538 %endif
539
540 %files -n monit-rc-nginx
541 %defattr(644,root,root,755)
542 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/monit/%{name}.monitrc
This page took 0.138418 seconds and 3 git commands to generate.