3 %bcond_with dietlibc # use dietlibc instead of glibc
4 %bcond_without doc # don't build documentation which needed LaTeX
5 %bcond_with xalan # use the xalan xslt processor
7 Summary: Linux virtual server utilities
8 Summary(pl): Narzêdzia dla linuksowych serwerów wirtualnych
14 Source0: http://www.13thfloor.at/~ensc/util-vserver/files/alpha/%{name}-%{version}.tar.bz2
15 # Source0-md5: 1c8457a687643ae8a7b1f1d34ebbdd68
16 Source1: vprocunhide.init
17 Source2: vservers-default.init
18 Source3: vservers-legacy.init
19 Source4: rebootmgr.init
20 Source5: vservers-default.sysconfig
21 Source6: vservers-legacy.sysconfig
22 Patch0: %{name}-no-kernel-includes.patch
23 Patch1: %{name}-vsysvwrapper.patch
24 Patch2: %{name}-build-poldek.patch
25 URL: http://savannah.nongnu.org/projects/util-vserver/
26 BuildRequires: beecrypt-devel
27 %{?with_dietlibc:BuildRequires: dietlibc >= 0:0.25}
28 BuildRequires: doxygen
29 BuildRequires: libstdc++-devel
30 %{?with_doc:BuildRequires: libxslt-progs}
31 %{?with_doc:BuildRequires: tetex-format-pdflatex}
32 %{?with_doc:BuildRequires: tetex-makeindex}
35 %{?with_xalan:BuildRequires: xalan-j}
38 Requires(post,preun): /sbin/chkconfig
39 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42 This package provides the components and a framework to setup virtual
43 servers. A virtual server runs inside a Linux server. It is
44 nevertheless highly independent. As such, you can run various services
45 with normal configuration. The various vservers can't interact with
46 each other and can't interact with services in the main server.
48 This requires a special kernel supporting the new new_s_context and
49 set_ipv4root system call.
52 Ten pakiet dostarcza sk³adniki i szkielet do tworzenia wirtualnych
53 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
54 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
55 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
56 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
58 Wymaga to specjalnego j±dra obs³uguj±cego nowe wywo³ania systemowe
59 new_s_context i set_ipv4root.
62 Summary: Development files for Linux vserver libraries
63 Summary(pl): Pliki programistyczne dla bibliotek linuksowego vserwera
64 Group: Development/Libraries
65 Requires: %{name} = %{version}-%{release}
68 This package contains the development files necessary for developing
69 programs which use vserver library.
71 %description devel -l pl
72 Ten pakiet zawiera pliki programistyczne konieczne do rozwijania
73 programów u¿ywaj±cych biblioteki vserver.
76 Summary: Static vserver library
77 Summary(pl): Biblioteka statyczna vservera
78 Group: Development/Libraries
79 Requires: %{name}-devel = %{version}-%{release}
82 This package contains the static version of vserver library.
84 %description static -l pl
85 Ten pakiet zawiera statyczn± wersjê biblioteki vservera.
88 Summary: Dynamic libraries for util-vserver
89 Summary(pl): Biblioteki dynamiczne dla pakietu util-vserver
93 util-vserver provides the components and a framework to setup virtual
94 servers. A virtual server runs inside a linux server. It is
95 nevertheless highly independent. As such, you can run various services
96 with normal configuration. The various vservers can't interact with
97 each other and can't interact with services in the main server.
99 This package contains the shared libraries needed by all other
100 'util-vserver' subpackages.
102 %description lib -l pl
103 util-vserver dostarcza sk³adniki i szkielet do tworzenia wirtualnych
104 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
105 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
106 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
107 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
109 Ten pakiet zawiera biblioteki wspó³dzielone wymagane przez wszystkie
110 podpakiety util-vserver.
113 Summary: The core-utilities for util-vserver
114 Summary(pl): Podstawowe narzêdzia dla util-vserver
115 Group: Applications/System
119 util-vserver provides the components and a framework to setup virtual
120 servers. A virtual server runs inside a linux server. It is
121 nevertheless highly independent. As such, you can run various services
122 with normal configuration. The various vservers can't interact with
123 each other and can't interact with services in the main server.
125 This package contains utilities which are required to communicate with
126 the Linux-Vserver enabled kernel.
128 %description core -l pl
129 util-vserver dostarcza sk³adniki i szkielet do tworzenia wirtualnych
130 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
131 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
132 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
133 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
135 Ten pakiet zawiera narzêdzia wymagane do komunikacji z j±drem z
136 w³±czonym mechanizmem Linux-Vserver.
139 Summary: Tools which can be used to build vservers
140 Summary(pl): Narzêdzia do budowania vserverów
141 Group: Applications/System
147 Requires: %{name} = %{version}-%{release}
150 util-vserver provides the components and a framework to setup virtual
151 servers. A virtual server runs inside a linux server. It is
152 nevertheless highly independent. As such, you can run various services
153 with normal configuration. The various vservers can't interact with
154 each other and can't interact with services in the main server.
156 This package contains utilities which assist in building Vservers.
158 %description build -l pl
159 util-vserver dostarcza sk³adniki i szkielet do tworzenia wirtualnych
160 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
161 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
162 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
163 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
165 Ten pakiet zawiera narzêdzia pomagaj±ce przy budowaniu Vserwerów.
168 Summary: initscripts for vserver
169 Summary(pl): Skrypty inicjalizuj±ce dla vserwera
171 Requires(post,preun): /sbin/chkconfig
172 Requires: %{name} = %{version}-%{release}
173 Requires: %{name}-core = %{version}-%{release}
179 util-vserver provides the components and a framework to setup virtual
180 servers. A virtual server runs inside a linux server. It is
181 nevertheless highly independent. As such, you can run various services
182 with normal configuration. The various vservers can't interact with
183 each other and can't interact with services in the main server.
185 This package contains the SysV initscripts which start and stop
186 Vservers and related tools.
188 %description init -l pl
189 util-vserver dostarcza sk³adniki i szkielet do tworzenia wirtualnych
190 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
191 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
192 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
193 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
195 Ten pakiet zawiera skrypty inicjalizuj±ce SysV uruchamiaj±ce i
196 zatrzymuj±ce Vserwery oraz powi±zane narzêdzia.
199 Summary: Legacy utilities for util-vserver
200 Summary(pl): Stare narzêdzia dla util-vserver
201 Group: Applications/System
202 Requires(post,preun): /sbin/chkconfig
203 Requires: %{name} = %{version}-%{release}
204 Requires: %{name}-core = %{version}-%{release}
208 util-vserver provides the components and a framework to setup virtual
209 servers. A virtual server runs inside a linux server. It is
210 nevertheless highly independent. As such, you can run various services
211 with normal configuration. The various vservers can't interact with
212 each other and can't interact with services in the main server.
214 This package contains the tools which are needed to work with Vservers
215 having an old-style configuration.
217 %description legacy -l pl
218 util-vserver dostarcza sk³adniki i szkielet do tworzenia wirtualnych
219 serwerów. Wirtualny serwer dzia³a wewn±trz serwera linuksowego, lecz
220 jest od niego w du¿ym stopniu niezale¿ny. Jako taki mo¿e uruchamiaæ
221 ró¿ne us³ugi z normaln± konfiguracj±. Ró¿ne vserwery nie mog± wchodziæ
222 w interakcjê z innymi ani z us³ugami na g³ównym serwerze.
224 Ten pakiet zawiera narzêdzia potrzebne do pracy z Vserwerami maj±cymi
225 konfiguracjê w starym stylu.
227 %package -n vserver-dev
228 Summary: /dev entries for systems in Vservers
229 Summary(pl): Pliki specjalne /dev/* dla systemów w Vserwerach
231 PreReq: setup >= 2.4.1-2
232 Provides: dev = 2.9.0-19
236 %description -n vserver-dev
237 Unix and unix like systems (including Linux) use file system entries
238 to represent devices attached to the machine. All of these entries are
239 in the /dev tree (though they don't have to be), and this package
240 contains only entries needed for a system running inside Vserver.
242 DO NOT install this package for a normal system!
244 %description -n vserver-dev -l pl
245 Wszystkie systemy klasy unices, w tym Linux, u¿ywaj± plików do
246 przedstawiania urz±dzeñ pod³±czonych do komputera. Wszystkie te pliki
247 znajduj± siê zwykle w katalogu /dev. Pakiet ten wy³±cznie te pliki
248 specjalne które s± potrzebne do uruchomienia systemu w Vserwerze.
250 NIE INSTALUJ tego pakietu na zwyk³ym systemie!
262 --with-initrddir=/etc/rc.d/init.d \
264 %{?with_dietlibc:--enable-dietlibc} \
265 %{!?with_dietlibc:--disable-dietlibc} \
266 IPTABLES=/usr/sbin/iptables \
267 NAMEIF=/sbin/nameif \
272 %{?with_doc:%{__make} doc}
275 rm -rf $RPM_BUILD_ROOT
276 install -d $RPM_BUILD_ROOT{/vservers,/etc/{sysconfig,rc.d/init.d},/dev/pts}
278 %{__make} install install-distribution \
279 DESTDIR=$RPM_BUILD_ROOT
281 install -d $RPM_BUILD_ROOT/etc/vservices
282 install -d $RPM_BUILD_ROOT/vservers/.pkg
283 ln -s /vservers $RPM_BUILD_ROOT%{_sysconfdir}/vservers/vdirbase
284 ln -s %{_localstatedir}/run/vservers.rev $RPM_BUILD_ROOT%{_sysconfdir}/vservers/run.rev
286 install -d $RPM_BUILD_ROOT%{_sysconfdir}/vservers/.distributions/pld2.0
287 ln -s pld2.0 $RPM_BUILD_ROOT%{_sysconfdir}/vservers/.distributions/pld1.99
289 install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/distributions/pld2.0/pkgs
290 ln -s pld2.0 $RPM_BUILD_ROOT%{_libdir}/%{name}/distributions/pld1.99
292 cat > $RPM_BUILD_ROOT%{_libdir}/%{name}/distributions/pld2.0/pkgs/01 << EOF
297 for i in $RPM_BUILD_ROOT/etc/rc.d/init.d/v_* ; do
298 s=`basename $i | sed s/v_//`
299 cat >$RPM_BUILD_ROOT/etc/vservices/$s << EOF
300 # IP addresses/interfaces to bound $s service to
306 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/vprocunhide
307 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/vservers-default
308 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/vservers-legacy
309 install %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/rebootmgr
310 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/vservers-default
311 install %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/vservers-legacy
313 ln -sf /dev/null $RPM_BUILD_ROOT/dev/initctl
316 rm -rf $RPM_BUILD_ROOT
319 %{_sbindir}/setattr --barrier /vservers || :
321 %post lib -p /sbin/ldconfig
322 %postun lib -p /sbin/ldconfig
325 /sbin/chkconfig --add vservers-default
326 /sbin/chkconfig --add vprocunhide
327 #if [ -r /var/lock/subsys/vprocunhide ]; then
328 # /etc/rc.d/init.d/vprocunhide restart >&2
330 #if [ -r /var/lock/subsys/vservers-default ]; then
331 # /etc/rc.d/init.d/vservers-default restart >&2
335 if [ "$1" = "0" ]; then
336 if [ -r /var/lock/subsys/vprocunhide ]; then
337 /etc/rc.d/init.d/vprocunhide stop >&2
339 if [ -r /var/lock/subsys/vservers-default ]; then
340 /etc/rc.d/init.d/vservers-default stop >&2
342 /sbin/chkconfig --del vprocunhide
343 /sbin/chkconfig --del vservers-default
347 /sbin/chkconfig --add rebootmgr
348 /sbin/chkconfig --add vservers-legacy
349 #if [ -r /var/lock/subsys/rebootmgr ] ; then
350 # /etc/rc.d/init.d/rebootmgr restart >&2
352 #if [ -r /var/lock/subsys/vservers-legacy ] ; then
353 # /etc/rc.d/init.d/vservers-legacy restart >&2
357 if [ "$1" = "0" ]; then
358 if [ -r /var/lock/subsys/rebootmgr ] ; then
359 /etc/rc.d/init.d/rebootmgr stop >&2
361 if [ -r /var/lock/subsys/vservers-legacy ] ; then
362 /etc/rc.d/init.d/vservers-legacy stop >&2
364 /sbin/chkconfig --del rebootmgr
365 /sbin/chkconfig --del vservers-legacy
369 %defattr(644,root,root,755)
370 %doc AUTHORS ChangeLog NEWS THANKS doc/intro.txt
371 %{?with_doc:%doc doc/*.html}
372 %dir %{_sysconfdir}/vservers
373 %dir %{_sysconfdir}/vservers/.defaults
374 %dir %{_sysconfdir}/vservers/.defaults/apps
375 %dir %{_sysconfdir}/vservers/.defaults/files
376 %{_sysconfdir}/vservers/.defaults/vdirbase
377 %{_sysconfdir}/vservers/.defaults/run.rev
378 %{_sysconfdir}/vservers/vdirbase
379 %{_sysconfdir}/vservers/run.rev
381 %attr(755,root,root) %{_sbindir}/exec-cd
382 %attr(755,root,root) %{_sbindir}/vdu
383 %attr(755,root,root) %{_sbindir}/vps
384 %attr(755,root,root) %{_sbindir}/vpstree
385 %attr(755,root,root) %{_sbindir}/vserver
386 %attr(755,root,root) %{_sbindir}/vserver-stat
387 %attr(755,root,root) %{_sbindir}/vsomething
388 %attr(755,root,root) %{_sbindir}/vtop
389 %dir %{_libdir}/%{name}
390 %dir %{_libdir}/%{name}/defaults
391 %{_libdir}/%{name}/defaults/*
392 %attr(755,root,root) %{_libdir}/%{name}/capchroot
393 %attr(755,root,root) %{_libdir}/%{name}/chain-echo
394 %attr(755,root,root) %{_libdir}/%{name}/check-unixfile
395 %attr(755,root,root) %{_libdir}/%{name}/chroot-*
396 %attr(755,root,root) %{_libdir}/%{name}/exec-ulimit
397 %attr(755,root,root) %{_libdir}/%{name}/fakerunlevel
398 %attr(755,root,root) %{_libdir}/%{name}/filetime
399 %{_libdir}/%{name}/functions
400 %attr(755,root,root) %{_libdir}/%{name}/keep-ctx-alive
401 %attr(755,root,root) %{_libdir}/%{name}/lockfile
402 %attr(755,root,root) %{_libdir}/%{name}/mask2prefix
403 %attr(755,root,root) %{_libdir}/%{name}/readlink
404 %attr(755,root,root) %{_libdir}/%{name}/save_ctxinfo
405 %attr(755,root,root) %{_libdir}/%{name}/secure-mount
406 %attr(755,root,root) %{_libdir}/%{name}/sigexec
407 %attr(755,root,root) %{_libdir}/%{name}/start-vservers
408 %attr(755,root,root) %{_libdir}/%{name}/vprocunhide
409 %{_libdir}/%{name}/vserver.*
410 %attr(755,root,root) %{_libdir}/%{name}/vservers.grabinfo.sh
411 %attr(755,root,root) %{_libdir}/%{name}/vshelper
412 %attr(755,root,root) %{_libdir}/%{name}/vshelper-sync
414 %attr(0,root,root) %dir /vservers
415 %attr(755,root,root) %dir /vservers/.pkg
416 %dir %{_localstatedir}/run/vservers
417 %dir %{_localstatedir}/run/vservers.rev
418 %dir %{_localstatedir}/run/vshelper
421 %defattr(644,root,root,755)
422 %{?with_doc:%doc lib/apidoc/latex/refman.pdf lib/apidoc/html}
423 %attr(755,root,root) %{_libdir}/lib*.so
425 %{_includedir}/vserver.h
426 %{_pkgconfigdir}/*.pc
429 %defattr(644,root,root,755)
430 %{_libdir}/libvserver.a
433 %defattr(644,root,root,755)
434 %attr(755,root,root) %{_libdir}/lib*.so.*.*.*
437 %defattr(644,root,root,755)
438 %attr(755,root,root) %{_libdir}/%{name}/vsysvwrapper
439 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/vservers-default
440 %attr(754,root,root) /etc/rc.d/init.d/vprocunhide
441 %attr(754,root,root) /etc/rc.d/init.d/vservers-default
444 %defattr(644,root,root,755)
445 %dir %{_libdir}/%{name}
446 %{_libdir}/%{name}/FEATURES.txt
447 %{_libdir}/%{name}/util-vserver-vars
448 %attr(755,root,root) %{_libdir}/%{name}/chcontext-compat
449 %attr(755,root,root) %{_sbindir}/chbind
450 %attr(755,root,root) %{_sbindir}/chcontext
451 %attr(755,root,root) %{_sbindir}/chxid
452 %attr(755,root,root) %{_sbindir}/lsxid
453 %attr(755,root,root) %{_sbindir}/reducecap
454 %attr(755,root,root) %{_sbindir}/setattr
455 %attr(755,root,root) %{_sbindir}/showattr
456 %attr(755,root,root) %{_sbindir}/vattribute
457 %attr(755,root,root) %{_sbindir}/vcontext
458 %attr(755,root,root) %{_sbindir}/vdlimit
459 %attr(755,root,root) %{_sbindir}/vnamespace
460 %attr(755,root,root) %{_sbindir}/vkill
461 %attr(755,root,root) %{_sbindir}/vlimit
462 %attr(755,root,root) %{_sbindir}/vrsetup
463 %attr(755,root,root) %{_sbindir}/vsched
464 %attr(755,root,root) %{_sbindir}/vserver-info
465 %attr(755,root,root) %{_sbindir}/vuname
466 %{_mandir}/man8/chbind*
467 %{_mandir}/man8/chcontext*
468 %{_mandir}/man8/reducecap*
471 %defattr(644,root,root,755)
472 %doc contrib/yum*.patch
473 %dir %{_sysconfdir}/vservers/.distributions
474 %{_sysconfdir}/vservers/.distributions/.common
475 %{_sysconfdir}/vservers/.distributions/*
476 %dir %{_sysconfdir}/vservers/.defaults/apps/vunify
477 %dir %{_sysconfdir}/vservers/.defaults/apps/vunify/hash
478 %attr(755,root,root) %{_libdir}/%{name}/rpm-fake*
479 %dir %{_libdir}/%{name}/distributions
480 %{_libdir}/%{name}/distributions/*
481 %{_libdir}/%{name}/vserver-build.*
482 %{_libdir}/%{name}/vserver-setup.functions
483 %{_libdir}/%{name}/defaults/fstab
484 %{_libdir}/%{name}/defaults/debootstrap.uri
485 %{_libdir}/%{name}/defaults/vunify-exclude
486 %attr(755,root,root) %{_libdir}/%{name}/pkgmgmt
487 %attr(755,root,root) %{_libdir}/%{name}/vapt-get-worker
488 %attr(755,root,root) %{_libdir}/%{name}/vbuild
489 %attr(755,root,root) %{_libdir}/%{name}/vcheck
490 %attr(755,root,root) %{_libdir}/%{name}/vcopy
491 %attr(755,root,root) %{_libdir}/%{name}/vhashify
492 %attr(755,root,root) %{_libdir}/%{name}/vpkg
493 %attr(755,root,root) %{_libdir}/%{name}/vpoldek-worker
494 %attr(755,root,root) %{_libdir}/%{name}/vrpm-*
495 %attr(755,root,root) %{_libdir}/%{name}/vserver-build
496 %attr(755,root,root) %{_libdir}/%{name}/vunify
497 %attr(755,root,root) %{_libdir}/%{name}/vyum-worker
498 %attr(755,root,root) %{_sbindir}/vapt-get
499 %attr(755,root,root) %{_sbindir}/vfiles
500 %attr(755,root,root) %{_sbindir}/vpoldek
501 %attr(755,root,root) %{_sbindir}/vrpm
502 %attr(755,root,root) %{_sbindir}/vyum
503 %{_mandir}/man8/vserver-copy*
506 %defattr(644,root,root,755)
509 %dir %{_libdir}/%{name}/legacy
510 %attr(755,root,root) %{_libdir}/%{name}/legacy/*
511 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/vservers-legacy
512 %attr(754,root,root) /etc/rc.d/init.d/v_*
513 %attr(754,root,root) /etc/rc.d/init.d/rebootmgr
514 %attr(754,root,root) /etc/rc.d/init.d/vservers-legacy
515 %attr(755,root,root) %{_sbindir}/vserver-copy
516 %{_mandir}/man8/distrib-info*
517 %{_mandir}/man8/rebootmgr*
518 %{_mandir}/man8/vps.*
520 %files -n vserver-dev
521 %defattr(644,root,root,755)
523 %dev(c,1,7) %attr(666,root,root) /dev/full
524 %dev(c,1,3) %attr(666,root,root) /dev/null
525 %dev(c,5,2) %attr(666,root,root) /dev/ptmx
526 %dev(c,1,8) %attr(644,root,root) /dev/random
527 %dev(c,5,0) %attr(666,root,root) /dev/tty
528 %dev(c,1,9) %attr(644,root,root) /dev/urandom
529 %dev(c,1,5) %attr(666,root,root) /dev/zero