X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=bootstrapfs.spec;h=90d07d37270b8a0ce49575e90aaf21a8ee2514bb;hb=296b3d4af2f78b2f8c401748685b6cdf1b8dfcd7;hp=fb9515ad2c9d9860c3db4abdf939fb28131d1d01;hpb=3d27c3a2baa7740915560a5bff45e41e401d2774;p=bootstrapfs.git diff --git a/bootstrapfs.spec b/bootstrapfs.spec index fb9515a..90d07d3 100644 --- a/bootstrapfs.spec +++ b/bootstrapfs.spec @@ -32,6 +32,10 @@ BuildArch: noarch Requires: tar, gnupg, sharutils, bzip2 +# 5.0 now has 3-fold nodefamily +%define obsolete_nodefamily %{pldistro}-%{_arch} +Obsoletes: bootstrapfs-%{obsolete_nodefamily} + AutoReqProv: no %define debug_package %{nil} @@ -46,6 +50,15 @@ Group: System Environment/Base %description plain This package provides the same functions as %{name} but with uncompressed tarball for faster tests. +%package -n nodeyum +Summary: the MyPLC-side utilities for tweaking nodes yum configs +Group: System Environment/Base +%description -n nodeyum +Utility scripts for configuring node updates. This package is designed +for the MyPLC side. +# need the apache user at install-time +Requires: httpd + %prep %setup -q @@ -54,6 +67,31 @@ pushd BootstrapFS ./build.sh %{pldistro} popd BootstrapFS +# xxx in a multi-flavour myplc, we should ship for all fcdistros +# and let the php scripts do the right thing + +pushd BootstrapFS/nodeconfig/yum + +# expand list of kexcludes + +# scan fcdistros and catenate all repos in 'stock.repo' so db-config can be distro-independant + +for fcdistro in $(ls); do + [ -d $fcdistro ] || continue + KEXCLUDE="exclude=$(../../../build/getkexcludes.sh -f $fcdistro)" + pushd $fcdistro/yum.myplc.d + echo "* Handling KEXCLUDE in yum repo for $fcdistro ($KEXCLUDE)" + for filein in $(find . -name '*.in') ; do + file=$(echo $filein | sed -e "s,\.in$,,") + sed -e "s,@KEXCLUDE@,$KEXCLUDE,g" $filein > $file + done + rm -f stock.repo + cat *.repo > stock.repo + popd +done + +popd + %install rm -rf $RPM_BUILD_ROOT @@ -72,12 +110,28 @@ for pkgs in $(ls ../build/config.%{pldistro}/bootstrapfs-*.pkgs) ; do install -D -m 644 %{pldistro}-filesystems/bootstrapfs-${NAME}-%{extensionfamily}.tar \ $RPM_BUILD_ROOT/var/www/html/boot/bootstrapfs-${NAME}-%{extensionfamily}.tar done +popd +pushd BootstrapFS/nodeconfig/yum +echo "* Installing MyPLC-side yum stuff" +# expose (fixed) myplc.repo.php as https:///yum/myplc.repo.php +install -D -m 644 ./yum/myplc.repo.php $RPM_BUILD_ROOT/var/www/html/yum/myplc.repo.php +# expose the fcdistro-dependant yum.conf as https:///yum/yum.conf +install -D -m 644 ./yum/%{distroname}/yum.conf $RPM_BUILD_ROOT/var/www/html/yum/yum.conf +# expose the (fcdistro-dependant) stock.repo as https:///yum/stock.repo +install -D -m 644 ./yum/%{distroname}/yum.myplc.d/stock.repo $RPM_BUILD_ROOT/var/www/html/yum/stock.repo popd %clean rm -rf $RPM_BUILD_ROOT +%post -n nodeyum +# the boot manager upload area +mkdir -p /var/log/bm +chown apache:apache /var/log/bm +chmod 700 /var/log/bm + + %files %defattr(-,root,root,-) /var/www/html/boot/bootstrapfs*.tar.bz2 @@ -86,6 +140,10 @@ rm -rf $RPM_BUILD_ROOT %defattr(-,root,root,-) /var/www/html/boot/bootstrapfs*.tar +%files -n nodeyum +%defattr(-,root,root,-) +/var/www/html/yum + %changelog * Mon Jan 04 2010 Thierry Parmentelat - BootstrapFS-1.0-11 - for building on fedora12