Compare commits

...
Sign in to create a new pull request.

30 commits

Author SHA1 Message Date
Christian Kellner
3c646f0775 28 upstream release
New upstream release with fixes for the oci stage and official
support for the Fedora 35 runner.
2021-04-08 21:42:24 +02:00
Christian Kellner
9469b5a47f Include patch to add Fedora 35 runner
Needed to actually run on rawhide (fedora 35).
2021-03-17 14:20:48 +01:00
Christian Kellner
cea5f05f10 ci: fix and update image test
Use an up-to-date manifest from the upstream osbuild CI test data
and also specify an output directory, so that osbuild is actually
attempting to produce an image.
2021-03-17 14:20:41 +01:00
Christian Kellner
60d5074f71 27 upstream release
Various bug fixes related to the new container and installer stages
introdcued in version 25 and 26.
2021-03-17 14:20:23 +01:00
Christian Kellner
9962c482ea 26 upstream release
Support for building boot isos.
Grub stage gained support for 'saved_entry' to fix grub tooling.
2021-02-20 16:57:21 +01:00
Christian Kellner
9999f9a3e1 gating: actually make an image in the 'image' test
As of some versions ago, osbuild, when neither --output-directory
nor --checkpoints are given, does not actually build anything.
This is obviously not what we want. We want images. So do specify
an output directory.
2021-02-20 16:57:21 +01:00
Christian Kellner
543fa936fe 25 upstream release
New upstream release, with a tech preview of the new manifest
format and new assembler-like stages that are needed to deliver
ostree commits contained in an oci archive.
2021-02-13 18:46:42 +01:00
Christian Kellner
bf1d4d4ec4 24 upstream release
Only disable dependency generator for runners but not other modules.
Include new `Input` binaries.
2021-01-28 07:10:42 +01:00
Christian Kellner
7b50676daa 23 upstream release
Do not mangle shebangs for assemblers, runners & stages.
2020-11-02 10:14:47 +01:00
Christian Kellner
e97cc4a0be 22 upstream release
no spec file changes.
2020-10-12 16:20:49 +02:00
Christian Kellner
7673a6b53d 21 upstream release 2020-09-10 15:16:02 +02:00
Christian Kellner
d156c25f6a 20 upstream release 2020-08-13 18:51:48 +02:00
Christian Kellner
bc974b503e 19 upstream release
Sandboxing mechanism changed from systemd-nspawn to bubblewrap,
change requirements accordingly.
Drop no-floats-in-sources.patch, included in the release.
2020-08-07 14:09:59 +02:00
Christian Kellner
2dd649c19a Add a patch to not use floats in sources
Do not pass floats to curl, because the format of the float is
locale specific (comma vs dot) but curl only likes dots. See
the patch for details.
2020-06-26 14:06:53 +02:00
Christian Kellner
eb55a2ed91 18 upstream release
All RHEL runners use platform-python now.
2020-06-23 20:31:14 +02:00
Christian Kellner
97f0294fad 17 upstream release
Add a custom SELinux policy, shipped in a new osbuild-selinux sub-
package, to allow setting labels unknown to the host.
2020-06-15 15:10:18 +02:00
Christian Kellner
ab731274fa 16 upstream release
Drop sources-fix-break-when-secrets-is-None.patch patch included
upstream.
2020-06-05 10:27:48 +02:00
Christian Kellner
8d98b3a9e1 Patch added to allow new files source format
Add a patch to allow org.osbuild.files source in the new format
but without actually containing the secrets key.
Taken from merged PR: https://github.com/osbuild/osbuild/pull/416
2020-05-26 19:24:07 +02:00
Christian Kellner
4521b200e3 15 upstream release
no spec file changes.
2020-05-21 11:18:34 +02:00
Christian Kellner
7e852a83af gating: don't gate on dist.*
Taskotron is End-of-Life since 2020-04-30 and thus we don't have
any dist.* checks; at least for now. Remove it.

https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/TRQZCXI5IZH3GLJTCO56SMBX5UY6J6LL/
2020-05-21 11:18:34 +02:00
Christian Kellner
9055276fb8 Install schemata
Install schemata to <datadir>/osbuild/schemas and include a
symlink to it in /usr/lib/osbuild/schemas.
This is needed otherwise schema validation will not work.
2020-05-06 21:12:53 +02:00
Christian Kellner
92cab38ab9 14 upstream release
Remove the /usr/lib/osbuild/{assemblers, stages}/osbuild dirs.
NB: Release 13 got skipped since it replaced aforementioned
directories with symlinks and that would have required a
%pretrans script. osbuild was adjusted to use a different
mechanism to locate the osbuild module inside the container
rendering the symlinks (or 'osbuild' directories) obsolete.
2020-05-06 20:38:59 +02:00
Christian Kellner
d2ccc6bc67 tests: adjust image test name
The sample file got renamed: base-rpm-qcow2.json → base-qcow2.json
Do the same in the test or gating will file.
2020-04-15 21:14:07 +02:00
Christian Kellner
48c5a095e3 12 upstream release
Specify the exact version in the 'python3-osbuild' requirement
to avoid the library and the main binary being out of sync.
Add osbuild-ostree sub-package with the necessary bits to create
OSTree based images.
2020-04-15 20:50:47 +02:00
Christian Kellner
0d155515aa gating: drop dist.depcheck
Although mentioned in the docs, this check is obsolete[1] but the
replacement[2] seems to be not running as well, so just drop that
check.

[1] https://fedoraproject.org/wiki/Taskotron/Tasks/dist.depcheck
[2] https://fedoraproject.org/wiki/Taskotron/Tasks/dist.rpmdeplint
2020-04-02 15:57:29 +02:00
Christian Kellner
e29a02c3a9 tests: try to actually build an image
Run osbuild and try to build one of the samples provided, i.e.
source/samples/base-rpm-qcow2.json.
2020-04-02 15:56:37 +02:00
Christian Kellner
9a1dd6bb50 11 upstream release
Turn of dependency generator for internal components since those
were generating a dependency for python3.6 due to the rhel runner.
2020-04-02 14:08:21 +02:00
Christian Kellner
e8c93925f1 ci: add smoke test and enable gating
Add a simple smoke test that currently just executes osbuild with
the '--help' option to check that it can run at all.
Gate for rawhide (via bodhi_update_push_stable) and for stable
(via bodhi_update_push_testing) on a minimum of dist checks as
well as the smoke test above.
2020-04-02 14:08:13 +02:00
Christian Kellner
104ca312c0 10 upstream release
Following changes:
  - build and include man pages, this adds 'make' and
    'python3-docutils' to the build requirements
  - add NEWS.md file with the release notes

Minor whitespace cleanups and correction of the previous changelog
entry that had the wrong version number.
2020-03-19 10:07:37 +01:00
Christian Kellner
69ddb9d523 9 upstream release
- Remove host runner links, now being auto-detected
- Cleanup spec file to not mix spaces and tabs
2020-03-05 13:45:47 +01:00
5 changed files with 277 additions and 35 deletions

20
.gitignore vendored
View file

@ -6,3 +6,23 @@
/6.tar.gz
/7.tar.gz
/osbuild-8.tar.gz
/osbuild-9.tar.gz
/osbuild-10.tar.gz
/osbuild-11.tar.gz
/osbuild-12.tar.gz
/osbuild-13.tar.gz
/osbuild-14.tar.gz
/osbuild-15.tar.gz
/osbuild-16.tar.gz
/osbuild-17.tar.gz
/osbuild-18.tar.gz
/osbuild-19.tar.gz
/osbuild-20.tar.gz
/osbuild-21.tar.gz
/osbuild-22.tar.gz
/osbuild-23.tar.gz
/osbuild-24.tar.gz
/osbuild-25.tar.gz
/osbuild-26.tar.gz
/osbuild-27.tar.gz
/osbuild-28.tar.gz

12
gating.yaml Normal file
View file

@ -0,0 +1,12 @@
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_testing
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_stable
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

View file

@ -1,6 +1,7 @@
%global forgeurl https://github.com/osbuild/osbuild
%global forgeurl https://github.com/osbuild/osbuild
%global selinuxtype targeted
Version: 8
Version: 28
%forgemeta
@ -17,21 +18,43 @@ Source0: %{forgesource}
BuildArch: noarch
Summary: A build system for OS images
BuildRequires: make
BuildRequires: python3-devel
BuildRequires: python3-docutils
Requires: bash
Requires: coreutils
Requires: curl
Requires: dnf
Requires: e2fsprogs
Requires: glibc
Requires: policycoreutils
Requires: qemu-img
Requires: systemd
Requires: systemd-container
Requires: tar
Requires: util-linux
Requires: python3-%{pypi_name}
Requires: bash
Requires: bubblewrap
Requires: coreutils
Requires: curl
Requires: dnf
Requires: e2fsprogs
Requires: glibc
Requires: policycoreutils
Requires: qemu-img
Requires: systemd
Requires: tar
Requires: util-linux
Requires: python3-%{pypi_name} = %{version}-%{release}
Requires: (%{name}-selinux if selinux-policy-%{selinuxtype})
# Turn off dependency generators for runners. The reason is that runners are
# tailored to the platform, e.g. on RHEL they are using platform-python. We
# don't want to pick up those dependencies on other platform.
%global __requires_exclude_from ^%{pkgdir}/(runners)/.*$
# Turn off shebang mangling on RHEL. brp-mangle-shebangs (from package
# redhat-rpm-config) is run on all executables in a package after the `install`
# section runs. The below macro turns this behavior off for:
# - runners, because they already have the correct shebang for the platform
# they're meant for, and
# - stages and assemblers, because they are run within osbuild build roots,
# which are not required to contain the same OS as the host and might thus
# have a different notion of "platform-python".
# RHEL NB: Since assemblers and stages are not excluded from the dependency
# generator, this also means that an additional dependency on /usr/bin/python3
# will be added. This is intended and needed, so that in the host build root
# /usr/bin/python3 is present so stages and assemblers can be run.
%global __brp_mangle_shebangs_exclude_from ^%{pkgdir}/(assemblers|runners|stages)/.*$
%{?python_enable_dependency_generator}
@ -42,14 +65,44 @@ A build system for OS images
Summary: %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}
%description -n python3-%{pypi_name}
%description -n python3-%{pypi_name}
A build system for OS images
%package ostree
Summary: OSTree support
Requires: %{name} = %{version}-%{release}
Requires: ostree
Requires: rpm-ostree
%description ostree
Contains the necessary stages, assembler and source
to build OSTree based images.
%package selinux
Summary: SELinux policies
Requires: %{name} = %{version}-%{release}
BuildRequires: selinux-policy
BuildRequires: selinux-policy-devel
%{?selinux_requires}
%description selinux
Contains the necessary SELinux policies that allows
osbuild to use labels unknown to the host inside the
containers it uses to build OS artifacts.
%prep
%forgesetup
%build
%py3_build
make man
# SELinux
make -f /usr/share/selinux/devel/Makefile osbuild.pp
bzip2 -9 osbuild.pp
%pre
%selinux_relabel_pre -s %{selinuxtype}
%install
%py3_install
@ -66,23 +119,26 @@ install -p -m 0755 $(find runners -type f -or -type l) %{buildroot}%{pkgdir}/run
mkdir -p %{buildroot}%{pkgdir}/sources
install -p -m 0755 $(find sources -type f) %{buildroot}%{pkgdir}/sources
# mount points for bind mounting the osbuild library
mkdir -p %{buildroot}%{pkgdir}/stages/osbuild
mkdir -p %{buildroot}%{pkgdir}/assemblers/osbuild
mkdir -p %{buildroot}%{pkgdir}/inputs
install -p -m 0755 $(find inputs -type f) %{buildroot}%{pkgdir}/inputs
# install host runner
%if 0%{?fc30}
ln -s org.osbuild.fedora30 %{buildroot}%{pkgdir}/runners/org.osbuild.host
%endif
%if 0%{?fc31}
ln -s org.osbuild.fedora31 %{buildroot}%{pkgdir}/runners/org.osbuild.host
%endif
%if 0%{?fc32}
ln -s org.osbuild.fedora32 %{buildroot}%{pkgdir}/runners/org.osbuild.host
%endif
%if 0%{?el8}
ln -s org.osbuild.rhel82 %{buildroot}%{pkgdir}/runners/org.osbuild.host
%endif
# mount point for bind mounting the osbuild library
mkdir -p %{buildroot}%{pkgdir}/osbuild
# schemata
mkdir -p %{buildroot}%{_datadir}/osbuild/schemas
install -p -m 0755 $(find schemas/*.json) %{buildroot}%{_datadir}/osbuild/schemas
ln -s %{_datadir}/osbuild/schemas %{buildroot}%{pkgdir}/schemas
# documentation
mkdir -p %{buildroot}%{_mandir}/man1
mkdir -p %{buildroot}%{_mandir}/man5
install -p -m 0644 -t %{buildroot}%{_mandir}/man1/ docs/*.1
install -p -m 0644 -t %{buildroot}%{_mandir}/man5/ docs/*.5
# SELinux
install -D -m 644 -t %{buildroot}%{_datadir}/selinux/packages/%{selinuxtype} %{name}.pp.bz2
install -D -m 644 -t %{buildroot}%{_mandir}/man8 selinux/%{name}_selinux.8
%check
exit 0
@ -92,15 +148,149 @@ exit 0
%files
%license LICENSE
%{_bindir}/osbuild
%{_mandir}/man1/%{name}.1*
%{_mandir}/man5/%{name}-manifest.5*
%{_datadir}/osbuild/schemas
%{pkgdir}
# the following files are in the ostree sub-package
%exclude %{pkgdir}/assemblers/org.osbuild.ostree.commit
%exclude %{pkgdir}/sources/org.osbuild.ostree
%exclude %{pkgdir}/stages/org.osbuild.ostree
%exclude %{pkgdir}/stages/org.osbuild.rpm-ostree
%files -n python3-%{pypi_name}
%files -n python3-%{pypi_name}
%license LICENSE
%doc README.md
%doc README.md NEWS.md
%{python3_sitelib}/%{pypi_name}-*.egg-info/
%{python3_sitelib}/%{pypi_name}/
%files ostree
%{pkgdir}/assemblers/org.osbuild.ostree.commit
%{pkgdir}/sources/org.osbuild.ostree
%{pkgdir}/stages/org.osbuild.ostree
%{pkgdir}/stages/org.osbuild.rpm-ostree
%files selinux
%{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2
%{_mandir}/man8/%{name}_selinux.8.*
%ghost %{_sharedstatedir}/selinux/%{selinuxtype}/active/modules/200/%{name}
%post selinux
%selinux_modules_install -s %{selinuxtype} %{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2
%postun selinux
if [ $1 -eq 0 ]; then
%selinux_modules_uninstall -s %{selinuxtype} %{name}
fi
%posttrans selinux
%selinux_relabel_post -s %{selinuxtype}
%changelog
* Thu Apr 8 2021 Christian Kellner <ckellner@redhat.com> - 28-1
- Upstream release 28
- Drop Fedora 35 runner patch incldued in release 28.
* Wed Mar 17 2021 Christian Kellner <ckellner@redhat.com> - 27-2
- Include Fedora 35 runner (upstream commit 337e0f0)
* Tue Mar 16 2021 Christian Kellner <ckellner@redhat.com> - 27-1
- Upstream release 27
- Various bug fixes related to the new container and installer
stages introdcued in version 25 and 26.
* Sat Feb 20 2021 Christian Kellner <ckellner@redhat.com> - 26-1
- Upstream release 26
- Support for building boot isos
- Grub stage gained support for 'saved_entry' to fix grub tooling
* Fri Feb 12 2021 Christian Kellner <ckellner@redhat.com> - 25-1
- Upstream release 25
- First tech preview of the new manifest format. Includes
various new stages and inputs to be able to build ostree
commits contained in a oci archive.
* Thu Jan 28 2021 Christian Kellner <ckellner@redhat.com> - 24-1
- Upstream release 24
- Turn on dependency generator for everything but runners
- Include new 'input' binaries
* Fri Oct 23 2020 Christian Kellner <ckellner@redhat.com> - 23-1
- Upstream release 23
- Do not mangle shebangs for assemblers, runners & stages.
* Mon Oct 12 2020 Christian Kellner <ckellner@redhat.com> - 22-1
- Upstream release 22
* Thu Sep 10 2020 Christian Kellner <ckellner@redhat.com> - 21-1
- Upstream reelase 21
* Thu Aug 13 2020 Christian Kellner <ckellner@redhat.com> - 20-1
- Upstream reelase 20
* Fri Aug 7 2020 Christian Kellner <ckellner@redhat.com> - 19-1
- Upstream release 19
- Drop no-floats-in-sources.patch included in release 19
- bubblewrap replaced systemd-nspawn for sandboxing; change the
requirements accordingly.
* Fri Jun 26 2020 Christian Kellner <ckellner@redhat.com> - 18-2
- Add patch to not pass floats to curl in the files source
https://github.com/osbuild/osbuild/pull/459
* Tue Jun 23 2020 Christian Kellner <ckellner@redhat.com> - 18-1
- Upstream release 18
- All RHEL runners now use platform-python.
* Wed Jun 10 2020 Christian Kellner <ckellner@redhat.com> - 17-1
- new upstream relaese 17
- Add custom SELinux policy that lets osbuild set labels inside
the build root that are unknown to the host.
* Thu Jun 4 2020 Christian Kellner <ckellner@redhat.com> - 16-1
- new upstream release 16
- Drop sources-fix-break-when-secrets-is-None.patch included in
the new upstream reelase.
* Tue May 26 2020 Christian Kellner <ckellner@redhat.com> - 15-2
- Add a patch to allow org.osbuild.files source in the new format
but without actually containing the secrets key.
Taken from merged PR: https://github.com/osbuild/osbuild/pull/416
* Thu May 21 2020 Christian Kellner <ckellner@redhat.com> - 15-1
- new upstream release 15
* Wed May 6 2020 Christian Kellner <christian@kellner.me> - 14-2
- Install schemata to <datadir>/osbuild/schemas and include a
symlink to it in /usr/lib/osbuild/schemas
* Wed May 6 2020 Christian Kellner <christian@kellner.me> - 14-1
- new upstream release 14
- The directories /usr/lib/osbuild/{assemblers, stages}/osbuild
got removed. Changes to osbuild made them obsolete.
* Wed Apr 15 2020 Christian Kellner <ckellner@redhat.com> - 12-1
- new upstream release 12
- Specify the exact version in the 'python3-osbuild' requirement
to avoid the library and the main binary being out of sync.
- osbuild-ostree sub-package with the necessary bits to create
OSTree based images
* Thu Apr 2 2020 Christian Kellner <ckellner@redhat.com> - 11-1
- new upstream release 11
- Turn of dependency generator for internal components
* Thu Mar 19 2020 Christian Kellner <ckellner@redhat.com> - 10-1
- new upstream release 10
- build and include man pages, this adds 'make' and 'python3-docutils'
to the build requirements
- add NEWS.md file with the release notes
* Thu Mar 5 2020 Christian Kellner <ckellner@redhat.com> - 9-1
- new upstream release: 9
- Remove host runner link, it now is being auto-detected
- Cleanup use of mixed use of spaces/tabs
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 7-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild

View file

@ -1 +1 @@
SHA512 (osbuild-8.tar.gz) = c553f6599149e29f3d299a22e9aa543163af38cdd0a5e17530c89c536436c1bc0278166a3bea036b470d5ce7beca5cfca936c5e77c21661c26a0ca85e4c14304
SHA512 (osbuild-28.tar.gz) = 855b6db566f9c0011e76d143f83183ae09a00e338ada241fc27f9412b20f37ff36692ec30b28dc9542eb457ea2a4fbd0e351821270b5d79a870f697a686e0d88

20
tests/tests.yml Normal file
View file

@ -0,0 +1,20 @@
---
- hosts: localhost
roles:
- role: standard-test-source
tags:
- always
- role: standard-test-basic
tags:
- atomic
- classic
required_packages:
- osbuild
tests:
- smoke:
dir: smoke
run: osbuild --help
- image:
dir: .
run: osbuild source/test/data/manifests/fedora-boot.json --output-directory=/var/tmp/osbuild