]> git.pld-linux.org Git - packages/lxc.git/blame - lxc.spec
also gnupg keys and hkp plugins for it to be usable
[packages/lxc.git] / lxc.spec
CommitLineData
8ba1db82 1# TODO
8ba1db82
ER
2# - package apparmor stuff
3
67c70229
JB
4# Conditional build:
5%bcond_without seccomp # SecComp syscall filter
ccd4948a 6%bcond_without apparmor # apparmor
67c70229
JB
7%bcond_without lua # Lua binding
8%bcond_without python # Python binding
120ac263 9%bcond_with selinux # SELinux
8ba1db82 10%bcond_with cgmanager # Enable cgmanager (BR: libcgmanager, libnih >= 1.0.2, libnih-dbus >= 1.0.0, dbus-1 >= 1.2.16)
21c5c666 11
247c2ba9 12Summary: Linux Containers userspace tools
67c70229 13Summary(pl.UTF-8): Narzędzia do kontenerów linuksowych (LXC)
0886a606 14Name: lxc
247c2ba9 15Version: 1.0.0
39773dac 16Release: 0.3
c34ce688 17License: LGPL v2.1+
67c70229 18Group: Applications/System
9db966c1
ER
19Source0: http://linuxcontainers.org/downloads/%{name}-%{version}.tar.gz
20# Source0-md5: 87a9d168a6e55326303cce3b2cb7f82e
adc39309 21Source1: %{name}-pld.in.sh
67c70229 22Patch1: %{name}-pld.patch
247c2ba9 23URL: http://linuxcontainers.org/
67c70229
JB
24BuildRequires: autoconf >= 2.50
25BuildRequires: automake
e5afa52e 26BuildRequires: docbook-dtd30-sgml
27BuildRequires: docbook-utils
21c5c666 28BuildRequires: docbook2X
7e4c14a6 29BuildRequires: gnutls-devel
ccd4948a 30%{?with_apparmor:BuildRequires: libapparmor-devel}
4e32c712 31BuildRequires: libcap-devel
67c70229
JB
32%{?with_seccomp:BuildRequires: libseccomp-devel}
33%{?with_lua:BuildRequires: lua51-devel >= 5.1}
34BuildRequires: pkgconfig
35%{?with_python:BuildRequires: python3-devel >= 3.2}
36BuildRequires: rpmbuild(macros) >= 1.612
c34ce688 37BuildRequires: sed >= 4.0
7e514b06 38Requires: rc-scripts >= 0.4.6
adc39309 39Requires: which
7f0b7e89 40Suggests: gnupg
16cf226e
ER
41Suggests: gnupg-plugin-keys_curl
42Suggests: gnupg-plugin-keys_hkp
21c5c666 43Suggests: net-tools
b335abc0 44Suggests: rsync
0886a606
AM
45BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
e5afa52e 47%define configpath /var/lib/lxc
48
0886a606
AM
49%description
50Tools to create and manage containers. It contains a full featured
51container with the isolation / virtualization of the pids, the ipc,
52the utsname, the mount points, /proc, /sys, the network and it takes
53into account the control groups. It is very light, flexible, and
54provides a set of tools around the container like the monitoring with
55asynchronous events notification, or the freeze of the container. This
56package is useful to create Virtual Private Server, or to run isolated
57applications like bash or sshd.
58
67c70229
JB
59%description -l pl.UTF-8
60Narzędzia do tworzenia i zarządzania kontenerami. System ten obejmuje
61w pełni funkcjonalne kontenery z ilozacją/wirtualizacją pidów, ipc,
62utsname, punktów montowania, /proc, /sys, sieci oraz uwzględniające
63grupy kontrolne. Jest bardzo lekki, elastyczny i udostępnia narzędzia
64do czynności związanych z kontenerami, takich jak monitorowanie z
65asynchronicznym powiadamianiem o zdarzeniach czy zamrażanie. Ten
66pakiet jest przydatny do tworzenia wirtualnych serwerów prywatnych
67oraz uruchamiania izolowanych aplikacji, takich jak bash czy sshd.
68
0886a606 69%package devel
67c70229
JB
70Summary: Header files for lxc library
71Summary(pl.UTF-8): Pliki nagłówkowe biblioteki lxc
0886a606 72Group: Development/Libraries
67c70229 73Requires: %{name} = %{version}-%{release}
0886a606
AM
74
75%description devel
67c70229
JB
76Header files for lxc library.
77
78%description devel -l pl.UTF-8
79Pliki nagłówkowe biblioteki lxc.
80
81%package -n lua-lxc
82Summary: Lua binding for LXC
83Summary(pl.UTF-8): Wiązanie Lua do LXC
84Group: Libraries
85Requires: %{name} = %{version}-%{release}
86Requires: lua51-libs >= 5.1
87
88%description -n lua-lxc
89Lua binding for LXC.
90
91%description -n lua-lxc -l pl.UTF-8
92Wiązanie Lua do LXC.
93
94%package -n python3-lxc
95Summary: Python (3.x) binding for LXC
96Summary(pl.UTF-8): Wiązanie Pythona (3.x) do LXC
97Group: Libraries
98Requires: %{name} = %{version}-%{release}
99Requires: python3-libs >= 3.2
91c8fae7 100Requires: python3-modules
67c70229
JB
101
102%description -n python3-lxc
103Python (3.x) binding for LXC.
104
105%description -n python3-lxc -l pl.UTF-8
106Wiązanie Pythona (3.x) do LXC.
0886a606 107
4e82464d
ER
108%package -n bash-completion-%{name}
109Summary: bash-completion for LXC
110Summary(pl.UTF-8): bashowe uzupełnianie nazw dla LXC
111Group: Applications/Shells
112Requires: %{name}
113Requires: bash-completion
114
115%description -n bash-completion-%{name}
116bash-completion for LXC.
117
118%description -n bash-completion-%{name} -l pl.UTF-8
119bashowe uzupełnianie nazw dla LXC.
120
0886a606 121%prep
9db966c1 122%setup -q
67c70229 123%patch1 -p1
0886a606 124
8a96554a
ER
125cp -p %{SOURCE1} templates/lxc-pld.in
126
0886a606 127%build
67c70229
JB
128%{__aclocal} -I config
129%{__autoconf}
130%{__autoheader}
131%{__automake}
e5afa52e 132%configure \
67c70229
JB
133 db2xman=docbook2X2man \
134 --disable-rpath \
8ba1db82 135 --enable-bash \
67c70229 136 --enable-doc \
120ac263 137 --enable-examples \
ccd4948a 138 %{__enable_disable apparmor} \
247c2ba9 139 %{__enable_disable lua} %{?with_lua:--with-lua-pc=lua51} \
ccd4948a
ER
140 %{__enable_disable python} \
141 %{__enable_disable seccomp} \
120ac263 142 %{__enable_disable selinux} \
67c70229 143 --with-config-path=%{configpath} \
8ba1db82 144 --with-init-script=sysvinit,systemd \
9db966c1 145 --with-runtime-path=/var/run \
67c70229 146 --with-distro=pld
0886a606
AM
147
148%{__make}
e5afa52e 149%{__make} -C doc
0886a606
AM
150
151%install
152rm -rf $RPM_BUILD_ROOT
39773dac 153install -d $RPM_BUILD_ROOT{%{configpath},%{configpath}snap,/var/{cache,log}/lxc}
0886a606 154%{__make} install \
7e4c14a6
ER
155 SYSTEMD_UNIT_DIR=%{systemdunitdir} \
156 pcdatadir=%{_pkgconfigdir} \
157 DESTDIR=$RPM_BUILD_ROOT
33aee790 158
e5afa52e 159%{__make} -C doc install \
0886a606 160 DESTDIR=$RPM_BUILD_ROOT
33aee790 161
21c5c666 162%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
0886a606 163
67c70229
JB
164%if %{with python}
165%py3_comp $RPM_BUILD_ROOT%{py3_sitedir}/lxc
166%py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}/lxc
167%endif
c34ce688
JB
168%if %{with lua}
169%{__sed} -i -e '1s,#!/usr/bin/env lua,#!/usr/bin/lua51,' $RPM_BUILD_ROOT%{_bindir}/lxc-top
170%endif
67c70229 171
0886a606
AM
172%clean
173rm -rf $RPM_BUILD_ROOT
174
67c70229
JB
175%post -p /sbin/ldconfig
176%postun -p /sbin/ldconfig
0886a606
AM
177
178%files
179%defattr(644,root,root,755)
247c2ba9 180%doc AUTHORS CONTRIBUTING MAINTAINERS README TODO doc/FAQ.txt doc/examples/*.conf
c34ce688 181%attr(755,root,root) %{_bindir}/lxc-attach
7e4c14a6 182%attr(755,root,root) %{_bindir}/lxc-autostart
c34ce688
JB
183%attr(755,root,root) %{_bindir}/lxc-cgroup
184%attr(755,root,root) %{_bindir}/lxc-checkconfig
c34ce688 185%attr(755,root,root) %{_bindir}/lxc-clone
247c2ba9 186%attr(755,root,root) %{_bindir}/lxc-config
c34ce688
JB
187%attr(755,root,root) %{_bindir}/lxc-console
188%attr(755,root,root) %{_bindir}/lxc-create
189%attr(755,root,root) %{_bindir}/lxc-destroy
190%attr(755,root,root) %{_bindir}/lxc-execute
191%attr(755,root,root) %{_bindir}/lxc-freeze
192%attr(755,root,root) %{_bindir}/lxc-info
c34ce688 193%attr(755,root,root) %{_bindir}/lxc-monitor
247c2ba9 194%attr(755,root,root) %{_bindir}/lxc-snapshot
c34ce688
JB
195%attr(755,root,root) %{_bindir}/lxc-start
196%attr(755,root,root) %{_bindir}/lxc-stop
197%attr(755,root,root) %{_bindir}/lxc-unfreeze
198%attr(755,root,root) %{_bindir}/lxc-unshare
120ac263 199%attr(755,root,root) %{_bindir}/lxc-usernsexec
c34ce688 200%attr(755,root,root) %{_bindir}/lxc-wait
e5afa52e 201%attr(755,root,root) %{_libdir}/liblxc.so.*.*.*
247c2ba9 202%attr(755,root,root) %ghost %{_libdir}/liblxc.so.1
7e4c14a6
ER
203%attr(754,root,root) /etc/rc.d/init.d/lxc
204%{systemdunitdir}/lxc.service
8ba1db82
ER
205%dir %{_libdir}/%{name}
206%dir %{_libdir}/%{name}/rootfs
207%{_libdir}/%{name}/rootfs/README
208%attr(755,root,root) %{_libdir}/%{name}/lxc-devsetup
209%attr(755,root,root) %{_libdir}/%{name}/lxc-init
210%attr(755,root,root) %{_libdir}/%{name}/lxc-monitord
211%attr(755,root,root) %{_libdir}/%{name}/lxc-user-nic
dc9a5b3b 212%dir %{_sysconfdir}/lxc
67c70229 213%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lxc/default.conf
120ac263 214%dir %{_datadir}/%{name}
f5933d47 215%{_datadir}/%{name}/lxc.functions
120ac263 216%dir %{_datadir}/%{name}/config
8ba1db82
ER
217%{_datadir}/%{name}/config/centos.*.conf
218%{_datadir}/%{name}/config/debian.*.conf
219%{_datadir}/%{name}/config/fedora.*.conf
3f7b319e 220%{_datadir}/%{name}/config/gentoo.*.conf
8ba1db82
ER
221%{_datadir}/%{name}/config/oracle.*.conf
222%{_datadir}/%{name}/config/plamo.*.conf
223%{_datadir}/%{name}/config/ubuntu-cloud.*.conf
224%{_datadir}/%{name}/config/ubuntu.*.conf
f5933d47
ER
225%dir %{_datadir}/%{name}/hooks
226%dir %{_datadir}/%{name}/templates
247c2ba9 227%attr(755,root,root) %{_datadir}/%{name}/hooks/clonehostname
7e4c14a6
ER
228%attr(755,root,root) %{_datadir}/%{name}/hooks/mount*
229%attr(755,root,root) %{_datadir}/%{name}/hooks/squid-deb-proxy-client
247c2ba9 230%attr(755,root,root) %{_datadir}/%{name}/hooks/ubuntu-cloud-prep
f5933d47 231%attr(755,root,root) %{_datadir}/%{name}/templates/lxc-*
c34ce688 232%{_mandir}/man1/lxc-attach.1*
7e4c14a6 233%{_mandir}/man1/lxc-autostart.1*
c34ce688
JB
234%{_mandir}/man1/lxc-cgroup.1*
235%{_mandir}/man1/lxc-checkconfig.1*
c34ce688 236%{_mandir}/man1/lxc-clone.1*
8ba1db82 237%{_mandir}/man1/lxc-config.1*
c34ce688
JB
238%{_mandir}/man1/lxc-console.1*
239%{_mandir}/man1/lxc-create.1*
240%{_mandir}/man1/lxc-destroy.1*
241%{_mandir}/man1/lxc-execute.1*
242%{_mandir}/man1/lxc-freeze.1*
243%{_mandir}/man1/lxc-info.1*
c34ce688 244%{_mandir}/man1/lxc-monitor.1*
247c2ba9 245%{_mandir}/man1/lxc-snapshot.1*
c34ce688
JB
246%{_mandir}/man1/lxc-start.1*
247%{_mandir}/man1/lxc-stop.1*
248%{_mandir}/man1/lxc-unfreeze.1*
249%{_mandir}/man1/lxc-unshare.1*
120ac263 250%{_mandir}/man1/lxc-user-nic.1*
8ba1db82 251%{_mandir}/man1/lxc-usernsexec.1*
c34ce688 252%{_mandir}/man1/lxc-wait.1*
120ac263 253%{_mandir}/man5/lxc-usernet.5*
67c70229 254%{_mandir}/man5/lxc.conf.5*
8ba1db82
ER
255%{_mandir}/man5/lxc.container.conf.5*
256%{_mandir}/man5/lxc.system.conf.5*
67c70229 257%{_mandir}/man7/lxc.7*
247c2ba9 258%lang(ja) %{_mandir}/ja/man1/lxc*.1*
7e4c14a6 259%lang(ja) %{_mandir}/ja/man5/lxc-usernet.5*
247c2ba9 260%lang(ja) %{_mandir}/ja/man5/lxc.conf.5*
8ba1db82
ER
261%lang(ja) %{_mandir}/ja/man5/lxc.container.conf.5*
262%lang(ja) %{_mandir}/ja/man5/lxc.system.conf.5*
247c2ba9
ER
263%lang(ja) %{_mandir}/ja/man7/lxc.7*
264%exclude %{_mandir}/ja/man1/lxc-device.1*
265%exclude %{_mandir}/ja/man1/lxc-ls.1*
266%exclude %{_mandir}/ja/man1/lxc-start-ephemeral.1*
267%exclude %{_mandir}/ja/man1/lxc-top.1*
268
c34ce688
JB
269%if %{without python}
270# legacy version
271%attr(755,root,root) %{_bindir}/lxc-ls
272%{_mandir}/man1/lxc-ls.1*
273%endif
0886a606 274
ff8ce371 275%dir %{configpath}
39773dac 276%dir %{configpath}snap
f10dfb13
ER
277%dir %attr(750,root,root) /var/log/lxc
278%dir %attr(750,root,root) /var/cache/lxc
ff8ce371 279
0886a606
AM
280%files devel
281%defattr(644,root,root,755)
0886a606 282%attr(755,root,root) %{_libdir}/liblxc.so
67c70229 283%{_includedir}/lxc
e5afa52e 284%{_pkgconfigdir}/lxc.pc
67c70229
JB
285
286%if %{with lua}
287%files -n lua-lxc
288%defattr(644,root,root,755)
c34ce688 289%attr(755,root,root) %{_bindir}/lxc-top
247c2ba9
ER
290%dir %{_libdir}/lua/lxc
291%attr(755,root,root) %{_libdir}/lua/lxc/core.so
292%{_datadir}/lua/lxc.lua
c34ce688 293%{_mandir}/man1/lxc-top.1*
247c2ba9 294%lang(ja) %{_mandir}/ja/man1/lxc-top.1*
67c70229
JB
295%endif
296
297%if %{with python}
298%files -n python3-lxc
299%defattr(644,root,root,755)
c34ce688
JB
300%attr(755,root,root) %{_bindir}/lxc-device
301%attr(755,root,root) %{_bindir}/lxc-ls
302%attr(755,root,root) %{_bindir}/lxc-start-ephemeral
67c70229
JB
303%{py3_sitedir}/lxc
304%attr(755,root,root) %{py3_sitedir}/_lxc.cpython-*.so
305%{py3_sitedir}/_lxc-0.1-py*.egg-info
c34ce688
JB
306%{_mandir}/man1/lxc-device.1*
307%{_mandir}/man1/lxc-ls.1*
308%{_mandir}/man1/lxc-start-ephemeral.1*
247c2ba9
ER
309%lang(ja) %{_mandir}/ja/man1/lxc-device.1*
310%lang(ja) %{_mandir}/ja/man1/lxc-ls.1*
311%lang(ja) %{_mandir}/ja/man1/lxc-start-ephemeral.1*
67c70229 312%endif
4e82464d
ER
313
314%files -n bash-completion-%{name}
315%defattr(644,root,root,755)
316/etc/bash_completion.d/lxc
This page took 0.075126 seconds and 4 git commands to generate.