[opensuse-buildservice] use kiwi result as build-requirement
Hi, Is it possible to use kiwi build products as build-requirements for rpm builds? I would like to do the following: get rootfs tar.gz of some kiwi build, repack it into /var/lib/container/myservice and utilize systemd-nspawn. So, effectively, I will get an rpm with the service which I will be able to install, enable and run as following: zypper in myservice systemctl enable systemd-nspawn@myservice.service systemctl start systemd-nspawn@myservice.service This is only an idea for private use, of course, I am not going to do that with real services. -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
On Samstag, 30. August 2014, 20:12:35 wrote Matwey V. Kornilov:
Hi,
Is it possible to use kiwi build products as build-requirements for rpm builds?
Not directly. But what you can do is providing a wrapper script, which is using a hook at the end of the kiwi build and packages the resulting files into an rpm. That one can be used as any other rpm afterwards inside of OBS. To create such a hook, you need to write a script and package it as /usr/lib/build/kiwi_post_run executable. When this file is installed during kiwi builds (eg. via Support: $your_package line in prjconf), it is executed at the end of the kiwi build. The script needs to build the rpm, eg. via calling rpmbuild and placing the result into $TOPDIR/OTHER/ directory. ($TOPDIR should be set in the environment) You should create an own repository in your project to build this and configure it in your prjconf like this: %if "%_repository" == "images-rpm" Type: kiwi Repotype: rpm-md Patterntype: none Support: kiwi-post-run-package %endif -- Adrian Schroeter email: adrian@suse.de SUSE LINUX GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 21284 (AG Nürnberg) Maxfeldstraße 5 90409 Nürnberg Germany -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
participants (2)
-
Adrian Schröter
-
Matwey V. Kornilov