22%bcond_without check
33%global __cargo_skip_build 0
44%global __cargo_is_lib() false
5- %global forgeurl https://github.com/fedora-iot/greenboot
5+ %global forgeurl https://github.com/fedora-iot/greenboot-rs
6+ %global pkgname greenboot
67
78Version: 0.16.0
89
910%forgemeta
1011
11- Name: greenboot
12+ Name: greenboot-rs
1213Release: 0%{?dist }
1314Summary: Generic Health Check Framework for systemd
1415License: LGPLv2+
@@ -50,15 +51,30 @@ Requires: pam >= 1.4.0
5051Recommends: openssh
5152
5253%description
54+ This is the source package for the Rust implementation of greenboot.
55+
56+ %package -n %{pkgname }
57+ Summary: %{summary }
58+ # this replaces the bash version of greenboot
59+ Provides: %{pkgname } = %{version }-%{release }
60+ Obsoletes: %{pkgname } < %{version }-%{release }
61+ Conflicts: %{pkgname } < %{version }-%{release }
62+ Requires: systemd >= 240
63+ Requires: rpm-ostree
64+ Requires: pam >= 1.4.0
65+ Recommends: openssh
66+
67+ %description -n %{pkgname }
68+
5369%{summary }.
5470
55- %package default-health-checks
71+ %package -n %{ pkgname }- default-health-checks
5672Summary: Series of optional and curated health checks
57- Requires: %{name } = %{version }-%{release }
73+ Requires: %{pkgname } = %{version }-%{release }
5874Requires: util-linux
5975Requires: jq
6076
61- %description default-health-checks
77+ %description -n %{ pkgname }- default-health-checks
6278%{summary }.
6379
6480%prep
@@ -71,26 +87,26 @@ Requires: jq
7187%install
7288%cargo_install
7389mkdir -p %{buildroot }%{_libexecdir }
74- mkdir -p %{buildroot }%{_libexecdir }/%{name }
75- mv %{buildroot }%{_bindir }/greenboot %{buildroot }%{_libexecdir }/%{name }/%{name }
90+ mkdir -p %{buildroot }%{_libexecdir }/%{pkgname }
91+ mv %{buildroot }%{_bindir }/greenboot %{buildroot }%{_libexecdir }/%{pkgname }/%{pkgname }
7692install -Dpm0644 -t %{buildroot }%{_unitdir } usr/lib/systemd/system/* .service
7793install -Dpm0644 -t %{buildroot }%{_unitdir } usr/lib/systemd/system/* .target
7894mkdir -p %{buildroot }%{_exec_prefix }/lib/motd.d/
79- mkdir -p %{buildroot }%{_libexecdir }/%{name }
80- install -Dpm0644 -t %{buildroot }%{_sysconfdir }/%{name } etc/greenboot/greenboot.conf
95+ mkdir -p %{buildroot }%{_libexecdir }/%{pkgname }
96+ install -Dpm0644 -t %{buildroot }%{_sysconfdir }/%{pkgname } etc/greenboot/greenboot.conf
8197install -D -t %{buildroot }%{_prefix }/lib/bootupd/grub2-static/configs.d grub2/08_greenboot.cfg
82- mkdir -p %{buildroot }%{_sysconfdir }/%{name }/check/required.d
83- mkdir %{buildroot }%{_sysconfdir }/%{name }/check/wanted.d
84- mkdir %{buildroot }%{_sysconfdir }/%{name }/green.d
85- mkdir %{buildroot }%{_sysconfdir }/%{name }/red.d
86- mkdir -p %{buildroot }%{_prefix }/lib/%{name }/check/required.d
87- mkdir %{buildroot }%{_prefix }/lib/%{name }/check/wanted.d
88- mkdir %{buildroot }%{_prefix }/lib/%{name }/green.d
89- mkdir %{buildroot }%{_prefix }/lib/%{name }/red.d
98+ mkdir -p %{buildroot }%{_sysconfdir }/%{pkgname }/check/required.d
99+ mkdir %{buildroot }%{_sysconfdir }/%{pkgname }/check/wanted.d
100+ mkdir %{buildroot }%{_sysconfdir }/%{pkgname }/green.d
101+ mkdir %{buildroot }%{_sysconfdir }/%{pkgname }/red.d
102+ mkdir -p %{buildroot }%{_prefix }/lib/%{pkgname }/check/required.d
103+ mkdir %{buildroot }%{_prefix }/lib/%{pkgname }/check/wanted.d
104+ mkdir %{buildroot }%{_prefix }/lib/%{pkgname }/green.d
105+ mkdir %{buildroot }%{_prefix }/lib/%{pkgname }/red.d
90106mkdir -p %{buildroot }%{_unitdir }
91107mkdir -p %{buildroot }%{_tmpfilesdir }
92- install -DpZm 0755 usr/lib/greenboot/check/required.d/* %{buildroot }%{_prefix }/lib/%{name }/check/required.d
93- install -DpZm 0755 usr/lib/greenboot/check/wanted.d/* %{buildroot }%{_prefix }/lib/%{name }/check/wanted.d
108+ install -DpZm 0755 usr/lib/greenboot/check/required.d/* %{buildroot }%{_prefix }/lib/%{pkgname }/check/required.d
109+ install -DpZm 0755 usr/lib/greenboot/check/wanted.d/* %{buildroot }%{_prefix }/lib/%{pkgname }/check/wanted.d
94110install -DpZm 0644 usr/lib/systemd/system/greenboot-healthcheck.service.d/10-network-online.conf %{buildroot }%{_unitdir }/greenboot-healthcheck.service.d/10-network-online.conf
95111
96112%post
@@ -108,36 +124,40 @@ install -DpZm 0644 usr/lib/systemd/system/greenboot-healthcheck.service.d/10-net
108124%systemd_postun greenboot-set-rollback-trigger.service
109125%systemd_postun greenboot-success.target
110126
111- %files
127+ %files -n %{ pkgname }
112128%doc README.md
113129%license LICENSE
114- %dir %{_libexecdir }/%{name }
115- %{_libexecdir }/%{name }/%{name }
130+ %dir %{_libexecdir }/%{pkgname }
131+ %{_libexecdir }/%{pkgname }/%{pkgname }
116132%{_unitdir }/greenboot-healthcheck.service
117133%{_unitdir }/greenboot-set-rollback-trigger.service
118134%{_unitdir }/greenboot-success.target
119- %{_sysconfdir }/%{name }/greenboot.conf
135+ %{_sysconfdir }/%{pkgname }/greenboot.conf
120136%{_prefix }/lib/bootupd/grub2-static/configs.d/08_greenboot.cfg
121- %dir %{_prefix }/lib/%{name }
122- %dir %{_prefix }/lib/%{name }/check
123- %dir %{_prefix }/lib/%{name }/check/required.d
124- %dir %{_prefix }/lib/%{name }/check/wanted.d
125- %dir %{_prefix }/lib/%{name }/green.d
126- %dir %{_prefix }/lib/%{name }/red.d
127- %dir %{_sysconfdir }/%{name }
128- %dir %{_sysconfdir }/%{name }/check
129- %dir %{_sysconfdir }/%{name }/check/required.d
130- %dir %{_sysconfdir }/%{name }/check/wanted.d
131- %dir %{_sysconfdir }/%{name }/green.d
132- %dir %{_sysconfdir }/%{name }/red.d
133-
134- %files default-health-checks
135- %{_prefix }/lib/%{name }/check/wanted.d/01_update_platforms_check.sh
136- %{_prefix }/lib/%{name }/check/required.d/02_watchdog.sh
137- %{_prefix }/lib/%{name }/check/required.d/01_repository_dns_check.sh
137+ %dir %{_prefix }/lib/%{pkgname }
138+ %dir %{_prefix }/lib/%{pkgname }/check
139+ %dir %{_prefix }/lib/%{pkgname }/check/required.d
140+ %dir %{_prefix }/lib/%{pkgname }/check/wanted.d
141+ %dir %{_prefix }/lib/%{pkgname }/green.d
142+ %dir %{_prefix }/lib/%{pkgname }/red.d
143+ %dir %{_sysconfdir }/%{pkgname }
144+ %dir %{_sysconfdir }/%{pkgname }/check
145+ %dir %{_sysconfdir }/%{pkgname }/check/required.d
146+ %dir %{_sysconfdir }/%{pkgname }/check/wanted.d
147+ %dir %{_sysconfdir }/%{pkgname }/green.d
148+ %dir %{_sysconfdir }/%{pkgname }/red.d
149+
150+ %files -n %{ pkgname }- default-health-checks
151+ %{_prefix }/lib/%{pkgname }/check/wanted.d/01_update_platforms_check.sh
152+ %{_prefix }/lib/%{pkgname }/check/required.d/02_watchdog.sh
153+ %{_prefix }/lib/%{pkgname }/check/required.d/01_repository_dns_check.sh
138154%{_unitdir }/greenboot-healthcheck.service.d/10-network-online.conf
139155
140156%changelog
141- * Thu Jul 24 2025 Sayan Paul <paul.sayan@gmail.com> - 0.16-1
157+ * Fri Jul 25 2025 Paul Whalen <pwhalen@fedoraproject.org> - 0.16.0-2
158+ - Update src to greenboot-rs, binaries remain greenboot
159+ - Obsoletes/Conflicts for bash greenboot, Provides greenboot
160+
161+ * Thu Jul 24 2025 Sayan Paul <paul.sayan@gmail.com> - 0.16.0-1
142162- Initial Package
143- - Switched to native Fedora dependencies, removing vendoring.
163+ - Switched to native Fedora dependencies, removing vendoring.
0 commit comments