From f49a7b4c9fb8fcd20ba703bf64e1f8b3f6431ccf3e033c0d44906ec55a78563f Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 17:30:39 +0000 Subject: [PATCH 1/6] - Behavioral change: Use cron only for older RHEL/CentOS versions (along with openSUSE < 12.3). Everything else now uses systemd. Please adopt accordingly! Refer to README.md for OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=43 --- README.SUSE => README.maintainer | 4 ++-- dehydrated.changes | 7 +++++++ dehydrated.spec | 12 ++++++------ 3 files changed, 15 insertions(+), 8 deletions(-) rename README.SUSE => README.maintainer (97%) diff --git a/README.SUSE b/README.maintainer similarity index 97% rename from README.SUSE rename to README.maintainer index b471228..5fafa1f 100644 --- a/README.SUSE +++ b/README.maintainer @@ -2,14 +2,14 @@ Acquiring TLS Certificates with Dehydrated ========================================== -The SUSE dehydrated package has been designed to make acquiring TLS +The dehydrated package has been designed to make acquiring TLS certificates (aka SSL Certificates) as simple as possible, while still being useful in a broad amount of use cases. Please consult the dehydrated man page, then continue reading here. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -IMPORTANT: On systemd-enabled system (SLE12+), you need to enable the update +IMPORTANT: On systemd-based systems, you need to enable the update timer, which has obsoleted the cron job. This is independent on which method you chose from below! diff --git a/dehydrated.changes b/dehydrated.changes index 6d5499f..11f1cd4 100644 --- a/dehydrated.changes +++ b/dehydrated.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sat Aug 10 17:18:25 UTC 2019 - Daniel Molkentin + +- Behavioral change: Use cron only for older RHEL/CentOS versions + (along with openSUSE < 12.3). Everything else now uses systemd. + Please adopt accordingly! Refer to README.md for + ------------------------------------------------------------------- Wed Jun 26 11:03:27 UTC 2019 - Daniel Molkentin diff --git a/dehydrated.spec b/dehydrated.spec index efcb83b..826b202 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -21,12 +21,12 @@ %define _home %{_sysconfdir}/dehydrated %define _postrunhooks %{_home}/postrun-hooks.d -%if 0%{?suse_version} > 1230 -%define _lock_dir /run/dehydrated -%bcond_without systemd -%else +%if 0%{?suse_version} <= 1230 || 0%{?rhel_version} <= 600 || 0%{?centos_version} <= 600 %define _lock_dir %{_localstatedir}/run/dehydrated %bcond_with systemd +%else +%define _lock_dir /run/dehydrated +%bcond_without systemd %endif %if 0%{?is_opensuse} || %{defined fedora} @@ -60,7 +60,7 @@ Source4: dehydrated.cron.in Source5: dehydrated.tmpfiles.d Source6: dehydrated.service.in Source7: dehydrated.timer -Source9: README.SUSE +Source9: README.maintainer Source10: README.Fedora Source11: README.hooks Source12: %{name}-%{version}.tar.gz.asc @@ -269,7 +269,7 @@ diff -urN docs/examples/config %{buildroot}%{_home}/config ||: %attr(-,%{_user},root) %dir %{_localstatedir}/lib/acme-challenge %{_mandir}/man1/* %doc LICENSE README.md docs/*.md docs/*.jpg -%doc README.SUSE +%doc README.maintainer %if %{defined redhat} %doc README.Fedora %endif From c29b838222b65d8a3a15f30275984e95f8bedbdd061ce217ad71ac891d12eb42 Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 17:43:44 +0000 Subject: [PATCH 2/6] Fix version conditions OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=44 --- dehydrated.changes | 2 +- dehydrated.spec | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dehydrated.changes b/dehydrated.changes index 11f1cd4..7d51293 100644 --- a/dehydrated.changes +++ b/dehydrated.changes @@ -2,7 +2,7 @@ Sat Aug 10 17:18:25 UTC 2019 - Daniel Molkentin - Behavioral change: Use cron only for older RHEL/CentOS versions - (along with openSUSE < 12.3). Everything else now uses systemd. + (along with SLE < 12.0). Everything else now uses systemd. Please adopt accordingly! Refer to README.md for ------------------------------------------------------------------- diff --git a/dehydrated.spec b/dehydrated.spec index 826b202..abb9585 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -21,7 +21,7 @@ %define _home %{_sysconfdir}/dehydrated %define _postrunhooks %{_home}/postrun-hooks.d -%if 0%{?suse_version} <= 1230 || 0%{?rhel_version} <= 600 || 0%{?centos_version} <= 600 +%if 0%{?sle_version} < 120000 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 %define _lock_dir %{_localstatedir}/run/dehydrated %bcond_with systemd %else From 695fa06d0771737519fc4ad6029a664611f6295dd65c78a00e1adad8af494e95 Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 17:50:58 +0000 Subject: [PATCH 3/6] TW requires suse_version OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=45 --- dehydrated.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dehydrated.spec b/dehydrated.spec index abb9585..8e37c5b 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -21,7 +21,7 @@ %define _home %{_sysconfdir}/dehydrated %define _postrunhooks %{_home}/postrun-hooks.d -%if 0%{?sle_version} < 120000 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 +%if 0%{?sle_version} < 120100 || %{?suse_version} < 1210 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 %define _lock_dir %{_localstatedir}/run/dehydrated %bcond_with systemd %else From 29ce8547a473447b94eb8ea0d300dacebf48d46c0e6a5e38879e1e0c956546b3 Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 17:53:28 +0000 Subject: [PATCH 4/6] Fix typo OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=46 --- dehydrated.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dehydrated.spec b/dehydrated.spec index 8e37c5b..87b2306 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -21,7 +21,7 @@ %define _home %{_sysconfdir}/dehydrated %define _postrunhooks %{_home}/postrun-hooks.d -%if 0%{?sle_version} < 120100 || %{?suse_version} < 1210 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 +%if 0%{?sle_version} < 120100 || 0%{?suse_version} < 1210 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 %define _lock_dir %{_localstatedir}/run/dehydrated %bcond_with systemd %else From 4a202471498bc5093287b4fff6287819977ebea4bacc23f4553ce2d55628cf2e Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 17:58:33 +0000 Subject: [PATCH 5/6] Negate again, < comparisions do not work OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=47 --- dehydrated.spec | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dehydrated.spec b/dehydrated.spec index 87b2306..7b0393b 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -21,12 +21,12 @@ %define _home %{_sysconfdir}/dehydrated %define _postrunhooks %{_home}/postrun-hooks.d -%if 0%{?sle_version} < 120100 || 0%{?suse_version} < 1210 || 0%{?rhel_version} < 700 || 0%{?centos_version} < 700 -%define _lock_dir %{_localstatedir}/run/dehydrated -%bcond_with systemd -%else +%if 0%{?sle_version} >= 120100 || 0%{?suse_version} >= 1210 || 0%{?rhel_version} >= 700 || 0%{?centos_version} >= 700 %define _lock_dir /run/dehydrated %bcond_without systemd +%else +%define _lock_dir %{_localstatedir}/run/dehydrated +%bcond_with systemd %endif %if 0%{?is_opensuse} || %{defined fedora} From ada9a540d777def9898db882564405753c189ab5d7bdfce784a095478e2b7b5e Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Sat, 10 Aug 2019 18:01:43 +0000 Subject: [PATCH 6/6] install rcdehydrated only for suse OBS-URL: https://build.opensuse.org/package/show/security:dehydrated/dehydrated?expand=0&rev=48 --- dehydrated.spec | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dehydrated.spec b/dehydrated.spec index 7b0393b..0ea6066 100644 --- a/dehydrated.spec +++ b/dehydrated.spec @@ -277,9 +277,11 @@ diff -urN docs/examples/config %{buildroot}%{_home}/config ||: %{_tmpfilesdir}/%{name}.conf %{_unitdir}/dehydrated.service %{_unitdir}/dehydrated.timer +%if 0%{?suse_version} %{_sbindir}/rcdehydrated +%endif %ghost %attr(700,%{_user},%{_user}) %dir %{_lock_dir} -%else +%else #with systemd %config %{_sysconfdir}/cron.d/dehydrated %attr(700,%{_user},%{_user}) %dir %{_lock_dir} %endif