summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authork0n24d2016-06-18 17:42:58 +0200
committerk0n24d2016-06-18 17:42:58 +0200
commitd341109bc04488105efbfbeb548d22073581b41c (patch)
treea74ad2c50bf8227a6ede1ace328eb484097de415
downloadaur-d341109bc04488105efbfbeb548d22073581b41c.tar.gz
Initial version
-rw-r--r--.SRCINFO29
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD44
-rw-r--r--urbackup.install10
4 files changed, 87 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..f6792f68950
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,29 @@
+pkgbase = urbackup2-server
+ pkgdesc = Client Server backup system
+ pkgver = 2.0.29
+ pkgrel = 1
+ url = http://www.urbackup.org/
+ install = urbackup.install
+ arch = i686
+ arch = x86_64
+ arch = armv5
+ arch = armv6h
+ arch = armv6
+ arch = armv7h
+ arch = armv7
+ arch = aarch64
+ license = GPL
+ makedepends = gcc-libs
+ makedepends = gcc
+ makedepends = make
+ depends = sqlite
+ depends = crypto++
+ depends = curl
+ depends = fuse
+ depends = zlib
+ conflicts = urbackup-server
+ source = https://www.urbackup.org/downloads/Server/2.0.29/urbackup-server-2.0.29.tar.gz
+ md5sums = f2d73ca40ce399240170c825f9c8e23b
+
+pkgname = urbackup2-server
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..c48ff97dd55
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+src
+pkg
+urbackup*.pkg.tar.xz
+urbackup*.tar.gz
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..bd0969adc4c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,44 @@
+# Contributor: K0n24d <konrad AT knauber DOT net>
+pkgname=urbackup2-server
+pkgver=2.0.29
+pkgrel=1
+pkgdesc="Client Server backup system"
+arch=('i686' 'x86_64' 'armv5' 'armv6h' 'armv6' 'armv7h' 'armv7' 'aarch64')
+url="http://www.urbackup.org/"
+license=('GPL')
+makedepends=('gcc-libs' 'gcc' 'make')
+depends=('sqlite' 'crypto++' 'curl' 'fuse' 'zlib')
+conflicts=('urbackup-server')
+source=("https://www.urbackup.org/downloads/Server/${pkgver}/urbackup-server-${pkgver}.tar.gz")
+install='urbackup.install'
+md5sums=('f2d73ca40ce399240170c825f9c8e23b')
+
+CFLAGS="-march=native -O2 -pipe -fstack-protector-strong -ansi"
+CXXFLAGS="${CFLAGS}"
+MAKEFLAGS="-j$(nproc)"
+
+build() {
+ cd "${srcdir}/urbackup-server-${pkgver}"
+ ./configure --prefix=/usr --sbindir=/usr/bin --sysconfdir=/etc \
+ --localstatedir=/var --enable-packaging \
+ --with-mountvhd --with-zlib --with-libcurl
+ make
+}
+
+package() {
+ cd "${srcdir}/urbackup-server-${pkgver}"
+
+ make DESTDIR=$pkgdir install
+
+ install -Dm644 "${srcdir}/urbackup-server-${pkgver}"/urbackup-server.service \
+ "${pkgdir}"/usr/lib/systemd/system/urbackup-server.service
+ install -Dm644 "${srcdir}/urbackup-server-${pkgver}"/urbackup-server-firewalld.xml \
+ "${pkgdir}"/usr/lib/firewalld/services/urbackup-server-firewalld.xml
+ install -Dm644 "${srcdir}/urbackup-server-${pkgver}"/logrotate_urbackupsrv \
+ "${pkgdir}"/etc/logrotate.d/urbackupsrv
+ install -Dm644 "${srcdir}/urbackup-server-${pkgver}"/docs/urbackupsrv.1 \
+ "${pkgdir}"/usr/share/man/man1/urbackupsrv.1
+ install -Dm644 "${srcdir}/urbackup-server-${pkgver}"/defaults_server \
+ "${pkgdir}"/etc/default/urbackupsrv
+}
+# vim: ts=2
diff --git a/urbackup.install b/urbackup.install
new file mode 100644
index 00000000000..28083ae1eac
--- /dev/null
+++ b/urbackup.install
@@ -0,0 +1,10 @@
+post_install() {
+ _urbackup_user="urbackup"
+ _urbackup_group="urbackup"
+
+ getent group $_urbackup_group > /dev/null || groupadd -r $_urbackup_group > /dev/null
+ getent passwd $_urbackup_user > /dev/null || useradd -r -g $_urbackup_group \
+ -d /dev/null -s /bin/false $_urbackup_user > /dev/null
+
+ chown -hR --preserve-root $_urbackup_user:$_urbackup_group /var/urbackup
+}