Add coreos-installer-systemd subpackage

Systemd units and supporting executables were added upstream in
https://github.com/coreos/coreos-installer/pull/119. Let's add a
subpackage so we can deliver them in Fedora, but separate from the
main installer binary that people may want to execute outside of the
service.
This commit is contained in:
Dusty Mabe 2020-01-06 16:56:36 -05:00
parent d7a67be68a
commit 8107316311
No known key found for this signature in database
GPG Key ID: 3302DBD73952E671

View File

@ -20,6 +20,7 @@ Patch0: coreos-installer-fix-metadata.diff
ExclusiveArch: %{rust_arches} ExclusiveArch: %{rust_arches}
BuildRequires: rust-packaging BuildRequires: rust-packaging
BuildRequires: systemd-rpm-macros
%global _description %{expand: %global _description %{expand:
coreos-installer installs Fedora CoreOS or RHEL CoreOS to bare-metal coreos-installer installs Fedora CoreOS or RHEL CoreOS to bare-metal
@ -58,6 +59,25 @@ Obsoletes: coreos-installer-dracut < 0.0.1
%install %install
%cargo_install %cargo_install
# Install binaries, units, targets, generators for running via systemd
install -D -m 0750 -t %{buildroot}%{_libexecdir} systemd/coreos-installer-service
install -D -m 0644 -t %{buildroot}%{_unitdir} systemd/coreos-installer.service
install -D -m 0644 -t %{buildroot}%{_unitdir} systemd/coreos-installer-reboot.service
install -D -m 0644 -t %{buildroot}%{_unitdir} systemd/coreos-installer-noreboot.service
install -D -m 0644 -t %{buildroot}%{_unitdir} systemd/coreos-installer.target
install -D -m 0750 -t %{buildroot}%{_systemdgeneratordir} systemd/coreos-installer-generator
%package -n %{crate}-systemd
Summary: Systemd service files for %{crate}
Requires: %{crate} = %{version}-%{release}
%description -n %{crate}-systemd
Systemd service files for %{crate}
%files -n %{crate}-systemd
%{_libexecdir}/*
%{_unitdir}/*
%{_systemdgeneratordir}/*
%if %{with check} %if %{with check}
%check %check
@ -68,6 +88,8 @@ Obsoletes: coreos-installer-dracut < 0.0.1
* Wed Jan 08 2020 Dusty Mabe <dusty@dustymabe.com> - 0.1.2-1 * Wed Jan 08 2020 Dusty Mabe <dusty@dustymabe.com> - 0.1.2-1
- Bump to new upstream release 0.1.2 - Bump to new upstream release 0.1.2
- Release notes: https://github.com/coreos/coreos-installer/releases/tag/v0.1.2 - Release notes: https://github.com/coreos/coreos-installer/releases/tag/v0.1.2
- Update spec file to include systemd units from upstream
- These were added upstream in https://github.com/coreos/coreos-installer/pull/119
* Fri Dec 20 17:57:28 UTC 2019 Robert Fairley <rfairley@redhat.com> - 0.1.1-1 * Fri Dec 20 17:57:28 UTC 2019 Robert Fairley <rfairley@redhat.com> - 0.1.1-1
- Initial package - Initial package