From b92c8fd16293718a842bbbe7ba4f871093cb4101 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Tue, 5 Apr 2022 06:00:39 -0400 Subject: [PATCH] import console-login-helper-messages-0.21.2-3.el9 --- .console-login-helper-messages.metadata | 1 + .gitignore | 1 + SPECS/console-login-helper-messages.spec | 293 +++++++++++++++++++++++ 3 files changed, 295 insertions(+) create mode 100644 .console-login-helper-messages.metadata create mode 100644 .gitignore create mode 100644 SPECS/console-login-helper-messages.spec diff --git a/.console-login-helper-messages.metadata b/.console-login-helper-messages.metadata new file mode 100644 index 0000000..35cf781 --- /dev/null +++ b/.console-login-helper-messages.metadata @@ -0,0 +1 @@ +ef58468f3d0a6bfea94b9c166c50ccdc81630d65 SOURCES/v0.21.2.tar.gz diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9474142 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/v0.21.2.tar.gz diff --git a/SPECS/console-login-helper-messages.spec b/SPECS/console-login-helper-messages.spec new file mode 100644 index 0000000..997e1af --- /dev/null +++ b/SPECS/console-login-helper-messages.spec @@ -0,0 +1,293 @@ +%global github_owner coreos +%global github_project console-login-helper-messages + +Name: console-login-helper-messages +Version: 0.21.2 +Release: 3%{?dist} +Summary: Combines motd, issue, profile features to show system information to the user before/on login +License: BSD +URL: https://github.com/%{github_owner}/%{github_project} +Source0: https://github.com/%{github_owner}/%{github_project}/archive/v%{version}.tar.gz + +BuildArch: noarch +BuildRequires: systemd make +%{?systemd_requires} +Requires: bash systemd + +%description +%{summary}. + +%package motdgen +Summary: Message of the day generator script showing system information +Requires: console-login-helper-messages +# sshd reads /run/motd.d, where the generated MOTD message is written. +Recommends: openssh +# bash: bash scripts are included in this package +# systemd: systemd service units, and querying for failed units +# (the above applies to the issuegen and profile subpackages too) +Requires: bash systemd +# setup: filesystem paths need setting up. +# * https://pagure.io/setup/pull-request/14 +# * https://pagure.io/setup/pull-request/15 +# * https://pagure.io/setup/pull-request/16 +# Make exception for fc29 - soft requires as we will create /run/motd.d +# ourselves if it doesn't already exist. +%if 0%{?fc29} +Requires: setup +%else +Requires: setup >= 2.12.7-1 +%endif +# pam: to display motds in /run/motd.d. +# * https://github.com/linux-pam/linux-pam/issues/47 +# * https://github.com/linux-pam/linux-pam/pull/69 +# * https://github.com/linux-pam/linux-pam/pull/76 +Requires: ((pam >= 1.3.1-15) if openssh) +# selinux-policy: to apply pam_var_run_t contexts: +# * https://github.com/fedora-selinux/selinux-policy/pull/244 +# Make exception for fc29, as PAM will create the tmpfiles. (In Fedora 30 and +# above, setup is responsible for this). +%if 0%{?fc29} +Requires: ((selinux-policy >= 3.14.2-50) if openssh) +%else +Requires: ((selinux-policy >= 3.14.3-23) if openssh) +%endif +# Needed to display MOTDs in `/run/motd.d` before upon login through +# the serial console. +Requires: util-linux >= 2.36-1 + +%description motdgen +%{summary}. + +%package issuegen +Summary: Issue generator scripts showing SSH keys and IP address +Requires: console-login-helper-messages +Requires: bash systemd setup +# NetworkManager: for displaying IP info using NetworkManager dispatcher script +Requires: (NetworkManager) +Requires: /etc/issue.d +# Needed to display issues in /etc/issue.d before login through the serial console. +Requires: util-linux >= 2.36-1 + +%description issuegen +%{summary}. + +%package profile +Summary: Profile script showing systemd failed units +Requires: console-login-helper-messages +Requires: bash systemd setup + +%description profile +%{summary}. + +%prep +%setup -q + +%build + +%install +make install DESTDIR=%{buildroot} + +%post issuegen +%systemd_post %{name}-gensnippet-ssh-keys.service + +%preun issuegen +%systemd_preun %{name}-gensnippet-ssh-keys.service + +%postun issuegen +%systemd_postun_with_restart %{name}-gensnippet-ssh-keys.service + +%post motdgen +%systemd_post %{name}-gensnippet-os-release.service + +%preun motdgen +%systemd_preun %{name}-gensnippet-os-release.service + +%postun motdgen +%systemd_postun_with_restart %{name}-gensnippet-os-release.service + +# TODO: %check + +%files +%doc README.md +%doc doc/manual.md +%license LICENSE +%dir %{_libexecdir}/%{name} +%dir %{_prefix}/lib/%{name} +%dir %{_prefix}/share/%{name} +%{_prefix}/lib/%{name}/libutil.sh +%{_tmpfilesdir}/%{name}.conf + +%files issuegen +%{_unitdir}/%{name}-gensnippet-ssh-keys.service +%{_sysconfdir}/NetworkManager/dispatcher.d/90-%{name}-gensnippet_if +%{_prefix}/lib/%{name}/issue.defs +%{_tmpfilesdir}/%{name}-issuegen.conf +%{_libexecdir}/%{name}/gensnippet_ssh_keys +%{_libexecdir}/%{name}/gensnippet_if +%{_libexecdir}/%{name}/gensnippet_if_udev + +%files motdgen +%{_unitdir}/%{name}-gensnippet-os-release.service +%{_prefix}/lib/%{name}/motd.defs +%{_tmpfilesdir}/%{name}-motdgen.conf +%{_libexecdir}/%{name}/gensnippet_os_release + +%files profile +%{_prefix}/share/%{name}/profile.sh +%{_tmpfilesdir}/%{name}-profile.conf +%ghost %{_sysconfdir}/profile.d/%{name}-profile.sh + +%changelog +* Thu Jul 29 2021 Kelvin Fan - 0.21.2-3 +- Remove requirement for `fedora-release` and require `/etc/issue.d` + +* Wed Jul 21 2021 Fedora Release Engineering - 0.21.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Tue Mar 30 2021 Kelvin Fan - 0.21.2-1 +- Update to 0.21.2 + +* Tue Mar 02 2021 Zbigniew Jędrzejewski-Szmek - 0.21.1-3 +- Rebuilt for updated systemd-rpm-macros + See https://pagure.io/fesco/issue/2583. + +* Thu Feb 18 2021 Kelvin Fan - 0.21.1-2 +- Make scripts subpackage-specific, addresses #1929844 + +* Fri Feb 5 2021 Kelvin Fan - 0.21.1-1 +- Update to 0.21.1 + +* Thu Feb 4 2021 Kelvin Fan - 0.21-1 +- Update to 0.21 +- Require util-linux >= 2.36-1 +- Remove files related to the issuegen and motdgen executables + +* Tue Jan 26 2021 Fedora Release Engineering - 0.20.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Mon Nov 23 2020 Kelvin Fan - 0.20.3-1 +- Update to 0.20.3 + +* Fri Oct 30 2020 Kelvin Fan - 0.20.2-1 +- Update to 0.20.2 + +* Fri Oct 2 2020 Kelvin Fan - 0.20.1-1 +- Update to 0.20.1 + +* Fri Sep 25 2020 Kelvin Fan - 0.2-1 +- Update to 0.2 +- Add presets for `.service` units +- %ghost symlinks defined in tmpfiles.d directory + +* Fri Sep 18 2020 Kelvin Fan - 0.19-2 +- BuildRequire `make` +- Remove preinstall scripts + +* Tue Sep 08 2020 Kelvin Fan - 0.19-1 +- Update to 0.19 +- Invoke make install +- Remove -motdgen.service, -issuegen.service presets +- Require NetworkManager or systemd-udev + +* Mon Jul 27 2020 Fedora Release Engineering - 0.18.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Mon Jul 06 2020 Robert Fairley - 0.18.2-1 +- Update to 0.18.2 + +* Thu Apr 30 2020 Robert Fairley - 0.18.1-1 +- Update to 0.18.1 + +* Tue Apr 28 2020 Robert Fairley - 0.18-1 +- Update to 0.18 +- Change github_owner to coreos + +* Tue Jan 28 2020 Fedora Release Engineering - 0.17-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Fri Aug 16 2019 Robert Fairley - 0.17-1 +- Update to 0.17 +- Add manual.md to package docs +- Use tmpfiles_create_pkg macro + +* Wed Jul 24 2019 Fedora Release Engineering - 0.16-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Fri Jun 21 2019 Robert Fairley - 0.16-3 +- Specfile tidyups (comments, formatting), and remove fc28 conditionals + +* Fri Mar 22 2019 Robert Fairley - 0.16-2 +- Add condition for f28 setup Requires + +* Thu Mar 21 2019 Robert Fairley - 0.16-1 +- relax setup dependency for f29 +- general upstream source/tidiness improvements +- house executable scripts in /usr/libexec +- change Source0 to use GitHub-generated archive link +- drop .path units for motdgen and issuegen + +* Fri Mar 15 2019 Robert Fairley - 0.15-1 +- make motdgen generate motd in /run with no symlink + +* Fri Mar 15 2019 Robert Fairley - 0.14-1 +- issuegen.service: rely on sshd-keygen.target +- issuegen: don't show kernel version + +* Thu Jan 24 2019 Robert Fairley - 0.13-4 +- update reviewers.md and manual.md with correct paths + +* Wed Jan 23 2019 Robert Fairley - 0.13-3 +- change generated issue to be scoped in private directory + +* Wed Jan 23 2019 Robert Fairley - 0.13-2 +- change generated motd to be scoped in private directory + +* Wed Jan 23 2019 Robert Fairley - 0.13-1 +- add a symlink for motdgen (quick solution until upstream pam_motd.so changes propagate) + +* Fri Jan 18 2019 Robert Fairley - 0.12-2 +- fix Requires for selinux-policy, add missing Requires for systemd-udev and fedora-release + +* Wed Jan 16 2019 Robert Fairley - 0.12-1 +- fix specfile Source0 to correct github URL + +* Wed Jan 16 2019 Robert Fairley - 0.11-1 +- add reviewers.md, specfile fixes + +* Wed Jan 16 2019 Robert Fairley - 0.1-12 +- add move README.md sections out into a manual, update specfile + +* Wed Jan 09 2019 Robert Fairley - 0.1-11 +- specfile cleanup, go through git commit history to write changelog + +* Wed Jan 09 2019 Robert Fairley - 0.1-10 +- Add license, tidyups + +* Mon Dec 10 2018 Robert Fairley - 0.1-9 +- Add tmpfiles_create_package usage to reproduce coredump + +* Mon Dec 10 2018 Robert Fairley - 0.1-8 +- Remove tmpfiles_create_package usage + +* Mon Dec 10 2018 Robert Fairley - 0.1-7 +- Fix usage of tmpfiles_create_package macro in specfile + +* Fri Dec 07 2018 Robert Fairley - 0.1-6 +- Fix tmpfile symlink paths + +* Fri Dec 07 2018 Robert Fairley - 0.1-5 +- Add [systemd] label to failed units message in profile script + +* Tue Dec 04 2018 Robert Fairley - 0.1-4 +- Minor formatting edits to generated issue and motd + +* Tue Dec 04 2018 Robert Fairley - 0.1-3 +- Remove printing package manager info (rpm-ostree, dnf) + +* Tue Dec 04 2018 Robert Fairley - 0.1-2 +- Add CI with copr +- Drop requirement on specifc SELinux version +- Various tidyups including filenames + +* Tue Sep 25 2018 Robert Fairley - 0.1-1 +- Initial Package