pgbackrest/pgbackrest.spec
Andrea Manzini 6355c5a7e1 Accepting request 1113999 from home:amanzini:branches:server:database:postgresql
- update to version 2.48
  * Bug Fixes:
    + Fix issue restoring block incremental without a block list. 
    + [doc] Fix configuration reference example for the tls-server-address option.
    + [doc] Fix command reference example for the filter option.
  * Features:
    + Add --repo-storage-tag option to create object tags. 
    + Add known hosts checking for SFTP storage driver. 
    + Support for dual stack connections. 
    + Add backup size completed/total to info command JSON output. 
  * Improvements:
    + Multi-stanza check command.
    + Retry reads of pg_control until checksum is valid. 
    + Optimize WAL segment check after successful backup. 
    + Improve GCS multi-part performance. 
    + Allow archive-get command to run when stanza is stopped.
    + Accept leading tilde in paths for SFTP public/private keys.
    + Reload GCS credentials before renewing authentication token. 
  * Test Suite Improvements
- refreshed patches; release.xml has been splitted into individual files

OBS-URL: https://build.opensuse.org/request/show/1113999
OBS-URL: https://build.opensuse.org/package/show/server:database:postgresql/pgbackrest?expand=0&rev=61
2023-09-28 07:41:49 +00:00

158 lines
4.7 KiB
RPMSpec

#
# spec file for package pgbackrest
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2019-2022 Ioda-Net Sàrl, Charmoille, Switzerland.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define services pgbackrest.target pgbackrest-diff@.service pgbackrest-full@.service pgbackrest-incr@.service pgbackrest.service pgbackrest-diff@.timer pgbackrest-full@.timer pgbackrest-incr@.timer
Name: pgbackrest
Version: 2.48
Release: 0
Summary: Reliable PostgreSQL Backup & Restore
License: MIT
Group: Productivity/Databases/Tools
URL: https://www.pgbackrest.org
Source: https://github.com/%{name}/%{name}/archive/release/%{version}/%{name}-%{version}.tar.gz
Source1: pgbackrest.conf
Source10: pgbackrest-diff@.service
Source11: pgbackrest-diff@.timer
Source12: pgbackrest-full@.service
Source13: pgbackrest-full@.timer
Source14: pgbackrest-incr@.service
Source15: pgbackrest-incr@.timer
Source16: pgbackrest.service
Source17: pgbackrest.target
Source18: pgbackrest.tmpfiles.d
Source98: README.SUSE
Source99: series
Patch0: libpq-fe.h_localisation.patch
Patch1: use-run-pgbackrest.patch
BuildRequires: libyaml-devel
BuildRequires: openssl-devel
BuildRequires: pkgconfig
BuildRequires: pkgconfig(bzip2)
BuildRequires: pkgconfig(libpq)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(systemd)
# This is a bit awkward as we only need this for directory ownership
Requires(pre): postgresql-server
%if 0%{?suse_version} >= 1500
BuildRequires: pkgconfig(liblz4)
%endif
%if 0%{?is_opensuse} || 0%{?sle_version} >= 150100
BuildRequires: pkgconfig(libzstd)
%endif
%description
pgBackRest aims to be a simple, reliable backup and restore system for
PostgreSQL that can seamlessly scale up to the largest databases and
workloads.
The following features are available:
- Parallel backup & restore
- Local or remote operation
- Full, incremental, differential backups
- Backup rotation & archive expiration
- Backup integrity
- Page checksums
- Backup resume
- Streaming compression & checksums
- Delta restore
- Parallel, asynchronous WAL push & get
- Tablespace & link support
- Amazon S3 support
- Encryption
- Compatibility with PostgreSQL >= 8.3
%prep
%autosetup -p1 -n %{name}-release-%{version}
%build
cp %{SOURCE98} .
pushd src
%configure
# make_build doesn't work on sle12, as long we want to support that we can not use the macro here
%make_build
popd
%install
%make_install -C src
install -D -d -m 0700 \
%{buildroot}%{_localstatedir}/lib/%{name} \
%{buildroot}%{_localstatedir}/log/%{name} \
%{buildroot}%{_localstatedir}/spool/%{name}
install -D -d -m 0755 \
%{buildroot}%{_sysconfdir} \
%{buildroot}%{_unitdir}
install -m 0644 %{SOURCE1} %{buildroot}/%{_sysconfdir}/%{name}.conf
install -m 0644 \
%{SOURCE10} \
%{SOURCE11} \
%{SOURCE12} \
%{SOURCE13} \
%{SOURCE14} \
%{SOURCE15} \
%{SOURCE16} \
%{SOURCE17} \
%{buildroot}%{_unitdir}
install -D -m 0644 \
%{SOURCE18} \
%{buildroot}%{_tmpfilesdir}/%{name}.conf
%check
# Tests are only available with Vagrant
# We just test that the binary works.
%{buildroot}/%{_bindir}/%{name} version || exit 1
%pre
%service_add_pre %{services}
%post
%tmpfiles_create %{_tmpfilesdir}/%{name}.conf
%service_add_post %{services}
%preun
%service_del_preun %{services}
%postun
%service_del_postun %{services}
%files
%doc README.md README.SUSE
%license LICENSE
%config(noreplace) %attr (640,root,postgres) %{_sysconfdir}/%{name}.conf
# We still can do that as postgres user is system fixed
%attr(-,postgres,postgres) %{_localstatedir}/log/%{name}
%attr(-,postgres,postgres) %{_localstatedir}/lib/%{name}
%attr(-,postgres,postgres) %{_localstatedir}/spool/%{name}
%ghost %dir %attr(750,postgres,postgres) /run/pgbackrest
%{_bindir}/%{name}
%{_unitdir}/pgbackrest-diff@.service
%{_unitdir}/pgbackrest-diff@.timer
%{_unitdir}/pgbackrest-full@.service
%{_unitdir}/pgbackrest-full@.timer
%{_unitdir}/pgbackrest-incr@.service
%{_unitdir}/pgbackrest-incr@.timer
%{_unitdir}/pgbackrest.service
%{_unitdir}/pgbackrest.target
%{_tmpfilesdir}/%{name}.conf
%changelog