2 # - /etc/sysconfig/nginx file
3 # - missing perl build/install requires
5 # Conditional build for nginx:
6 %bcond_without light # don't build light version
7 %bcond_without mail # don't build imap/mail proxy
8 %bcond_without perl # don't build with perl module
9 %bcond_without addition # adds module
10 %bcond_without dav # WebDAV
11 %bcond_without flv # FLV stream
12 %bcond_without ipv6 # build without ipv6 support
13 %bcond_without sub # ngx_http_sub_module
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 spdy # spdy module
19 %bcond_without status # status module
20 %bcond_without ssl # ssl support
21 %bcond_with http_browser # header "User-agent" parser
22 %bcond_with rtmp # rtmp support
23 %bcond_with threads # thread pool support
24 %bcond_with debug # enable debug logging: http://nginx.org/en/docs/debugging_log.html
25 %bcond_without auth_request # auth_request module
31 %define rtmp_version 1.1.7
32 Summary: High perfomance HTTP and reverse proxy server
33 Summary(pl.UTF-8): Serwer HTTP i odwrotne proxy o wysokiej wydajności
35 # - stable: production quality with stable API
36 # - mainline: production quality but API can change
41 Group: Networking/Daemons/HTTP
42 Source0: http://nginx.org/download/%{name}-%{version}.tar.gz
43 # Source0-md5: 3ca4a37931e9fa301964b8ce889da8cb
44 Source1: http://nginx.net/favicon.ico
45 # Source1-md5: 2aaf2115c752cbdbfb8a2f0b3c3189ab
47 Source3: %{name}.logrotate
49 Source5: %{name}-light.conf
50 Source6: %{name}-light.monitrc
52 Source8: %{name}-mail.conf
53 Source9: %{name}-mail.monitrc
54 Source11: %{name}-perl.conf
55 Source12: %{name}-perl.monitrc
56 Source14: %{name}-standard.conf
57 Source15: %{name}-standard.monitrc
58 Source17: %{name}-mime.types.sh
59 Source18: %{name}-standard.service
60 Source19: %{name}-light.service
61 Source20: %{name}-perl.service
62 Source21: %{name}-mail.service
63 Source101: https://github.com/arut/nginx-rtmp-module/archive/v%{rtmp_version}/nginx-rtmp-module-%{rtmp_version}.tar.gz
64 # Source101-md5: 8006de2560db3e55bb15d110220076ac
65 Patch0: %{name}-no-Werror.patch
66 URL: http://nginx.net/
67 BuildRequires: mailcap
68 BuildRequires: openssl-devel
69 BuildRequires: pcre-devel
70 %{?with_perl:BuildRequires: perl-CGI}
71 %{?with_perl:BuildRequires: perl-devel}
72 %{?with_perl:BuildRequires: python}
73 %{?with_perl:BuildRequires: rpm-perlprov}
74 BuildRequires: rpmbuild(macros) >= 1.644
75 BuildRequires: zlib-devel
76 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
78 %define _sysconfdir /etc/%{name}
79 %define _nginxdir /home/services/%{name}
82 nginx ("engine x") is a high-performance HTTP server and reverse
83 proxy, as well as an IMAP/POP3 proxy server. nginx was written by Igor
84 Sysoev for Rambler.ru, Russia's second-most visited website, where it
85 has been running in production for over two and a half years. Igor has
86 released the source code under a BSD-like license. Although still in
87 beta, nginx is known for its stability, rich feature set, simple
88 configuration, and low resource consumption.
90 %description -l pl.UTF-8
91 nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
92 a także IMAP/POP3 proxy. nginx został napisany przez Igora Sysoeva na
93 potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
94 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
95 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle w
96 fazie beta, już zasłynął dzięki stabilności, bogactwu dodatków,
97 prostej konfiguracji oraz małej "zasobożerności".
100 Summary: nginx - common files
101 Summary(pl.UTF-8): nginx - pliki wspólne
102 Group: Networking/Daemons/HTTP
103 Requires(postun): /usr/sbin/groupdel
104 Requires(postun): /usr/sbin/userdel
105 Requires(pre): /bin/id
106 Requires(pre): /usr/bin/getgid
107 Requires(pre): /usr/sbin/groupadd
108 Requires(pre): /usr/sbin/useradd
109 Requires: rc-scripts >= 0.2.0
110 Requires: systemd-units >= 38
111 Provides: group(http)
112 Provides: group(nginx)
113 Provides: user(nginx)
115 Obsoletes: nginx < 1.4.1-4.1
116 Conflicts: logrotate < 3.8.0
119 Common files for the nginx daemon.
121 %description common -l pl.UTF-8
122 Niezbędne pliki dla nginx.
125 Summary: High perfomance HTTP and reverse proxy server
126 Summary(pl.UTF-8): Serwer HTTP i odwrotne proxy o wysokiej wydajności
127 Group: Networking/Daemons/HTTP
128 Requires(post,preun): /sbin/chkconfig
129 Requires(post,preun,postun): systemd-units >= 38
130 Requires: %{name}-common = %{version}-%{release}
131 Provides: nginx-daemon
135 nginx ("engine x") is a high-performance HTTP server and reverse
136 proxy, as well as an IMAP/POP3 proxy server. nginx was written by Igor
137 Sysoev for Rambler.ru, Russia's second-most visited website, where it
138 has been running in production for over two and a half years. Igor has
139 released the source code under a BSD-like license. Although still in
140 beta, nginx is known for its stability, rich feature set, simple
141 configuration, and low resource consumption.
143 The smallest, but also the fastest nginx edition. No additional
144 modules, no Perl, no DAV, no FLV, no IMAP, POP3, SMTP proxy.
146 %description light -l pl.UTF-8
147 nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
148 a także IMAP/POP3 proxy. nginx został napisany przez Igora Sysoeva na
149 potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
150 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
151 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle w
152 fazie beta, już zasłynął dzięki stabilności, bogactwu dodatków,
153 prostej konfiguracji oraz małej "zasobożerności".
155 Najmniejsza i najszybsza wersja nginx. Bez wsparcia dla Perla, DAV,
156 FLV oraz IMAP, POP3, SMTP proxy.
159 Summary: High perfomance HTTP and reverse proxy server
160 Summary(pl.UTF-8): Serwer HTTP i odwrotne proxy o wysokiej wydajności
161 Group: Networking/Daemons/HTTP
162 Requires(post,preun): /sbin/chkconfig
163 Requires(post,preun,postun): systemd-units >= 38
164 Requires: %{name}-common = %{version}-%{release}
166 Provides: nginx-daemon
170 nginx ("engine x") is a high-performance HTTP server and reverse
171 proxy, as well as an IMAP/POP3 proxy server. nginx was written by Igor
172 Sysoev for Rambler.ru, Russia's second-most visited website, where it
173 has been running in production for over two and a half years. Igor has
174 released the source code under a BSD-like license. Although still in
175 beta, nginx is known for its stability, rich feature set, simple
176 configuration, and low resource consumption.
178 nginx with Perl support. Mail modules not included.
180 %description perl -l pl.UTF-8
181 nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
182 a także IMAP/POP3 proxy. nginx został napisany przez Igora Sysoeva na
183 potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
184 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
185 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle w
186 fazie beta, już zasłynął dzięki stabilności, bogactwu dodatków,
187 prostej konfiguracji oraz małej "zasobożerności".
189 nginx z obsługą Perla. Bez wsparcia dla modułów poczty.
192 Summary: High perfomance IMAP, POP3, SMTP proxy server
193 Summary(pl.UTF-8): IMAP, POP3, SMTP proxy o wysokiej wydajności
194 Group: Networking/Daemons/HTTP
195 Requires(post,preun): /sbin/chkconfig
196 Requires(post,preun,postun): systemd-units >= 38
197 Requires: %{name}-common = %{version}-%{release}
198 Provides: nginx-daemon
201 nginx ("engine x") is a high-performance HTTP server and reverse
202 proxy, as well as an IMAP/POP3 proxy server. nginx was written by Igor
203 Sysoev for Rambler.ru, Russia's second-most visited website, where it
204 has been running in production for over two and a half years. Igor has
205 released the source code under a BSD-like license. Although still in
206 beta, nginx is known for its stability, rich feature set, simple
207 configuration, and low resource consumption.
209 nginx with mail support. Only mail modules included.
211 %description mail -l pl.UTF-8
212 nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
213 a także IMAP/POP3 proxy. nginx został napisany przez Igora Sysoeva na
214 potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
215 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
216 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle w
217 fazie beta, już zasłynął dzięki stabilności, bogactwu dodatków,
218 prostej konfiguracji oraz małej "zasobożerności".
220 nginx ze wsparciem tylko dla modułów poczty.
223 Summary: High perfomance HTTP and reverse proxy server
224 Summary(pl.UTF-8): Serwer HTTP i odwrotne proxy o wysokiej wydajności
225 Group: Networking/Daemons/HTTP
226 Requires(post,preun): /sbin/chkconfig
227 Requires(post,preun,postun): systemd-units >= 38
228 Requires: %{name}-common = %{version}-%{release}
231 Provides: nginx-daemon
232 Conflicts: logrotate < 3.7-4
234 %description standard
235 nginx ("engine x") is a high-performance HTTP server and reverse
236 proxy, as well as an IMAP/POP3 proxy server. nginx was written by Igor
237 Sysoev for Rambler.ru, Russia's second-most visited website, where it
238 has been running in production for over two and a half years. Igor has
239 released the source code under a BSD-like license. Although still in
240 beta, nginx is known for its stability, rich feature set, simple
241 configuration, and low resource consumption.
243 This is standard nginx version, without Perl support and IMAP, POP3,
246 %description standard -l pl.UTF-8
247 nginx ("engine x") jest wysokowydajnym serwerem HTTP, odwrotnym proxy
248 a także IMAP/POP3 proxy. nginx został napisany przez Igora Sysoeva na
249 potrzeby serwisu Rambler.ru. Jest to drugi pod względem ilości
250 odwiedzin serwis w Rosji i działa od ponad dwóch i pół roku. Igor
251 opublikował źródła na licencji BSD. Mimo, że projekt jest ciągle w
252 fazie beta, już zasłynął dzięki stabilności, bogactwu dodatków,
253 prostej konfiguracji oraz małej "zasobożerności". ginx ("engine x")
254 jest wysokowydajnym serwerem HTTP, odwrotnym proxy a także IMAP/POP3
255 proxy. nginx został napisany przez Igora Sysoeva na potrzeby serwisu
256 Rambler.ru. Jest to drugi pod względem ilości odwiedzin serwis w Rosji
257 i działa od ponad dwóch i pół roku. Igor opublikował źródła na
258 licencji BSD. Mimo, że projekt jest ciągle w fazie beta, już zasłynął
259 dzięki stabilności, bogactwu dodatków, prostej konfiguracji oraz małej
262 To jest standardowa wersja nginx, bez obsługi Perla oraz proxy dla
265 %package -n monit-rc-nginx
266 Summary: nginx support for monit
267 Summary(pl.UTF-8): Wsparcie nginx dla monit
268 Group: Applications/System
269 URL: http://nginx.eu/
270 Requires: %{name}-common = %{version}-%{release}
273 %description -n monit-rc-nginx
274 monitrc file for monitoring nginx webserver.
276 %description -n monit-rc-nginx -l pl.UTF-8
277 Plik monitrc do monitorowania serwera WWW nginx.
280 %setup -q %{?with_rtmp:-a101}
284 mv nginx-rtmp-module-%{rtmp_version} nginx-rtmp-module
287 # build mime.types.conf
288 #sh %{SOURCE17} /etc/mime.types
291 # NB: not autoconf generated configure
292 cp -f configure auto/
296 # build with default options
300 --prefix=%{_prefix} \
301 --sbin-path=%{_sbindir}/%{name}-$type \
302 --conf-path=%{_sysconfdir}/%{name}-$type.conf \
303 --error-log-path=%{_localstatedir}/log/%{name}/%{name}-${type}_error.log \
304 --http-log-path=%{_localstatedir}/log/%{name}/%{name}-${type}_access.log \
305 --pid-path=%{_localstatedir}/run/%{name}-$type.pid \
306 --lock-path=%{_localstatedir}/lock/subsys/%{name}-$type \
307 --http-client-body-temp-path=%{_localstatedir}/cache/%{name}-$type/client_body_temp \
308 --http-fastcgi-temp-path=%{_localstatedir}/cache/%{name}-$type/fastcgi_temp \
309 --http-proxy-temp-path=%{_localstatedir}/cache/%{name}-$type/proxy_temp \
312 %{?with_ipv6:--with-ipv6} \
313 %{?with_select:--with-select_module} \
314 %{?with_poll:--with-poll_module} \
315 %{?with_rtsig:--with-rtsig_module} \
316 --with-cc="%{__cc}" \
317 --with-cc-opt="%{rpmcflags}" \
318 --with-ld-opt="%{rpmldflags}" \
319 %{?with_debug:--with-debug} \
326 --with-http_perl_module \
327 %{?with_addition:--with-http_addition_module} \
328 %{?with_dav:--with-http_dav_module} \
329 %{?with_flv:--with-http_flv_module} \
330 %{?with_sub:--with-http_sub_module} \
331 %{?with_realip:--with-http_realip_module} \
332 %{?with_status:--with-http_stub_status_module} \
333 %{?with_ssl:--with-http_ssl_module} \
334 %{!?with_http_browser:--without-http_browser_module} \
335 %{?with_rtmp:--add-module=./nginx-rtmp-module} \
336 %{?with_auth_request:--with-http_auth_request_module} \
337 %{?with_threads:--with-threads} \
338 %{?with_spdy:--with-http_spdy_module} \
339 --with-http_secure_link_module \
342 mv -f objs/nginx bin/nginx-perl
343 mv -f objs/src/http/modules/perl/blib/arch/auto/nginx/nginx.so bin/nginx.so
344 mv -f objs/src/http/modules/perl/nginx.pm bin/nginx.pm
352 --with-mail_ssl_module \
355 mv -f objs/nginx bin/nginx-mail
360 %{?with_realip:--with-http_realip_module} \
361 %{?with_status:--with-http_stub_status_module} \
362 %{?with_ssl:--with-http_ssl_module} \
363 %{?with_rtmp:--add-module=./nginx-rtmp-module} \
364 %{?with_auth_request:--with-http_auth_request_module} \
365 %{?with_threads:--with-threads} \
366 %{?with_spdy:--with-http_spdy_module} \
367 --without-http_browser_module \
368 --with-http_secure_link_module \
371 mv -f objs/nginx bin/nginx-light
375 %{?with_addition:--with-http_addition_module} \
376 %{?with_dav:--with-http_dav_module} \
377 %{?with_flv:--with-http_flv_module} \
378 %{?with_sub:--with-http_sub_module} \
379 %{?with_realip:--with-http_realip_module} \
380 %{?with_status:--with-http_stub_status_module} \
381 %{?with_ssl:--with-http_ssl_module} \
382 %{!?with_http_browser:--without-http_browser_module} \
383 %{?with_rtmp:--add-module=./nginx-rtmp-module} \
384 %{?with_auth_request:--with-http_auth_request_module} \
385 %{?with_threads:--with-threads} \
386 --with-http_secure_link_module \
389 mv -f objs/%{name} bin/%{name}-standard
392 rm -rf $RPM_BUILD_ROOT
393 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d \
394 $RPM_BUILD_ROOT%{_nginxdir}/{cgi-bin,html,errors} \
395 $RPM_BUILD_ROOT%{_localstatedir}/log/{%{name},archive/%{name}} \
396 $RPM_BUILD_ROOT%{_localstatedir}/cache/{%{name}-standard,%{name}-perl,%{name}-mail,%{name}-light} \
397 $RPM_BUILD_ROOT%{_localstatedir}/lock/subsys/{%{name}-standard,%{name}-perl,%{name}-mail,%{name}-light} \
398 $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir}/{vhosts,webapps}.d} \
399 $RPM_BUILD_ROOT/etc/{logrotate.d,monit} \
400 $RPM_BUILD_ROOT{%{systemdunitdir},/etc/systemd/system}
402 cp -p conf/*_params $RPM_BUILD_ROOT%{_sysconfdir}
403 cp -p conf/koi-utf $RPM_BUILD_ROOT%{_sysconfdir}/koi-utf
404 cp -p conf/koi-win $RPM_BUILD_ROOT%{_sysconfdir}/koi-win
405 cp -p conf/win-utf $RPM_BUILD_ROOT%{_sysconfdir}/win-utf
406 cp -p html/index.html $RPM_BUILD_ROOT%{_nginxdir}/html
407 cp -p html/50x.html $RPM_BUILD_ROOT%{_nginxdir}/errors
408 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_nginxdir}/html/favicon.ico
409 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/proxy.conf
410 cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
411 cp -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/mime.types
412 cp -p %{SOURCE14} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-standard.conf
413 cp -p %{SOURCE15} $RPM_BUILD_ROOT/etc/monit/%{name}-standard.monitrc
414 install -p %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-standard
415 %{__sed} -i -e 's/@flavor@/standard/g' $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-standard
416 cp -p %{SOURCE18} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}-standard.service
417 install -p bin/nginx-standard $RPM_BUILD_ROOT%{_sbindir}
418 ln -sf %{systemdunitdir}/%{name}-standard.service $RPM_BUILD_ROOT/etc/systemd/system/nginx.service
421 cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-light.conf
422 cp -p %{SOURCE6} $RPM_BUILD_ROOT/etc/monit/%{name}-light.monitrc
423 cp -p %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-light
424 %{__sed} -i -e 's/@flavor@/light/g' $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-light
425 cp -p %{SOURCE19} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}-light.service
426 install -p bin/nginx-light $RPM_BUILD_ROOT%{_sbindir}
430 cp -p %{SOURCE8} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-mail.conf
431 cp -p %{SOURCE9} $RPM_BUILD_ROOT/etc/monit/%{name}-mail.monitrc
432 install -p bin/nginx-mail $RPM_BUILD_ROOT%{_sbindir}
433 install -p %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-mail
434 %{__sed} -i -e 's/@flavor@/mail/g' $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-mail
435 cp -p %{SOURCE21} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}-mail.service
439 install -d $RPM_BUILD_ROOT{%{perl_vendorarch},%{perl_vendorarch}/auto/%{name}}
440 cp -p %{SOURCE11} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-perl.conf
441 cp -p %{SOURCE12} $RPM_BUILD_ROOT/etc/monit/%{name}-perl.monitrc
442 install -p %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-perl
443 %{__sed} -i -e 's/@flavor@/perl/g' $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-perl
444 cp -p %{SOURCE20} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}-perl.service
445 cp -p bin/nginx.pm $RPM_BUILD_ROOT%{perl_vendorarch}/%{name}.pm
446 install -p bin/nginx.so $RPM_BUILD_ROOT%{perl_vendorarch}/auto/%{name}/%{name}.so
447 install -p bin/nginx-perl $RPM_BUILD_ROOT%{_sbindir}
450 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/*.default
451 rm -rf $RPM_BUILD_ROOT%{_prefix}/html
453 # only touch these for ghost packaging
454 touch $RPM_BUILD_ROOT%{_sysconfdir}/{fastcgi,scgi,uwsgi}.params
457 rm -rf $RPM_BUILD_ROOT
460 %groupadd -r -g 213 %{name}
462 %useradd -r -u 213 -d /usr/share/empty -s /bin/false -c "Nginx HTTP User" -g %{name} %{name}
463 %addusertogroup %{name} http
466 for a in access.log error.log; do
467 if [ ! -f /var/log/%{name}/nginx-standard_$a ]; then
469 touch /var/log/%{name}/nginx-standard_$a
470 chown nginx:nginx /var/log/%{name}/nginx-standard_$a
471 chmod 644 /var/log/%{name}/nginx-standard_$a
474 /sbin/chkconfig --add %{name}-standard
475 %systemd_post %{name}-standard.service
476 %service %{name}-standard restart
477 echo 'NOTE: this nginx daemon is using "/etc/nginx/nginx-standard.conf" as config.'
478 if ! [ -L /etc/systemd/system/nginx.service ] ; then
479 ln -s %{systemdunitdir}/%{name}-standard.service /etc/systemd/system/nginx.service || :
483 for a in access.log error.log; do
484 if [ ! -f /var/log/%{name}/nginx-light_$a ]; then
486 touch /var/log/%{name}/nginx-light_$a
487 chown nginx:nginx /var/log/%{name}/nginx-light_$a
488 chmod 644 /var/log/%{name}/nginx-light_$a
491 /sbin/chkconfig --add %{name}-light
492 %systemd_post %{name}-light.service
493 %service %{name}-light restart
494 echo 'NOTE: this nginx daemon is using "/etc/nginx/nginx-light.conf" as config'
497 for a in access.log error.log; do
498 if [ ! -f /var/log/%{name}/nginx-perl_$a ]; then
500 touch /var/log/%{name}/nginx-perl_$a
501 chown nginx:nginx /var/log/%{name}/nginx-perl_$a
502 chmod 644 /var/log/%{name}/nginx-perl_$a
505 /sbin/chkconfig --add %{name}-perl
506 %systemd_post %{name}-perl.service
507 %service %{name}-perl restart
508 echo 'NOTE: this nginx daemon is using "/etc/nginx/nginx-perl.conf" as config'
511 for a in access.log error.log; do
512 if [ ! -f /var/log/%{name}/nginx-mail_$a ]; then
514 touch /var/log/%{name}/nginx-mail_$a
515 chown nginx:nginx /var/log/%{name}/nginx-mail_$a
516 chmod 644 /var/log/%{name}/nginx-mail_$a
519 /sbin/chkconfig --add %{name}-mail
520 %systemd_post %{name}-mail.service
521 %service %{name}-mail restart
522 echo 'NOTE: this nginx daemon is using "/etc/nginx/nginx-mail.conf" as config'
525 if [ "$1" = "0" ];then
526 %service %{name}-standard stop
527 /sbin/chkconfig --del %{name}-standard
529 %systemd_preun %{name}-standard.service
532 if [ "$1" = "0" ]; then
533 %service %{name}-light stop
534 /sbin/chkconfig --del %{name}-light
536 %systemd_preun %{name}-light.service
539 if [ "$1" = "0" ]; then
540 %service %{name}-perl stop
541 /sbin/chkconfig --del %{name}-perl
543 %systemd_preun %{name}-perl.service
546 if [ "$1" = "0" ]; then
547 %service %{name}-mail stop
548 /sbin/chkconfig --del %{name}-mail
550 %systemd_preun %{name}-mail.service
553 if [ "$1" = "0" ]; then
570 %triggerpostun -- %{name}-standard < 1.4.1-4
571 %systemd_trigger %{name}-standard.service
573 %triggerpostun -- %{name}-light < 1.4.1-4
574 %systemd_trigger %{name}-light.service
576 %triggerpostun -- %{name}-perl < 1.4.1-4
577 %systemd_trigger %{name}-perl.service
579 %triggerpostun -- %{name}-mail < 1.4.1-4
580 %systemd_trigger %{name}-mail.service
582 %triggerpostun common -- %{name}-common < 1.8.0-2
583 # skip *this* trigger on downgrade
584 [ $1 -le 1 ] && exit 0
585 ln -sf fastcgi_params %{_sysconfdir}/fastcgi.params
586 ln -sf scgi_params %{_sysconfdir}/scgi.params
587 ln -sf uwsgi_params %{_sysconfdir}/uwsgi.params
591 %defattr(644,root,root,755)
592 %doc CHANGES LICENSE README html/index.html conf/nginx.conf
593 %doc %lang(ru) CHANGES.ru
594 %dir %attr(754,root,root) %{_sysconfdir}
596 %dir %{_nginxdir}/cgi-bin
597 %dir %{_nginxdir}/html
598 %dir %{_nginxdir}/errors
599 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
600 # XXX: duplicates, don't use such glob here
601 #%attr(640,root,root) %{_sysconfdir}/*[_-]*
602 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/proxy.conf
603 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/fastcgi_params
604 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/scgi_params
605 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/uwsgi_params
606 %ghost %{_sysconfdir}/fastcgi.params
607 %ghost %{_sysconfdir}/scgi.params
608 %ghost %{_sysconfdir}/uwsgi.params
609 %attr(640,root,root) %{_sysconfdir}/mime.types
610 %attr(640,root,root) %{_sysconfdir}/koi-utf
611 %attr(640,root,root) %{_sysconfdir}/koi-win
612 %attr(640,root,root) %{_sysconfdir}/win-utf
613 %dir %{_sysconfdir}/webapps.d
614 %dir %{_sysconfdir}/vhosts.d
615 %attr(750,nginx,logs) %dir /var/log/archive/%{name}
616 %attr(750,nginx,logs) /var/log/%{name}
617 %config(noreplace,missingok) %verify(not md5 mtime size) %{_nginxdir}/html/*
618 %config(noreplace,missingok) %verify(not md5 mtime size) %{_nginxdir}/errors/*
619 %ghost /etc/systemd/system/nginx.service
622 %defattr(644,root,root,755)
623 %attr(755,root,root) %{_sbindir}/%{name}-standard
624 %attr(770,root,%{name}) /var/cache/%{name}-standard
625 %attr(754,root,root) /etc/rc.d/init.d/%{name}-standard
626 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}-standard.conf
627 %{systemdunitdir}/%{name}-standard.service
631 %defattr(644,root,root,755)
632 %attr(755,root,root) %{_sbindir}/%{name}-mail
633 %attr(770,root,%{name}) /var/cache/%{name}-mail
634 %attr(754,root,root) /etc/rc.d/init.d/%{name}-mail
635 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}-mail.conf
636 %{systemdunitdir}/%{name}-mail.service
641 %defattr(644,root,root,755)
642 %attr(755,root,root) %{_sbindir}/%{name}-light
643 %attr(770,root,%{name}) /var/cache/%{name}-light
644 %attr(754,root,root) /etc/rc.d/init.d/%{name}-light
645 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}-light.conf
646 %{systemdunitdir}/%{name}-light.service
651 %defattr(644,root,root,755)
652 %attr(755,root,root) %{_sbindir}/%{name}-perl
653 %attr(754,root,root) /etc/rc.d/init.d/%{name}-perl
654 %attr(770,root,%{name}) /var/cache/%{name}-perl
655 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}-perl.conf
656 %dir %{perl_vendorarch}/auto/%{name}
657 %attr(755,root,root) %{perl_vendorarch}/auto/%{name}/%{name}.so
658 %{perl_vendorarch}/%{name}.pm
659 %{systemdunitdir}/%{name}-perl.service
662 %files -n monit-rc-nginx
663 %defattr(644,root,root,755)
664 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/monit/%{name}-standard.monitrc
666 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/monit/%{name}-perl.monitrc
669 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/monit/%{name}-light.monitrc
672 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/monit/%{name}-mail.monitrc