3 ## This package understands the following switches:
4 ## --without dietlibc ... disable usage of dietlibc
5 ## --with xalan ... require/use the xalan xslt processor
7 %global confdir %_sysconfdir/vservers
8 %global confdefaultdir %confdir/.defaults
9 %global pkglibdir %_libdir/%name
10 %global chkconfig /sbin/chkconfig
12 %global _localstatedir %_var
15 %{!?release_func:%global release_func() %1%{?dist}}
17 Summary: Linux virtual server utilities
20 Release: %release_func 0
22 Group: System Environment/Base
23 URL: http://savannah.nongnu.org/projects/util-vserver/
24 Source0: http://www.13thfloor.at/~ensc/util-vserver/files/alpha/%name-%version.tar.bz2
25 #Source1: http://www.13thfloor.at/~ensc/util-vserver/files/alpha/%name-%version.tar.bz2.asc
26 BuildRoot: %_tmppath/%name-%version-%release-root
28 Requires: %name-core = %version-%release
29 Requires: %name-lib = %version-%release
30 Requires: diffutils mktemp sed
31 Provides: vserver = %version-%release
32 Obsoletes: vserver < %version
33 BuildRequires: mount vconfig gawk iproute iptables
34 BuildRequires: gcc-c++ wget which diffutils
35 BuildRequires: e2fsprogs-devel beecrypt-devel
36 BuildRequires: doxygen tetex-latex
37 Requires(post): %name-core
38 Requires(pre): %pkglibdir
39 Requires(postun): %pkglibdir
40 %{!?_without_dietlibc:BuildRequires: dietlibc >= 0:0.25}
41 %{?_with_xalan:BuildRequires: xalan-j}
44 Summary: Dynamic libraries for util-vserver
45 Group: System Environment/Libraries
48 Summary: The core-utilities for util-vserver
49 Group: Applications/System
53 Summary: Tools which can be used to build vservers
54 Group: Applications/System
55 Requires: rpm wget binutils tar e2fsprogs
56 Requires: %name = %version-%release
57 Requires(pre): %confdir
58 Requires(postun): %confdir
59 Requires(post): %name-core
62 Summary: SysV-initscripts for vserver
63 Group: System Environment/Base
64 Provides: init(%name) = sysv
65 Requires: make diffutils
67 Requires: %name = %version-%release
68 Requires(post): %chkconfig
69 Requires(preun): %chkconfig
70 Requires(pre): %_initrddir %pkglibdir
71 requires(postun): %_initrddir %pkglibdir
74 Summary: Legacy utilities for util-vserver
75 Group: Applications/System
76 Requires: %name = %version-%release
77 Requires(post): %chkconfig
78 Requires(preun): %chkconfig
79 Requires(pre): %_initrddir %pkglibdir
80 requires(postun): %_initrddir %pkglibdir
83 Summary: Header-files and libraries needed to develop vserver based applications
84 Group: Development/Libraries
86 Requires: %name-lib = %version-%release
90 util-vserver provides the components and a framework to setup virtual
91 servers. A virtual server runs inside a linux server. It is nevertheless
92 highly independent. As such, you can run various services with normal
93 configuration. The various vservers can't interact with each other and
94 can't interact with services in the main server.
96 This requires a special kernel supporting the new new_s_context and
97 set_ipv4root system call.
100 util-vserver provides the components and a framework to setup virtual
101 servers. A virtual server runs inside a linux server. It is nevertheless
102 highly independent. As such, you can run various services with normal
103 configuration. The various vservers can't interact with each other and
104 can't interact with services in the main server.
106 This package contains the shared libraries needed by all other
107 'util-vserver' subpackages.
110 util-vserver provides the components and a framework to setup virtual
111 servers. A virtual server runs inside a linux server. It is nevertheless
112 highly independent. As such, you can run various services with normal
113 configuration. The various vservers can't interact with each other and
114 can't interact with services in the main server.
116 This package contains utilities which are required to communicate with
117 the Linux-Vserver enabled kernel.
121 util-vserver provides the components and a framework to setup virtual
122 servers. A virtual server runs inside a linux server. It is nevertheless
123 highly independent. As such, you can run various services with normal
124 configuration. The various vservers can't interact with each other and
125 can't interact with services in the main server.
127 This package contains utilities which assist in building Vservers.
130 util-vserver provides the components and a framework to setup virtual
131 servers. A virtual server runs inside a linux server. It is nevertheless
132 highly independent. As such, you can run various services with normal
133 configuration. The various vservers can't interact with each other and
134 can't interact with services in the main server.
136 This package contains the SysV initscripts which start and stop
137 VServers and related tools.
141 util-vserver provides the components and a framework to setup virtual
142 servers. A virtual server runs inside a linux server. It is nevertheless
143 highly independent. As such, you can run various services with normal
144 configuration. The various vservers can't interact with each other and
145 can't interact with services in the main server.
147 This package contains the tools which are needed to work with VServers
148 having an old-style configuration.
152 util-vserver provides the components and a framework to setup virtual
153 servers. A virtual server runs inside a linux server. It is nevertheless
154 highly independent. As such, you can run various services with normal
155 configuration. The various vservers can't interact with each other and
156 can't interact with services in the main server.
158 This package contains header files and libraries which are needed to
159 develop VServer related applications.
167 %configure --with-initrddir=%_initrddir --enable-release \
168 %{?_without_dietlibc:--disable-dietlibc}
170 %__make %{?_smp_mflags} all
171 %__make %{?_smp_mflags} doc
175 rm -rf $RPM_BUILD_ROOT
176 %__make DESTDIR="$RPM_BUILD_ROOT" install install-distribution
178 rm -f $RPM_BUILD_ROOT/%_libdir/*.la
180 MANIFEST_CONFIG='%config' \
181 MANIFEST_CONFIG_NOREPLACE='%config(noreplace)' \
182 contrib/make-manifest %name $RPM_BUILD_ROOT contrib/manifest.dat
190 rm -rf $RPM_BUILD_ROOT
194 test -d /vservers || mkdir -m0000 /vservers
195 test -d /vservers/.pkg || mkdir -m0755 /vservers/.pkg
197 f="%confdefaultdir/vdirbase"; test -L "$f" -o -e "$f" || ln -s /vservers "$f"
198 f="%confdefaultdir/run.rev"; test -L "$f" -o -e "$f" || ln -s %_localstatedir/run/vservers.rev "$f"
199 f="%confdefaultdir/cachebase"; test -L "$f" -o -e "$f" || ln -s %_localstatedir/cache/vservers "$f"
201 %_sbindir/setattr --barrier /vservers /vservers/.pkg || :
205 test "$1" != 0 || rm -rf %_localstatedir/cache/vservers/* 2>/dev/null || :
208 %post lib -p /sbin/ldconfig
209 %postun lib -p /sbin/ldconfig
213 %chkconfig --add vservers-default
214 %chkconfig --add vprocunhide
219 test "$1" != 0 || %_initrddir/vprocunhide stop &>/dev/null || :
221 test "$1" != 0 || %chkconfig --del vprocunhide
222 test "$1" != 0 || %chkconfig --del vservers-default
226 test "$1" = 0 || %_initrddir/vprocunhide condrestart >/dev/null || :
229 %triggerin build -- fedora-release, centos-release
236 test -r "$i" || continue
238 target=%confdir/.distributions/.common/pubkeys/$base-$(basename "$i")
242 copy fedora /usr/share/doc/fedora-release-*/RPM-GPG-*
243 copy fedora /etc/pki/rpm-gpg/RPM-GPG-*
244 copy centos /usr/share/doc/centos-*/RPM-GPG-KEY-*
248 test -d /vservers/.hash || mkdir -m0700 /vservers/.hash
250 f="%confdefaultdir/apps/vunify/hash"; test -e "$f"/method -o -e "$f"/00 || \
251 ln -s /vservers/.hash "$f"/00
253 %_sbindir/setattr --barrier /vservers/.hash || :
257 test "$1" != 0 || rm -f %confdir/.distributions/.common/pubkeys/fedora-*
260 ## Temporary workaround to remove old v_* files; it will conflict
261 ## somehow with the -legacy package but can be fixed by reinstalling
263 ## TODO: remove me in the final .spec file
264 %define v_services httpd named portmap sendmail smb sshd xinetd gated
265 %triggerun sysv -- util-vserver-sysv < 0.30.198
266 for i in %v_services; do
267 %chkconfig --del v_$i || :
272 %chkconfig --add rebootmgr
273 %chkconfig --add vservers-legacy
275 for i in %v_services; do
276 %chkconfig --add v_$i
281 test "$1" != 0 || %_initrddir/rebootmgr stop &>/dev/null || :
283 test "$1" != 0 || for i in %v_services; do
284 %chkconfig --del v_$i
287 test "$1" != 0 || %chkconfig --del rebootmgr
288 test "$1" != 0 || %chkconfig --del vservers-legacy
291 test "$1" = 0 || %_initrddir/rebootmgr condrestart >/dev/null || :
294 %files -f %name-base.list
295 %defattr(-,root,root,-)
296 %doc AUTHORS COPYING ChangeLog NEWS README THANKS
297 %doc doc/*.html doc/*.css
301 %dir %confdefaultdir/apps
302 %dir %confdefaultdir/files
303 %dir %pkglibdir/defaults
304 %ghost %confdefaultdir/cachebase
305 %ghost %confdefaultdir/vdirbase
306 %ghost %confdefaultdir/run.rev
308 %dir %_localstatedir/cache/vservers
309 %dir %_localstatedir/run/vservers
310 %dir %_localstatedir/run/vservers.rev
311 %dir %_localstatedir/run/vshelper
314 %files lib -f %name-lib.list
315 %files sysv -f %name-sysv.list
318 %files core -f %name-core.list
319 %defattr(-,root,root,-)
323 %files build -f %name-build.list
324 %defattr(-,root,root,-)
325 %doc contrib/yum*.patch
326 %dir %confdir/.distributions
327 %dir %confdir/.distributions/*
328 %dir %confdir/.distributions/*/apt
329 %dir %confdir/.distributions/.common
330 %dir %confdir/.distributions/.common/pubkeys
331 %dir %confdefaultdir/apps/vunify
332 %dir %confdefaultdir/apps/vunify/hash
335 %files legacy -f %name-legacy.list
336 %defattr(-,root,root,-)
337 %dir %pkglibdir/legacy
340 %files devel -f %name-devel.list
341 %defattr(-,root,root,-)
342 %doc lib/apidoc/latex/refman.pdf
347 * Sun Jan 22 2006 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.30.210-0
348 - do not require 'xalan' anymore by default
349 - removed 'Requires: apt'; apt-rpm is not maintained upstream anymore
350 - removed 'chattr' leftovers
351 - create the '/etc/vservers/.defaults/cachebase' symlink
352 - added /var/cache/vservers and the needed support
353 - set barrier attribute on /vservers/.pkg and /vservers/.hash
354 - added 'centos-release' to the list of packages in the copy-the-keys
356 - create '/vservers/.hash' and add initial configuration for it
358 * Sun Oct 30 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.209-0
362 * Sat Jul 16 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.208-2
365 * Fri Jul 15 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.208-1
367 - require the -lib subpackage by -devel
368 - copy GPG keys from /etc/pki/rpm-gpg/
370 * Fri Apr 15 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.206-1
371 - added patches to make yum work in chroot environments
374 * Thu Mar 24 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.205-0
375 - added some %%descriptions
376 - copy GPG keys from the system into the confdir
377 - buildrequire dietlibc-0.25
378 - BuildRequire beecrypt-devel
380 - use %%global instead of %%define
381 - removed 'run.rev' as a vserver-local variable and made it a system-wide setting
383 * Wed Jan 26 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.198-0.3
384 - updated BuildRequires:
385 - use 'setattr --barrier' instead of 'chattr +t' in the %%post scriptlet
386 - moved the v_* initscripts to legacy
387 - do not ship the /vservers directory itself; as it is immutable, the
388 extraction will fail else
390 * Thu Sep 9 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.30.194-0
391 - documented switches for 'rpmbuild'
393 * Wed May 26 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.29.215-0
394 - (re)added the MANIFEST_* variables which were lost some time ago;
395 this will preserve %%config files...
397 * Mon Mar 15 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.29.202-0
398 - use file-list for sysv scripts also
400 * Sat Mar 6 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.29.198-0
401 - added vprocunhide-service support
402 - added doxygen support
405 * Wed Oct 1 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0:0.23.5-0