Add extra templates and split them into a new package
This commit is contained in:
parent
d845a18d78
commit
6cea8553d0
Binary file not shown.
48
lxc.spec
48
lxc.spec
@ -17,6 +17,7 @@ License: LGPLv2+ and GPLv2
|
|||||||
URL: https://linuxcontainers.org/lxc
|
URL: https://linuxcontainers.org/lxc
|
||||||
Source0: https://linuxcontainers.org/downloads/%{name}/%{name}-%{version}.tar.gz
|
Source0: https://linuxcontainers.org/downloads/%{name}/%{name}-%{version}.tar.gz
|
||||||
Source1: lxc-net
|
Source1: lxc-net
|
||||||
|
Source2: https://git.shrug.pw/neil/lxc-templates/archive/v1.0.0.tar.gz
|
||||||
Patch0: lxc-2.0.7-fix-init.patch
|
Patch0: lxc-2.0.7-fix-init.patch
|
||||||
Patch1: lxc-4.0.1-fix-lxc-net.patch
|
Patch1: lxc-4.0.1-fix-lxc-net.patch
|
||||||
BuildRequires: make
|
BuildRequires: make
|
||||||
@ -91,6 +92,17 @@ overhead of full virtualization.
|
|||||||
|
|
||||||
The %{name}-templates package contains templates for creating containers.
|
The %{name}-templates package contains templates for creating containers.
|
||||||
|
|
||||||
|
%package templates-extra
|
||||||
|
Summary: Extra Templates for %{name}
|
||||||
|
Requires: %{name}-templates%{?_isa} = %{version}-%{release}
|
||||||
|
|
||||||
|
%description templates-extra
|
||||||
|
Linux Resource Containers provide process and resource isolation without the
|
||||||
|
overhead of full virtualization.
|
||||||
|
|
||||||
|
The %{name}-templates-extra package contains extra templates for creating containers
|
||||||
|
previously available in the lxc-templates package, but are now considered
|
||||||
|
legacy.
|
||||||
|
|
||||||
%package devel
|
%package devel
|
||||||
Summary: Development files for %{name}
|
Summary: Development files for %{name}
|
||||||
@ -116,7 +128,6 @@ This package contains documentation for %{name}.
|
|||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n %{name}-%{version}
|
%autosetup -p1 -n %{name}-%{version}
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
autoreconf -vif
|
autoreconf -vif
|
||||||
%configure --with-distro=fedora \
|
%configure --with-distro=fedora \
|
||||||
@ -141,6 +152,15 @@ autoreconf -vif
|
|||||||
%{make_build}
|
%{make_build}
|
||||||
|
|
||||||
|
|
||||||
|
# build extra templates
|
||||||
|
tar -xf %{SOURCE2}
|
||||||
|
cd lxc-templates/
|
||||||
|
autoreconf -vif
|
||||||
|
%configure
|
||||||
|
|
||||||
|
%{make_build}
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%{make_install}
|
%{make_install}
|
||||||
mkdir -p %{buildroot}%{_sharedstatedir}/%{name}
|
mkdir -p %{buildroot}%{_sharedstatedir}/%{name}
|
||||||
@ -159,8 +179,15 @@ rm -rf %{buildroot}%{_libdir}/liblxc.la
|
|||||||
# lxc-net config file
|
# lxc-net config file
|
||||||
cp -a %{SOURCE1} %{buildroot}%{_sysconfdir}/sysconfig/%{name}-net
|
cp -a %{SOURCE1} %{buildroot}%{_sysconfdir}/sysconfig/%{name}-net
|
||||||
|
|
||||||
|
# lxc-templates from github
|
||||||
|
cd lxc-templates
|
||||||
|
%{make_install}
|
||||||
|
ls -v
|
||||||
|
|
||||||
%check
|
%check
|
||||||
make check
|
make check
|
||||||
|
cd lxc-templates
|
||||||
|
make check
|
||||||
|
|
||||||
|
|
||||||
%post libs
|
%post libs
|
||||||
@ -239,10 +266,27 @@ make check
|
|||||||
|
|
||||||
|
|
||||||
%files templates
|
%files templates
|
||||||
|
%{_datadir}/%{name}/templates/lxc-busybox
|
||||||
|
%{_datadir}/%{name}/templates/lxc-download
|
||||||
|
%{_datadir}/%{name}/templates/lxc-local
|
||||||
|
%{_datadir}/%{name}/templates/lxc-oci
|
||||||
|
%{_datadir}/%{name}/config/common*
|
||||||
|
%{_datadir}/%{name}/config/userns.conf
|
||||||
|
%{_datadir}/%{name}/config/nesting.conf
|
||||||
|
%{_datadir}/%{name}/config/oci.common.conf
|
||||||
|
|
||||||
|
%files templates-extra
|
||||||
|
%exclude %{_datadir}/%{name}/templates/lxc-busybox
|
||||||
|
%exclude %{_datadir}/%{name}/templates/lxc-download
|
||||||
|
%exclude %{_datadir}/%{name}/templates/lxc-local
|
||||||
|
%exclude %{_datadir}/%{name}/templates/lxc-oci
|
||||||
|
%exclude %{_datadir}/%{name}/config/common*
|
||||||
|
%exclude %{_datadir}/%{name}/config/userns.conf
|
||||||
|
%exclude %{_datadir}/%{name}/config/nesting.conf
|
||||||
|
%exclude %{_datadir}/%{name}/config/oci.common.conf
|
||||||
%{_datadir}/%{name}/templates/lxc-*
|
%{_datadir}/%{name}/templates/lxc-*
|
||||||
%{_datadir}/%{name}/config/*
|
%{_datadir}/%{name}/config/*
|
||||||
|
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%{_libdir}/pkgconfig/%{name}.pc
|
%{_libdir}/pkgconfig/%{name}.pc
|
||||||
%{_includedir}/lxc
|
%{_includedir}/lxc
|
||||||
|
1
sources
1
sources
@ -1 +1,2 @@
|
|||||||
SHA512 (lxc-4.0.10.tar.gz) = ec3ccf344a91b50b30985562c54ad93d2db2d29c24d31da8e3a69e801c8bd23c1560274c1850c39eb7e984940ba86d3ebae75db136320d6bbc5eb03bda4c5318
|
SHA512 (lxc-4.0.10.tar.gz) = ec3ccf344a91b50b30985562c54ad93d2db2d29c24d31da8e3a69e801c8bd23c1560274c1850c39eb7e984940ba86d3ebae75db136320d6bbc5eb03bda4c5318
|
||||||
|
SHA512 (v1.0.0.tar.gz) = 6e0f4502097fac489010f70d9a99254d78e395534f7633fd05e0f5c26e9714a13d4930147e2cada0ba4c3c860410668bab1f652267a60f6ad06f12e5d6a8668a
|
||||||
|
Loading…
Reference in New Issue
Block a user