oops - fix numbers
[bootstrapfs.git] / slicerepo.spec
1 # build is expected to export the following rpm variables
2 # %{distroname}     : e.g. Fedora
3 # %{distrorelease}  : e.g. 8
4 # %{slice_rpms_plus} : as a +++ separated list of rpms from the build dir
5
6 %define nodefamily %{pldistro}-%{distroname}-%{_arch}
7 %define obsolete_nodefamily %{pldistro}-%{_arch}
8
9 %define name slicerepo-%{nodefamily}
10 %define version 2.1
11 %define taglevel 0
12
13 # pldistro already in the rpm name
14 #%define release %{taglevel}%{?pldistro:.%{pldistro}}%{?date:.%{date}}
15 %define release %{taglevel}%{?date:.%{date}}
16
17 # we don't really need the standard postinstall process from rpm that
18 # strips files and byte-compiles python files. all files in this
19 # package are comming from other rpm files and they've already went
20 # through this post install processing. - baris
21 %define __os_install_post %{nil}
22
23 Vendor: OneLab
24 Packager: PlanetLab Europe <build@onelab.eu>
25 Distribution: PlanetLab %{plrelease}
26 URL: %{SCMURL}
27
28 Summary: The yum repository for slices, to be installed on the myplc-side
29 Name: %{name}
30 Version: %{version}
31 Release: %{release}
32 License: BSD
33 Group: System Environment/Base
34 Source0: %{name}-%{version}.tar.gz
35 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
36 # other archs must be able to install this
37 BuildArch: noarch
38
39 BuildRequires: rsync 
40 Requires: myplc
41
42 %define debug_package %{nil}
43
44 %description
45 This rpm contains all the rpms that might ship on a sliver image
46 they come organized into a yum repository 
47
48 %prep
49 %setup -q
50
51 %build
52 echo nothing to do at build time for slicerepo
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56
57 repo=slice-%{nodefamily}
58 install -d -m 755 $RPM_BUILD_ROOT/var/www/html/install-rpms/$repo
59 rpms=$(echo %{slice_rpms_plus} | sed -e 's,+++, ,g')
60 for rpm in $rpms; do rsync %{_topdir}/$rpm $RPM_BUILD_ROOT/var/www/html/install-rpms/$repo/ ; done
61 ### yumgroups
62 install -D -m 644 %{_topdir}/RPMS/yumgroups.xml $RPM_BUILD_ROOT/var/www/html/install-rpms/$repo/yumgroups.xml
63 # do not do this yet, as plc.d/packages will do it anyway
64 #createrepo -g yumgroups.xml $RPM_BUILD_ROOT/var/www/html/install-rpms/$repo
65
66 %clean
67 rm -rf $RPM_BUILD_ROOT
68
69 %post
70 service plc start packages
71
72 %files
73 %defattr(-,root,root,-)
74 /var/www/html/install-rpms/slice-%{nodefamily}
75 # don't overwrite yumgroups.xml if exists
76 %config(noreplace) /var/www/html/install-rpms/slice-%{nodefamily}/yumgroups.xml
77
78 %changelog
79 * Thu Feb 16 2012 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-14
80 - changes needed for build with yumexcludes defined in a separate pkgs file
81
82 * Wed Aug 31 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-13
83 - plc.d/packages: rewrote comments about some corner cases where it fails
84 - plc.d/packages: marginally more robust
85
86 * Fri Jun 10 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-12
87 - minor tweak in plc.d/packages
88
89 * Mon Jun 06 2011 Baris Metin <bmetin@verivue.com> - bootstrapfs-2.0-11
90 - sl6 templates
91
92 * Thu Feb 17 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-10
93 - bugfix for multi-flavour deployments
94
95 * Fri Feb 04 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-9
96 - for multi-flavours : 'packages' step in plc.d now handles vserver links and related hacks in yumgroups
97
98 * Thu Jan 27 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-8
99 - no semantic change - attempt to speed up build
100
101 * Sun Jan 23 2011 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - bootstrapfs-2.0-7
102 - yum repo template for f14 nodes
103 - tweaks the way /etc/plc.d/packages works
104
105 * Mon Jul 05 2010 Baris Metin <Talip-Baris.Metin@sophia.inria.fr> - BootstrapFS-2.0-6
106 - add sha1sum
107 - module name changes
108
109 * Tue Apr 27 2010 Talip Baris Metin <Talip-Baris.Metin@sophia.inria.fr> - BootstrapFS-2.0-5
110 - support different flavours of vservers on nodes
111
112 * Mon Apr 12 2010 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - BootstrapFS-2.0-4
113 - fix unmatched $ in URL svn keywords
114
115 * Fri Apr 02 2010 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - BootstrapFS-2.0-3
116 - choice between various pldistros is not made at build time, but at run time
117 - relies on GetNodeFlavour to expose the node's fcdistro - requires PLCAPI-5.0-5
118 - in addition, the baseurl for the myplc repo is http:// and not https:// anymore
119 - the https method does not work on fedora 12, and GPG is used below anyway
120
121 * Fri Mar 12 2010 Thierry Parmentelat <thierry.parmentelat@sophia.inria.fr> - BootstrapFS-2.0-2
122 - new slicerepo package for exposing stuff to slivers
123