A new user interface for you! Read more...

File project.diff of Package barman

--- barman.changes.orig
+++ barman.changes
@@ -1,4 +1,33 @@
 -------------------------------------------------------------------
+Tue May 28 08:54:25 UTC 2019 - Boris Manojlovic <boris@steki.net>
+
+-  updated to version 2.8
+  - New features
+    - Add support for reuse_backup in geo-redundancy for incremental
+      backup copy in passive nodes
+    - Improve performance of rsync based copy by using strptime
+      instead of the more generic dateutil.parser (#210)
+    - Add ‘–test’ option to barman-wal-archive and barman-wal-restore
+      to verify the connection with the Barman server
+    - Complain if backup_options is not explicitly set, as the future default
+      value will change from exclusive_backup to concurrent_backup
+      when PostgreSQL 9.5 will be declared EOL by the PGDG
+    - Display additional settings in the show-server and diagnose commands:
+      archive_timeout, data_checksums, hot_standby, max_wal_senders,
+      max_replication_slots and wal_compression.
+    - Merge the barman-cli project in Barman
+  - Bug fixes: 
+    - Fix encoding error in get-wal on Python 3 (Jeff Janes, #221)
+    - Fix exclude_and_protect_filter (Jeff Janes, #217)
+    - Remove spurious message when resetting WAL (Jeff Janes, #215)
+    - Fix sync-wals error if primary has WALs older than the first backup
+    - Support for double quotes in synchronous_standby_names setting
+  - Minor changes:
+    - Improve messaging of check --nagios for inactive servers
+    - Log remote SSH command with recover command
+    - Hide logical decoding connections in replication-status command
+
+-------------------------------------------------------------------
 Fri Mar 29 15:24:42 UTC 2019 - Marcus Rueckert <mrueckert@suse.de>
 
 - update to 2.7
--- barman.spec.orig
+++ barman.spec
@@ -1,7 +1,7 @@
 #
 # spec file for package barman
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,27 +12,23 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
+%{?!python_module:%define python_module() python-%{**} python3-%{**}}
+
 %define         nsusr   barman
 %define         nsgrp   barman
 
-%if 0%{?suse_version} > 1230
-%bcond_without systemd
-%else
-%bcond_with    systemd
-%endif
-
 Name:           barman
-Version:        2.7
+Version:        2.8
 Release:        0
 Summary:        Backup and Recovery Manager for PostgreSQL
 License:        GPL-3.0-or-later
 Group:          Productivity/Databases/Tools
 URL:            http://www.pgbarman.org/
-Source0:        http://downloads.sourceforge.net/project/pgbarman/%{version}/%{name}-%{version}.tar.gz
+Source0:        http://downloads.sourceforge.net/project/pgbarman/%{version}/barman-%{version}.tar.gz
 Source1:        http://downloads.sourceforge.net/project/pgbarman/%{version}/manual.pdf
 
 Source2:        barman.logrotate
@@ -40,24 +36,28 @@ Source3:        barman.cron
 Source4:        barman.service
 Source5:        barman.timer
 
+BuildRequires:  %{python_module devel}
+BuildRequires:  %{python_module setuptools}
 BuildRequires:  fdupes
-BuildRequires:  python3-devel
+BuildRequires:  python-rpm-macros
 Requires(pre):  %{_sbindir}/groupadd
 Requires(pre):  %{_sbindir}/useradd
-%if %{with systemd}
 BuildRequires:  pkgconfig(systemd)
 %{?systemd_requires}
-%else #with_systemd
-Requires:       cron
-%endif #with_systemd
+
 Requires:       logrotate
-Requires:       python3-argcomplete
-Requires:       python3-argh >= 0.21.2
-Requires:       python3-dateutil
-Requires:       python3-psycopg2
+Requires:       python-argcomplete
+Requires:       python-argh >= 0.21.2
+Requires:       python-dateutil
+Requires:       python-psycopg2
 Requires:       rsync >= 3.0.4
+Requires:       barman-common
+Requires(post):   update-alternatives
+Requires(postun):  update-alternatives
 BuildArch:      noarch
 
+%python_subpackages
+
 %description
 Barman (backup and recovery manager) is an administration
 tool for disaster recovery of PostgreSQL servers written in Python.
@@ -67,77 +67,100 @@ Barman offers most wanted features inclu
 remote recovery, archiving and compression of WAL files and backups.
 Barman is written and maintained by PostgreSQL professionals 2ndQuadrant.
 
+%package -n barman-common
+Group: Productivity/Databases/Tools
+Summary: Backup and Recovery Manager for PostgreSQL - common files
+Requires: barman
+
+%description -n barman-common
+Barman (backup and recovery manager) is an administration
+tool for disaster recovery of PostgreSQL servers written in Python.
+It allows to perform remote backups of multiple servers
+in business critical environments and help DBAs during the recovery phase.
+Barman offers most wanted features include backup catalogs, retention policies,
+remote recovery, archiving and compression of WAL files and backups.
+Barman is written and maintained by PostgreSQL professionals 2ndQuadrant.
+
 %prep
 %setup -q
 cp %{SOURCE1} .
 
 %build
-python3 setup.py build
+%python_build
 
 %install
-python3 setup.py install -O1 --skip-build --root %{buildroot} --prefix=%{_prefix}
+%python_install
 
 mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d
-mkdir -p %{buildroot}%{_sysconfdir}/cron.d/
-# Without dir barman from cron will spew every minute annoying message
-# 2017-08-05 15:16:01,975 [27539] barman.config WARNING: Ignoring the "configuration_files_directory" option as "/etc/barman.d" is not a directory
 mkdir -p %{buildroot}%{_sysconfdir}/barman.d/
 mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d/
-mkdir -p %{buildroot}%{_localstatedir}/lib/%{name}
-mkdir -p %{buildroot}%{_localstatedir}/log/%{name}
-install -pm 644 doc/barman.conf %{buildroot}%{_sysconfdir}/%{name}.conf
-install -pm 644 scripts/barman.bash_completion %{buildroot}%{_sysconfdir}/bash_completion.d/%{name}
-%if %{with systemd}
-install -D -m 644 %{SOURCE4} %{buildroot}%{_unitdir}/%{name}.service
-install -D -m 644 %{SOURCE5} %{buildroot}%{_unitdir}/%{name}.timer
-%else
-install -pm 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/cron.d/%{name}
-%endif
-install -pm 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
-touch %{buildroot}%{_localstatedir}/log/%{name}/%{name}.log
-
-%fdupes %{buildroot}%{python3_sitelib}
-
-%pre
-groupadd -f -r %{name} >/dev/null 2>&1 || :
-useradd -g %{name} -r -d %{_localstatedir}/lib/%{name} -s /bin/bash \
-    -c "Backup and Recovery Manager for PostgreSQL" %{name} >/dev/null 2>&1 || :
-%if %{with systemd}
-%service_add_pre %{name}.service %{name}.timer
-
-%post
-%service_add_post %{name}.service %{name}.timer
-
-%preun
-%service_del_preun %{name}.service %{name}.timer
-
-%postun
-%service_del_postun %{name}.service %{name}.timer
-%endif
+mkdir -p %{buildroot}%{_localstatedir}/lib/barman
+mkdir -p %{buildroot}%{_localstatedir}/log/barman
+install -pm 644 doc/barman.conf %{buildroot}%{_sysconfdir}/barman.conf
+install -pm 644 scripts/barman.bash_completion %{buildroot}%{_sysconfdir}/bash_completion.d/barman
+install -D -m 644 %{SOURCE4} %{buildroot}%{_unitdir}/barman.service
+install -D -m 644 %{SOURCE5} %{buildroot}%{_unitdir}/barman.timer
+install -pm 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/barman
+touch %{buildroot}%{_localstatedir}/log/barman/barman.log
+
+%python_clone -a %{buildroot}%{_bindir}/barman
+%python_clone -a %{buildroot}%{_bindir}/barman-wal-archive
+%python_clone -a %{buildroot}%{_bindir}/barman-wal-restore
+%python_clone -a %{buildroot}%{_mandir}/man1/barman.1
+%python_clone -a %{buildroot}%{_mandir}/man1/barman-wal-archive.1
+%python_clone -a %{buildroot}%{_mandir}/man1/barman-wal-restore.1
+%python_clone -a %{buildroot}%{_mandir}/man5/barman.5
+%python_clone -a %{buildroot}%{_sysconfdir}/logrotate.d/barman
+
+%python_expand %fdupes %{buildroot}%{$python_sitelib}
+
+%pre -n barman-common
+groupadd -f -r barman >/dev/null 2>&1 || :
+useradd -g barman -r -d %{_localstatedir}/lib/barman -s /bin/bash \
+    -c "Backup and Recovery Manager for PostgreSQL" barman >/dev/null 2>&1 || :
+%service_add_pre barman.service barman.timer
+
+%post -n barman-common
+%{python_install_alternative barman barman.1 barman.5 barman-wal-archive barman-wal-restore barman-wal-archive.1 barman-wal-restore.1}
+%service_add_post barman.service barman.timer
+
+%preun -n barman-common
+%service_del_preun barman.service barman.timer
+
+%postun -n barman-common
+%python_uninstall_alternative barman
+%service_del_postun barman.service barman.timer
 
-%files
+%files -n barman-common
 %defattr(-,root,root,-)
-%license LICENSE
+%if 0%{?suse_version} > 1315
+ %license LICENSE
+%endif
 %doc README.rst ChangeLog NEWS manual.pdf
-%{_bindir}/%{name}
-%{python3_sitelib}/%{name}-%{version}-*.egg-info
-%{python3_sitelib}/%{name}/
-%{_mandir}/man1/%{name}.1%{?ext_man}
-%{_mandir}/man5/%{name}.5%{?ext_man}
-#
-%config(noreplace) %attr(640,root,%{nsgrp}) %{_sysconfdir}/barman.conf
+%if 0%{?suse_version} <= 1315
+ %doc LICENSE
+%endif
+%config(noreplace)  %attr(640,root,%{nsgrp}) %{_sysconfdir}/barman.conf
 %config(noreplace) %attr(750,root,%{nsgrp}) %{_sysconfdir}/barman.d/
 %config(noreplace) %{_sysconfdir}/bash_completion.d/barman
-%config(noreplace) %{_sysconfdir}/logrotate.d/barman
-%if %{with systemd}
-%{_unitdir}/%{name}.service
-%{_unitdir}/%{name}.timer
-%else
-%config(noreplace) %{_sysconfdir}/cron.d/%{name}
-%endif
-#
-%attr(700,%{nsusr},%{nsgrp}) %dir %{_localstatedir}/lib/%{name}
-%attr(700,%{nsusr},%{nsgrp}) %dir %{_localstatedir}/log/%{name}
-%attr(600,%{nsusr},%{nsgrp}) %ghost %{_localstatedir}/log/%{name}/%{name}.log
+%{_unitdir}/barman.service
+%{_unitdir}/barman.timer
+%attr(700,%{nsusr},%{nsgrp}) %dir %{_localstatedir}/lib/barman
+%attr(700,%{nsusr},%{nsgrp}) %dir %{_localstatedir}/log/barman
+%attr(600,%{nsusr},%{nsgrp}) %ghost %{_localstatedir}/log/barman/barman.log
+
+%files %{python_files}
+%defattr(-,root,root,-)
+%python_alternative %{_bindir}/barman-wal-archive
+%python_alternative %{_bindir}/barman-wal-restore
+%python_alternative %{_bindir}/barman
+%python_alternative %{_mandir}/man1/barman.1%{?ext_man}
+%python_alternative %{_mandir}/man5/barman.5%{?ext_man}
+%python_alternative %{_mandir}/man1/barman-wal-archive.1%{?ext_man}
+%python_alternative %{_mandir}/man1/barman-wal-restore.1%{?ext_man}
+
+%{python_sitelib}/barman
+%{python_sitelib}/barman-%{version}-py*.egg-info
+%config(noreplace) %python_alternative %{_sysconfdir}/logrotate.d/barman
 
 %changelog