summaryrefslogtreecommitdiff
path: root/app-backup/burp/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /app-backup/burp/files
reinit the tree, so we can have metadata
Diffstat (limited to 'app-backup/burp/files')
-rw-r--r--app-backup/burp/files/1.4.40-bedup-conf-path.patch33
-rw-r--r--app-backup/burp/files/1.4.40-non-zero-or-build-failure.patch13
-rw-r--r--app-backup/burp/files/1.4.40-tinfo.patch22
-rw-r--r--app-backup/burp/files/burp-2.0.54-ncurses_pkg-config.patch37
-rw-r--r--app-backup/burp/files/burp-2.0.54-no_mkdir_run.patch10
-rw-r--r--app-backup/burp/files/burp-2.0.54-protocol1_by_default.patch24
-rw-r--r--app-backup/burp/files/burp-2.0.54-server_user.patch13
-rw-r--r--app-backup/burp/files/burp-2.1.20-no_mkdir_run.patch10
-rw-r--r--app-backup/burp/files/burp-2.1.20-protocol1_by_default.patch24
-rw-r--r--app-backup/burp/files/burp.initd46
-rw-r--r--app-backup/burp/files/burp.service11
-rw-r--r--app-backup/burp/files/burp.tmpfiles1
-rw-r--r--app-backup/burp/files/burp2.initd45
13 files changed, 289 insertions, 0 deletions
diff --git a/app-backup/burp/files/1.4.40-bedup-conf-path.patch b/app-backup/burp/files/1.4.40-bedup-conf-path.patch
new file mode 100644
index 000000000000..30346d466148
--- /dev/null
+++ b/app-backup/burp/files/1.4.40-bedup-conf-path.patch
@@ -0,0 +1,33 @@
+diff -Naur burp/manpages/bedup.8 burp.new/manpages/bedup.8
+--- burp/manpages/bedup.8 2014-10-28 12:45:26.000000000 +0100
++++ burp.new/manpages/bedup.8 2014-11-21 09:49:57.705796144 +0100
+@@ -16,7 +16,7 @@
+ .SH OPTIONS
+ .TP
+ \fB\-c\fR \fBpath\fR
+-Path to config file (default: /etc/burp/burp.conf).
++Path to config file (default: /etc/burp/burp-server.conf).
+ .TP
+ \fB\-g\fR \fB<list of group names>\fR
+ Only run on the directories of clients that are in one of the groups specified. The list is comma-separated. To put a client in a group, use the 'dedup_group' option in the client configuration file on the server.
+@@ -42,7 +42,7 @@
+ \fB\-V\fR \fB\fR
+ Print version and exit.\fR
+ .TP
+-By default, bedup will read /etc/burp/burp.conf and deduplicate client storage directories using special knowledge of the structure.\fR
++By default, bedup will read /etc/burp/burp-server.conf and deduplicate client storage directories using special knowledge of the structure.\fR
+ .TP
+ With '\-n', this knowledge is turned off and you have to specify the directories to deduplicate on the command line. Running with '\-n' is therefore dangerous if you are deduplicating burp storage directories.
+
+diff -Naur burp/src/bedup.c burp.new/src/bedup.c
+--- burp/src/bedup.c 2014-10-28 12:45:56.000000000 +0100
++++ burp.new/src/bedup.c 2014-11-20 21:39:28.728206536 +0100
+@@ -740,7 +740,7 @@
+ static char *get_config_path(void)
+ {
+ static char path[256]="";
+- snprintf(path, sizeof(path), "%s", SYSCONFDIR "/burp.conf");
++ snprintf(path, sizeof(path), "%s", SYSCONFDIR "/burp-server.conf");
+ return path;
+ }
+
diff --git a/app-backup/burp/files/1.4.40-non-zero-or-build-failure.patch b/app-backup/burp/files/1.4.40-non-zero-or-build-failure.patch
new file mode 100644
index 000000000000..2c570486ce02
--- /dev/null
+++ b/app-backup/burp/files/1.4.40-non-zero-or-build-failure.patch
@@ -0,0 +1,13 @@
+diff --git a/Makefile.in b/Makefile.in
+index ac22a24..f99ce96 100755
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -40,7 +40,7 @@ all: Makefile
+ @for I in ${all_subdirs}; \
+ do (cd $$I; echo "==>Entering directory `pwd`"; \
+ $(MAKE) $@ || (echo ""; echo ""; echo " ====== Error in `pwd` ======"; \
+- echo ""; echo "";)); \
++ echo ""; echo ""; exit 1;)) || exit 1; \
+ done
+
+ depend:
diff --git a/app-backup/burp/files/1.4.40-tinfo.patch b/app-backup/burp/files/1.4.40-tinfo.patch
new file mode 100644
index 000000000000..081492261685
--- /dev/null
+++ b/app-backup/burp/files/1.4.40-tinfo.patch
@@ -0,0 +1,22 @@
+diff -Naur burp/configure.ac burp-new/configure.ac
+--- burp/configure.ac 2014-10-28 12:45:56.000000000 +0100
++++ burp-new/configure.ac 2014-11-10 17:40:50.996955441 +0100
+@@ -1203,13 +1203,12 @@
+ fi
+
+ AC_CHECK_HEADERS(ncurses.h)
+-AC_CHECK_LIB(ncurses, curs_set, [NCURSES_LIBS="-lncurses"])
+ have_ncurses=no
+-if test x$NCURSES_LIBS = x-lncurses; then
+- AC_DEFINE(HAVE_NCURSES, 1, [Defined to 1 if libncurses was found])
+- have_ncurses=yes
+-fi
+-AC_SUBST(NCURSES_LIBS)
++AC_CHECK_LIB(ncurses, endwin,
++ [NCURSES_LIBS="-lncurses"; have_ncurses=yes]
++ AC_SEARCH_LIBS(curs_set, tinfo, [NCURSES_LIBS="$NCURSES_LIBS $ac_res"]),
++ AC_DEFINE(HAVE_NCURSES, 1, [Defined to 1 if libncurses was found])
++ AC_SUBST(NCURSES_LIBS))
+
+ dnl
+ dnl Check if we have AFS on this system
diff --git a/app-backup/burp/files/burp-2.0.54-ncurses_pkg-config.patch b/app-backup/burp/files/burp-2.0.54-ncurses_pkg-config.patch
new file mode 100644
index 000000000000..07310d66b204
--- /dev/null
+++ b/app-backup/burp/files/burp-2.0.54-ncurses_pkg-config.patch
@@ -0,0 +1,37 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -1,3 +1,4 @@
++
+ dnl Process this file with autoconf to produce a configure script.
+
+ dnl require a recent autoconf
+@@ -276,21 +277,22 @@
+ dnl -----------------------------------------------------------
+
+ have_ncurses=no
+-AC_CHECK_HEADERS([ncurses.h ncurses/ncurses.h],
++m4_ifdef([PKG_CHECK_MODULES],
+ [
+- AC_CHECK_LIB([ncurses], [curs_set],
++ PKG_CHECK_MODULES([ncurses], [ncurses],
+ [
+- NCURSES_LIBS="-lncurses"
+- have_ncurses=yes
+- AC_DEFINE([HAVE_NCURSES], [1], [Set to 1 if we have ncurses])
+- ]
++ have_ncurses=yes
++ NCURSES_LIBS="$ncurses_LIBS"
++ CFLAGS="$CFLAGS $ncurses_CFLAGS -DHAVE_NCURSES_H=1"
++ AC_DEFINE([HAVE_NCURSES], [1], [Set to 1 if we have ncurses])
++ ],
++ []
+ )
+ ]
+ )
+
+ AC_SUBST([NCURSES_LIBS])
+
+-
+ dnl -----------------------------------------------------------
+ dnl Check whether libcheck ('Check') is available
+ dnl -----------------------------------------------------------
diff --git a/app-backup/burp/files/burp-2.0.54-no_mkdir_run.patch b/app-backup/burp/files/burp-2.0.54-no_mkdir_run.patch
new file mode 100644
index 000000000000..8d1cdc0a0628
--- /dev/null
+++ b/app-backup/burp/files/burp-2.0.54-no_mkdir_run.patch
@@ -0,0 +1,10 @@
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -405,7 +405,6 @@
+
+ install-data-local:
+ $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(localstatedir)/spool/burp
+- $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(runstatedir)
+
+ clean-local: clean-local-check
+
diff --git a/app-backup/burp/files/burp-2.0.54-protocol1_by_default.patch b/app-backup/burp/files/burp-2.0.54-protocol1_by_default.patch
new file mode 100644
index 000000000000..391c68a5f74b
--- /dev/null
+++ b/app-backup/burp/files/burp-2.0.54-protocol1_by_default.patch
@@ -0,0 +1,24 @@
+--- a/configs/client/burp.conf.in
++++ b/configs/client/burp.conf.in
+@@ -10,7 +10,8 @@
+ # 0 to decide automatically, 1 to force protocol1 mode (file level granularity
+ # with a pseudo mirrored storage on the server and optional rsync). 2 forces
+ # protocol2 mode (inline deduplication with variable length blocks).
+-# protocol = 0
++# WARNING: as of April 2017 protocol2 is still considered experimental.
++protocol = 1
+ pidfile = @runstatedir@/burp.client.pid
+ syslog = 0
+ stdout = 1
+--- a/configs/server/burp.conf.in
++++ b/configs/server/burp.conf.in
+@@ -21,7 +21,8 @@
+ # protocol2 mode (inline deduplication with variable length blocks).
+ # Like many other settings, this can be set per client in the clientconfdir
+ # files.
+-# protocol = 0
++# WARNING: as of April 2017 protocol2 is still considered experimental.
++protocol = 1
+ pidfile = @runstatedir@/burp.server.pid
+ hardlinked_archive = 0
+ working_dir_recovery_method = delete
diff --git a/app-backup/burp/files/burp-2.0.54-server_user.patch b/app-backup/burp/files/burp-2.0.54-server_user.patch
new file mode 100644
index 000000000000..979bb4bd4c91
--- /dev/null
+++ b/app-backup/burp/files/burp-2.0.54-server_user.patch
@@ -0,0 +1,13 @@
+--- a/configs/server/burp.conf.in
++++ b/configs/server/burp.conf.in
+@@ -68,8 +68,8 @@
+ # keep = 6
+
+ # Run as different user/group.
+-# user=graham
+-# group=nogroup
++user=burp
++group=burp
+
+ # CA options.
+ # If you want your server to be a certificate authority and generate its own
diff --git a/app-backup/burp/files/burp-2.1.20-no_mkdir_run.patch b/app-backup/burp/files/burp-2.1.20-no_mkdir_run.patch
new file mode 100644
index 000000000000..5dbdcf9e7c4c
--- /dev/null
+++ b/app-backup/burp/files/burp-2.1.20-no_mkdir_run.patch
@@ -0,0 +1,10 @@
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -417,7 +417,6 @@
+
+ install-data-local:
+ $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(localstatedir)/spool/$(PACKAGE_TARNAME)
+- $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(runstatedir)
+
+ clean-local: clean-local-check
+
diff --git a/app-backup/burp/files/burp-2.1.20-protocol1_by_default.patch b/app-backup/burp/files/burp-2.1.20-protocol1_by_default.patch
new file mode 100644
index 000000000000..db9e9b6a9de5
--- /dev/null
+++ b/app-backup/burp/files/burp-2.1.20-protocol1_by_default.patch
@@ -0,0 +1,24 @@
+--- a/configs/client/burp.conf.in
++++ b/configs/client/burp.conf.in
+@@ -10,7 +10,8 @@
+ # 0 to decide automatically, 1 to force protocol1 mode (file level granularity
+ # with a pseudo mirrored storage on the server and optional rsync). 2 forces
+ # protocol2 mode (inline deduplication with variable length blocks).
+-# protocol = 0
++# WARNING: as of September 2017 protocol2 is still considered experimental.
++protocol = 1
+ pidfile = @runstatedir@/@name@.client.pid
+ syslog = 0
+ stdout = 1
+--- a/configs/server/burp.conf.in
++++ b/configs/server/burp.conf.in
+@@ -21,7 +21,8 @@
+ # protocol2 mode (inline deduplication with variable length blocks).
+ # Like many other settings, this can be set per client in the clientconfdir
+ # files.
+-# protocol = 0
++# WARNING: as of September 2017 protocol2 is still considered experimental.
++protocol = 1
+ pidfile = @runstatedir@/@name@.server.pid
+ hardlinked_archive = 0
+ working_dir_recovery_method = delete
diff --git a/app-backup/burp/files/burp.initd b/app-backup/burp/files/burp.initd
new file mode 100644
index 000000000000..201af0a97123
--- /dev/null
+++ b/app-backup/burp/files/burp.initd
@@ -0,0 +1,46 @@
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+BURP_CONFIG="/etc/burp/burp-server.conf"
+
+description="Burp is a network backup and restore program"
+
+command="/usr/sbin/burp"
+command_args="-c '${BURP_CONFIG}' -F"
+command_background="yes"
+pidfile="/run/burp-server.pid"
+start_stop_daemon_arg="--make-pidfile --wait 500"
+
+extra_started_commands="reload summary"
+description_reload="Reloads configuration"
+description_summary="Displays main status monitor summary"
+
+get_backup_dir() {
+ grep '^directory = ' "${BURP_CONFIG}" \
+ | sed -e 's/^directory = //'
+}
+
+depend() {
+ need localmount
+ after bootmisc
+ use net
+}
+
+start_pre() {
+ checkpath -o root:burp -m 0775 -d /etc/burp
+ checkpath -o root:burp -m 0640 -f /etc/burp/burp-server.conf
+ checkpath -o root:burp -m 0750 -d /etc/burp/clientconfdir
+ checkpath -o burp:burp -m 0775 -d /run/lock/burp
+ checkpath -o root:burp -m 0770 -d "$(get_backup_dir)"
+}
+
+reload() {
+ ebegin "Reloading ${SVCNAME} configuration"
+ start-stop-daemon --exec ${command} --signal HUP
+ eend $?
+}
+
+summary() {
+ "${command}" -c "${BURP_CONFIG}" -a S
+}
diff --git a/app-backup/burp/files/burp.service b/app-backup/burp/files/burp.service
new file mode 100644
index 000000000000..5a40b5e36781
--- /dev/null
+++ b/app-backup/burp/files/burp.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=BackUp and Restore Program server
+After=network.target
+
+[Service]
+Type=simple
+PIDFile=/run/burp/burp.server.pid
+ExecStart=/usr/sbin/burp -F -c /etc/burp/burp-server.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/app-backup/burp/files/burp.tmpfiles b/app-backup/burp/files/burp.tmpfiles
new file mode 100644
index 000000000000..2f04960f230e
--- /dev/null
+++ b/app-backup/burp/files/burp.tmpfiles
@@ -0,0 +1 @@
+d /run/burp 0755 burp burp -
diff --git a/app-backup/burp/files/burp2.initd b/app-backup/burp/files/burp2.initd
new file mode 100644
index 000000000000..02a7ea856c42
--- /dev/null
+++ b/app-backup/burp/files/burp2.initd
@@ -0,0 +1,45 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+BURP_CONFIG="/etc/burp/burp-server.conf"
+
+description="Burp is a network backup and restore program"
+
+command="/usr/sbin/burp"
+command_args="-c '${BURP_CONFIG}' -F"
+command_background="yes"
+pidfile="/run/burp/burp.server.pid"
+start_stop_daemon_arg="--wait 500"
+
+extra_started_commands="reload summary"
+description_reload="Reloads configuration"
+description_summary="Displays main status monitor summary"
+
+get_backup_dir() {
+ grep '^directory = ' "${BURP_CONFIG}" \
+ | sed -e 's/^directory = //'
+}
+
+depend() {
+ need localmount
+ after bootmisc
+ use net
+}
+
+start_pre() {
+ checkpath -o root:burp -m 0775 -d /etc/burp
+ checkpath -o root:burp -m 0640 -f /etc/burp/burp-server.conf
+ checkpath -o root:burp -m 0750 -d /etc/burp/clientconfdir
+ checkpath -o root:burp -m 0770 -d "$(get_backup_dir)"
+}
+
+reload() {
+ ebegin "Reloading ${SVCNAME} configuration"
+ start-stop-daemon --exec ${command} --signal HUP
+ eend $?
+}
+
+summary() {
+ "${command}" -c "${BURP_CONFIG}" -a S
+}