diff --git a/.gitignore b/.gitignore index 1221449..488ed59 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /v0.4.tar.gz +/v0.5.tar.gz diff --git a/greenboot.spec b/greenboot.spec index 52dd66a..506bc6a 100644 --- a/greenboot.spec +++ b/greenboot.spec @@ -3,8 +3,8 @@ %global build_timestamp %(date +"%Y%m%d%H%M%%S") Name: greenboot -Version: 0.4 -Release: 2%{?dist} +Version: 0.5 +Release: 1%{?dist} Summary: Generic Health Check Framework for systemd License: LGPLv2+ URL: https://github.com/%{github_owner}/%{github_project} @@ -57,23 +57,21 @@ Requires: %{name} = %{version}-%{release} %install install -Dpm 0755 usr/libexec/greenboot/greenboot.sh %{buildroot}%{_libexecdir}/%{name}/%{name}.sh +install -Dpm 0755 usr/libexec/greenboot/greenboot_motdgen.sh %{buildroot}%{_libexecdir}/%{name}/%{name}_motdgen.sh install -Dpm 0644 usr/lib/systemd/system/greenboot.target %{buildroot}%{_unitdir}/greenboot.target install -Dpm 0644 usr/lib/systemd/system/greenboot-healthcheck.service %{buildroot}%{_unitdir}/greenboot-healthcheck.service install -Dpm 0644 usr/lib/systemd/system/greenboot.service %{buildroot}%{_unitdir}/greenboot.service install -Dpm 0644 usr/lib/systemd/system/redboot.service %{buildroot}%{_unitdir}/redboot.service -mkdir -p %{buildroot}/run/%{name} -mkdir -p %{buildroot}%{_sysconfdir}/motd.d +install -Dpm 0644 usr/lib/systemd/system/greenboot-motdgen.service %{buildroot}%{_unitdir}/greenboot-motdgen.service mkdir -p %{buildroot}%{_sysconfdir}/%{name}/check/required.d mkdir %{buildroot}%{_sysconfdir}/%{name}/check/wanted.d mkdir %{buildroot}%{_sysconfdir}/%{name}/green.d mkdir %{buildroot}%{_sysconfdir}/%{name}/red.d -mkdir %{buildroot}%{_sysconfdir}/%{name}/motd install -Dpm 0755 etc/greenboot/check/required.d/* %{buildroot}%{_sysconfdir}/%{name}/check/required.d install -Dpm 0755 etc/greenboot/check/wanted.d/* %{buildroot}%{_sysconfdir}/%{name}/check/wanted.d install -Dpm 0755 etc/greenboot/green.d/* %{buildroot}%{_sysconfdir}/%{name}/green.d install -Dpm 0755 etc/greenboot/red.d/* %{buildroot}%{_sysconfdir}/%{name}/red.d -install -Dpm 0644 etc/greenboot/motd/* %{buildroot}%{_sysconfdir}/%{name}/motd -ln -snf /run/greenboot/motd %{buildroot}%{_sysconfdir}/motd.d/%{name} +install -Dpm 0644 etc/greenboot/motd %{buildroot}%{_sysconfdir}/%{name}/motd %post %systemd_post greenboot.target @@ -81,18 +79,27 @@ ln -snf /run/greenboot/motd %{buildroot}%{_sysconfdir}/motd.d/%{name} %systemd_post greenboot-healthcheck.service %systemd_post redboot.service +%post motd +%systemd_post greenboot-motdgen.service + %preun %systemd_preun greenboot.target %systemd_preun greenboot.service %systemd_preun greenboot-healthcheck.service %systemd_preun redboot.service +%preun motd +%systemd_preun greenboot-motdgen.service + %postun %systemd_postun_with_restart greenboot.target %systemd_postun_with_restart greenboot.service %systemd_postun_with_restart greenboot-healthcheck.service %systemd_postun_with_restart redboot.service +%postun motd +%systemd_postun greenboot-motdgen.service + %check # TODO @@ -112,16 +119,12 @@ ln -snf /run/greenboot/motd %{buildroot}%{_sysconfdir}/motd.d/%{name} %dir %{_sysconfdir}/%{name}/check/wanted.d %{_sysconfdir}/%{name}/check/wanted.d/00_wanted_scripts_start.sh %dir %{_sysconfdir}/%{name}/green.d -%{_sysconfdir}/%{name}/green.d/00_greenboot_notification.sh %dir %{_sysconfdir}/%{name}/red.d -%{_sysconfdir}/%{name}/red.d/00_redboot_notification.sh %files motd -%dir /run/%{name} -%config(noreplace) %{_sysconfdir}/motd.d/%{name} -%config %{_sysconfdir}/%{name}/motd/ -%{_sysconfdir}/%{name}/green.d/50_greenboot_motd.sh -%{_sysconfdir}/%{name}/red.d/50_redboot_motd.sh +%config %{_sysconfdir}/%{name}/motd +%{_libexecdir}/%{name}/%{name}_motdgen.sh +%{_unitdir}/greenboot-motdgen.service %files ostree-grub2 %{_sysconfdir}/%{name}/green.d/01_ostree_grub2_fallback.sh @@ -133,6 +136,9 @@ ln -snf /run/greenboot/motd %{buildroot}%{_sysconfdir}/motd.d/%{name} %{_sysconfdir}/%{name}/red.d/99_reboot.sh %changelog +* Fri Oct 19 2018 Christian Glombek - 0.5-1 +- Update to v0.5 + * Tue Oct 02 2018 Christian Glombek - 0.4-2 - Spec Review diff --git a/sources b/sources index 241e41e..9c78692 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (v0.4.tar.gz) = 66841040467527deec390178cd298f2358fc19e844c2d2d09e29f377b39d17b769611993b4d2a519a77adf5030b533c3edd132c0c7fe9b5b0090b554226d56d6 +SHA512 (v0.5.tar.gz) = 9f3a0690c9fcee982f5395455a29362ae8c09b1fc739f8d9d7bcfa0b3929a52a35fe22dd93f5696cf044782d0c52e3fb2a5e205533661d54e8bb61b76854d72b