summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bareos/PKGBUILD684
-rw-r--r--bareos/bareos-bconsole.install11
-rw-r--r--bareos/bareos-common.install31
-rw-r--r--bareos/bareos-database-mysql.install24
-rw-r--r--bareos/bareos-database-postgresql.install24
-rw-r--r--bareos/bareos-director.install19
-rw-r--r--bareos/bareos-filedaemon.install11
-rw-r--r--bareos/bareos-storage-fifo.install8
-rw-r--r--bareos/bareos-storage-tape.install8
-rw-r--r--bareos/bareos-storage.install14
-rwxr-xr-xbareos/check-if-bareos-backup-is-running19
11 files changed, 0 insertions, 853 deletions
diff --git a/bareos/PKGBUILD b/bareos/PKGBUILD
deleted file mode 100644
index 8d3018551..000000000
--- a/bareos/PKGBUILD
+++ /dev/null
@@ -1,684 +0,0 @@
-# Maintainer: Erich Eckner <arch at eckner dot net>
-# Contributor: Michael Spradling <mike@mspradling.com>
-
-pkgbase='bareos'
-
-pkgname=("${pkgbase}-common"
- "${pkgbase}-bconsole"
- "${pkgbase}-database-common"
- "${pkgbase}-database-postgresql"
- "${pkgbase}-database-tools"
-# "${pkgbase}-devel"
- "${pkgbase}-director"
- "${pkgbase}-storage-fifo"
- "${pkgbase}-tools"
- "${pkgbase}-filedaemon"
- "${pkgbase}-storage"
- "${pkgbase}-storage-tape"
- "${pkgbase}-director-python-plugin"
- "${pkgbase}-filedaemon-python-plugin"
- "${pkgbase}-storage-python-plugin"
- "${pkgbase}-webui")
-
-pkgver=23.0.2
-pkgrel=5
-arch=(x86_64 i486 i686 pentium4 armv6h armv7h aarch64)
-groups=('bareos')
-pkgdesc="Bareos - Backup Archiving REcovery Open Sourced"
-url="http://www.bareos.org"
-license=('AGPL3')
-_pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libacl.so=1'
- 'libcrypto.so=3'
- 'libpam.so=0'
- 'libpq.so=5'
- 'libreadline.so=8'
- 'libz.so=1'
- 'lzo=2.10'
-)
-_pinned_dependencies_libmariadbclient=(
- 'libmariadb.so=3'
-)
-makedepends=(bash cmake lsb-release mtx python "${_pinned_dependencies[@]}")
-makedepends_x86_64=(ceph "${_pinned_dependencies_libmariadbclient[@]}")
-makedepends_i686=("${_pinned_dependencies_libmariadbclient[@]}")
-makedepends_pentium4=("${_pinned_dependencies_libmariadbclient[@]}")
-makedepends_armv6h=("${_pinned_dependencies_libmariadbclient[@]}")
-makedepends_armv7h=("${_pinned_dependencies_libmariadbclient[@]}")
-makedepends_aarch64=(ceph "${_pinned_dependencies_libmariadbclient[@]}")
-source=("$pkgbase-$pkgver.tar.gz::https://github.com/$pkgbase/$pkgbase/archive/Release/$pkgver.tar.gz"
-'check-if-bareos-backup-is-running')
-sha512sums=('a8d8270c8060480fe87da9252de86a75eea1cc427db63536f848d19a2c23c499ca294a9656d9a6aac73a756f84c96a2d72f13d1cede7948e18bf93efc2ecfc29'
- '0235763891f368c13931f0fc43e3ae2d7ec796b7ef35896b6b9c048345d539308abe4a9bafda4e95221a89231d2f373ac3cfc2098d572d4068a1c068d27452f6')
-
-prepare() {
- cd $pkgbase-Release-$pkgver
- sed -i '
- 1i #include <system_error>
- ' core/src/stored/dev.cc
-}
-
-build() {
- cd $pkgbase-Release-$pkgver
- mkdir build
- cd build
-
- cmake .. \
- -Dprefix=/usr \
- -Dsbindir=/usr/bin \
- -Dsysconfdir=/etc \
- -Dconfdir=/etc/$pkgbase \
- -Dworkingdir=/etc/$pkgbase \
- -Dlocalstatedir=/ \
- -Dlibdir=/usr/lib/$pkgbase \
- -Dmandir=/usr/share/man \
- -Ddisable-conio=yes \
- -Ddynamic-cats-backends=yes \
- -Ddynamic-storage-backends=yes \
- -Dpython=yes \
- -Dopenssl=yes \
- -Ddisable-rpath=yes \
- -Dpostgresql=yes \
- -Dndmp=no \
- -Dhostname='XXX_REPLACE_WITH_LOCAL_HOSTNAME_XXX' \
- -Ddir-password="XXX_REPLACE_WITH_DIRECTOR_PASSWORD_XXX" \
- -Dfd-password="XXX_REPLACE_WITH_CLIENT_PASSWORD_XXX" \
- -Dsd-password="XXX_REPLACE_WITH_STORAGE_PASSWORD_XXX" \
- -Dmon-dir-password="XXX_REPLACE_WITH_DIRECTOR_MONITOR_PASSWORD_XXX" \
- -Dmon-fd-password="XXX_REPLACE_WITH_CLIENT_MONITOR_PASSWORD_XXX" \
- -Dmon-sd-password="XXX_REPLACE_WITH_STORAGE_MONITOR_PASSWORD_XXX" \
- -Dbasename="XXX_REPLACE_WITH_LOCAL_HOSTNAME_XXX" \
- -Dlogdir=/var/log/$pkgbase \
- -Ddir-user=$pkgbase \
- -Ddir-group=$pkgbase \
- -Dsd-user=$pkgbase \
- -Dsd-group=$pkgbase \
- -Dfd-user=root \
- -Dfd-group=root \
- -Dconfigtemplatedir=/usr/share/$pkgbase/config \
- -Dworking-dir=/var/lib/$pkgbase \
- -Dplugindir=/usr/lib/$pkgbase/plugins \
- -Dscriptdir=/usr/lib/$pkgbase/scripts \
- -Dbackenddir=/usr/lib/$pkgbase/backends \
- -Darchivedir=/var/lib/$pkgbase/storage \
- -Dbsrdir=/var/lib/$pkgbase \
- -Dsubsys-dir=/run/$pkgbase \
- -Dsystemd=yes \
- -DCMAKE_CXX_FLAGS="-Wno-use-after-free" \
- -DCMAKE_C_FLAGS="-Wno-use-after-free"
-
- make
- make DESTDIR="$srcdir/install" install
-
- # Currently upstream systemd file does not automatically create run directory
- for _daemon in 'dir' 'fd' 'sd'; do
- sed -i '
- /^StandardOutput=syslog$/d
- /\[Service\]/a RuntimeDirectory=bareos/'"${_daemon}"'
- s@^\(WorkingDirectory=\).*$@\1/run/bareos/'"${_daemon}"'@
- ' "$srcdir/bareos-Release-$pkgver/core/platforms/systemd/bareos-${_daemon}.service"
- done
-
- find "$srcdir/install/usr/share/bareos/config" -type f \
- -exec sed -i 's@/usr/local/bin/@/usr/bin/@g' {} \;
-}
-
-package_bareos-common() {
- # Matches bareos-common.install.in
- pkgdesc="${pkgdesc} - Common files"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libacl.so=1'
- 'libcrypto.so=3'
- 'liblzo2.so=2'
- 'libssl.so=3'
- 'libz.so=1'
- )
- depends=('bash' "${_pinned_dependencies[@]}")
- install=bareos-common.install
-
-# are these really 'common'?
-# usr/lib/bareos/libbareoslmdb.so
-# usr/lib/bareos/libbareossd.so
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos"/libbareos.so.* \
- "$srcdir/install/usr/lib/bareos"/libbareosfind.so.* \
- "$srcdir/install/usr/lib/bareos"/libbareoslmdb.so.* \
- "$srcdir/install/usr/lib/bareos"/libbareossd.so.* \
- "$srcdir/install/usr/lib/bareos"/libbareosfastlz.so.* \
- -t "$pkgdir/usr/lib/bareos"
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/bareos-config" \
- -t "$pkgdir/usr/lib/bareos/scripts"
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/bareos-config-lib.sh" \
- "$srcdir/install/usr/lib/bareos/scripts/btraceback.gdb" \
- -t "$pkgdir/usr/lib/bareos/scripts"
-
- install -Dm755 \
- "$srcdir/install/usr/bin/bsmtp" \
- "$srcdir/install/usr/bin/btraceback" \
- -t "$pkgdir/usr/bin"
-
- install -Dm644 \
- "$srcdir/install/usr/share/man/man1/bsmtp.1" \
- -t "$pkgdir/usr/share/man/man1/"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/btraceback.8" \
- -t "$pkgdir/usr/share/man/man8/"
-
- install -dm755 "$pkgdir/var/lib/bareos"
- install -dm750 "$pkgdir/etc/bareos"
- install -dm755 "$pkgdir/run/bareos"
-}
-
-package_bareos-bconsole() {
- pkgdesc="${pkgdesc} - Admin Tool (CLI)"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libreadline.so=8'
- )
- depends=("bareos-common=$pkgver" "${_pinned_dependencies[@]}")
- groups+=('bareos-client')
- install=bareos-bconsole.install
-
- backup=('etc/bareos/bconsole.conf')
-
- install -Dm640 "$srcdir/install/usr/share/bareos/config/bconsole.conf" \
- -t "$pkgdir/etc/bareos"
- install -Dm755 "$srcdir/install/usr/bin/bconsole" \
- -t "$pkgdir/usr/bin"
- install -Dm644 "$srcdir/install/usr/share/man/man1/bconsole.1" \
- -t "$pkgdir/usr/share/man/man1"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-database-common() {
- pkgdesc="${pkgdesc} - Generic abstration libs and tools for sql catalog"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'libpq.so=5'
- )
- depends=("bareos-common=$pkgver" 'libcap' 'lzo' 'zlib' 'bash' 'jansson' "${_pinned_dependencies[@]}")
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos"/libbareossql.so.* \
- -t "$pkgdir/usr/lib/bareos"
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/create_bareos_database" \
- "$srcdir/install/usr/lib/bareos/scripts/drop_bareos_database" \
- "$srcdir/install/usr/lib/bareos/scripts/drop_bareos_tables" \
- "$srcdir/install/usr/lib/bareos/scripts/grant_bareos_privileges" \
- "$srcdir/install/usr/lib/bareos/scripts/make_bareos_tables" \
- "$srcdir/install/usr/lib/bareos/scripts/update_bareos_tables" \
- -t "$pkgdir/usr/lib/bareos/scripts"
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/versions.map" \
- -t "$pkgdir/usr/lib/bareos/scripts/ddl"
-}
-
-package_bareos-database-postgresql() {
- pkgdesc="${pkgdesc} - Libs and tools for postgresql catalog"
- provides=("bareos-database=$pkgver")
- local _pinned_dependencies
- _pinned_dependencies=(
- )
- depends=("bareos-common=$pkgver" "bareos-database-common=$pkgver" "${_pinned_dependencies[@]}")
- install='bareos-database-postgresql.install'
- arch=(any)
-
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/drops/postgresql.sql" \
- -t "$pkgdir/usr/lib/bareos/scripts/ddl/drops"
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/grants/postgresql-change_owner.dbconfig-template.sql" \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/grants/postgresql-readonly.sql" \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/grants/postgresql.sql" \
- -t "$pkgdir/usr/lib/bareos/scripts/ddl/grants"
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/creates/postgresql.sql" \
- -t "$pkgdir/usr/lib/bareos/scripts/ddl/creates"
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/ddl/updates/"*".sql" \
- -t "$pkgdir/usr/lib/bareos/scripts/ddl/updates"
-}
-
-package_bareos-database-tools() {
- pkgdesc="${pkgdesc} - CLI tools with database dpendencies (dbcheck, bscan)"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libcrypto.so=3'
- )
- depends=("bareos-common=$pkgver" "bareos-database-common=$pkgver" "${_pinned_dependencies[@]}")
-
- install -Dm755 \
- "$srcdir/install/usr/bin/bareos-dbcheck" \
- "$srcdir/install/usr/bin/bscan" \
- -t "$pkgdir/usr/bin"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bareos-dbcheck.8" \
- "$srcdir/install/usr/share/man/man8/bscan.8" \
- -t "$pkgdir/usr/share/man/man8"
-}
-
-#package_bareos-devel() {
-# pkgdesc="${pkgdesc} - Devel headers"
-# arch=(any)
-# # TODO
-# install -d $pkgdir/usr/include/bareos
-#}
-
-package_bareos-director() {
- pkgdesc="${pkgdesc} - Director daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libcrypto.so=3'
- 'libpam.so=0'
- )
- depends=("bareos-common=$pkgver" "bareos-database=$pkgver" "bareos-database-common=$pkgver" 'bash' "${_pinned_dependencies[@]}")
- install=bareos-director.install
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/delete_catalog_backup" \
- -t "$pkgdir/usr/lib/bareos/scripts"
- install -Dm644 \
- "$srcdir/install/usr/lib/bareos/scripts/query.sql" \
- -t "$pkgdir/usr/lib/bareos/scripts"
-
- backup=(
- 'etc/bareos/bareos-dir.d/catalog/MyCatalog.conf'
- 'etc/bareos/bareos-dir.d/client/bareos-fd.conf'
- 'etc/bareos/bareos-dir.d/console/bareos-mon.conf'
- 'etc/bareos/bareos-dir.d/director/bareos-dir.conf'
- 'etc/bareos/bareos-dir.d/fileset/Catalog.conf'
- 'etc/bareos/bareos-dir.d/fileset/LinuxAll.conf'
- 'etc/bareos/bareos-dir.d/fileset/SelfTest.conf'
- 'etc/bareos/bareos-dir.d/fileset/Windows All Drives.conf'
- 'etc/bareos/bareos-dir.d/job/backup-bareos-fd.conf'
- 'etc/bareos/bareos-dir.d/job/BackupCatalog.conf'
- 'etc/bareos/bareos-dir.d/job/RestoreFiles.conf'
- 'etc/bareos/bareos-dir.d/jobdefs/DefaultJob.conf'
- 'etc/bareos/bareos-dir.d/messages/Daemon.conf'
- 'etc/bareos/bareos-dir.d/messages/Standard.conf'
- 'etc/bareos/bareos-dir.d/pool/Differential.conf'
- 'etc/bareos/bareos-dir.d/pool/Full.conf'
- 'etc/bareos/bareos-dir.d/pool/Incremental.conf'
- 'etc/bareos/bareos-dir.d/pool/Scratch.conf'
- 'etc/bareos/bareos-dir.d/profile/operator.conf'
- 'etc/bareos/bareos-dir.d/schedule/WeeklyCycleAfterBackup.conf'
- 'etc/bareos/bareos-dir.d/schedule/WeeklyCycle.conf'
- 'etc/bareos/bareos-dir.d/storage/File.conf'
- )
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/catalog/MyCatalog.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/catalog"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/client/bareos-fd.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/client"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/console/bareos-mon.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/console"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/director/bareos-dir.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/director"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/fileset/Catalog.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/fileset/LinuxAll.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/fileset/SelfTest.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/fileset/Windows All Drives.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/fileset"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/job/backup-bareos-fd.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/job/BackupCatalog.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/job/RestoreFiles.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/job"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/jobdefs/DefaultJob.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/jobdefs"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/messages/Daemon.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/messages/Standard.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/messages"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/pool/Differential.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/pool/Full.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/pool/Incremental.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/pool/Scratch.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/pool"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/profile/operator.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/profile"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/schedule/WeeklyCycleAfterBackup.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/schedule/WeeklyCycle.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/schedule"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/storage/File.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/storage"
-
- install -Dm755 \
- "$srcdir/install/usr/bin/bareos-dir" \
- -t "$pkgdir/usr/bin"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bareos-dir.8" \
- "$srcdir/install/usr/share/man/man8/bareos.8" \
- -t "$pkgdir/usr/share/man/man8"
-
- install -Dm644 \
- "$srcdir/bareos-Release-$pkgver/core/platforms/systemd/bareos-dir.service" \
- -t "$pkgdir/usr/lib/systemd/system/"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-storage-fifo() {
- pkgdesc="${pkgdesc} - FIFO support for storage daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- )
- depends=("bareos-storage=$pkgver" 'libcap' 'jansson' 'lzo' "${_pinned_dependencies[@]}")
- install=bareos-storage-fifo.install
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/backends/libbareossd-fifo.so" \
- -t "$pkgdir/usr/lib/bareos/backends"
- backup=(
- 'etc/bareos/bareos-dir.d/storage/NULL.conf.example'
- 'etc/bareos/bareos-sd.d/device/NULL.conf.example'
- )
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/storage/NULL.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/storage"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/device/NULL.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/device"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-tools() {
- pkgdesc="${pkgdesc} - CLI tools (bcopy, bextract, bls, bregeq, bwild)"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- )
- depends=("bareos-common=$pkgver" "${_pinned_dependencies[@]}")
-
- install -Dm755 \
- "$srcdir/install/usr/bin/bregex" \
- "$srcdir/install/usr/bin/bwild" \
- "$srcdir/install/usr/bin/bcopy" \
- "$srcdir/install/usr/bin/bextract" \
- "$srcdir/install/usr/bin/bls" \
- "$srcdir/install/usr/bin/bpluginfo" \
- -t "$pkgdir/usr/bin"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man1/bwild.1" \
- "$srcdir/install/usr/share/man/man1/bregex.1" \
- -t "$pkgdir/usr/share/man/man1"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bcopy.8" \
- "$srcdir/install/usr/share/man/man8/bextract.8" \
- "$srcdir/install/usr/share/man/man8/bls.8" \
- "$srcdir/install/usr/share/man/man8/bpluginfo.8" \
- -t "$pkgdir/usr/share/man/man8"
-}
-
-package_bareos-filedaemon() {
- pkgdesc="${pkgdesc} - File daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- 'jansson=2.14'
- 'libz.so=1'
- )
- depends=("bareos-common=$pkgver" "${_pinned_dependencies[@]}")
- groups+=('bareos-client')
- install=bareos-filedaemon.install
-
- backup=(
- 'etc/bareos/bareos-fd.d/client/myself.conf'
- 'etc/bareos/bareos-fd.d/director/bareos-dir.conf'
- 'etc/bareos/bareos-fd.d/director/bareos-mon.conf'
- 'etc/bareos/bareos-fd.d/messages/Standard.conf'
- )
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-fd.d/client/myself.conf" \
- -t "$pkgdir/etc/bareos/bareos-fd.d/client"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-fd.d/director/bareos-dir.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-fd.d/director/bareos-mon.conf" \
- -t "$pkgdir/etc/bareos/bareos-fd.d/director"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-fd.d/messages/Standard.conf" \
- -t "$pkgdir/etc/bareos/bareos-fd.d/messages"
-
- install -Dm755 \
- "$srcdir/install/usr/bin/bareos-fd" \
- "$srcdir/check-if-bareos-backup-is-running" \
- -t "$pkgdir/usr/bin"
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/plugins/bpipe-fd.so" \
- -t "$pkgdir/usr/lib/bareos/plugins"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bareos-fd.8" \
- -t "$pkgdir/usr/share/man/man8"
- install -Dm644 \
- "$srcdir/bareos-Release-$pkgver/core/platforms/systemd/bareos-fd.service" \
- -t "$pkgdir/usr/lib/systemd/system"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-storage() {
- pkgdesc="${pkgdesc} - Storage daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- )
- depends=("bareos-common=$pkgver" 'lzo' 'jansson' 'libcap' "${_pinned_dependencies[@]}")
- install=bareos-storage.install
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/plugins/autoxflate-sd.so" \
- -t "$pkgdir/usr/lib/bareos/plugins"
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/disk-changer" \
- -t "$pkgdir/usr/lib/bareos/scripts"
- backup=(
- 'etc/bareos/bareos-sd.d/device/FileStorage.conf'
- 'etc/bareos/bareos-sd.d/director/bareos-dir.conf'
- 'etc/bareos/bareos-sd.d/director/bareos-mon.conf'
- 'etc/bareos/bareos-sd.d/messages/Standard.conf'
- 'etc/bareos/bareos-sd.d/storage/bareos-sd.conf'
- )
- install -Dm644 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/device/FileStorage.conf" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/device"
- install -Dm644 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/director/bareos-dir.conf" \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/director/bareos-mon.conf" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/director"
- install -Dm644 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/messages/Standard.conf" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/messages"
- install -Dm644 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/storage/bareos-sd.conf" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/storage"
- install -Dm755 \
- "$srcdir/install/usr/bin/bareos-sd" \
- -t "$pkgdir/usr/bin"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bareos-sd.8" \
- -t "$pkgdir/usr/share/man/man8"
- install -Dm644 \
- "$srcdir/bareos-Release-$pkgver/core/platforms/systemd/bareos-sd.service" \
- -t "$pkgdir/usr/lib/systemd/system"
- install -dm750 "$pkgdir/var/lib/bareos/storage"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-storage-tape() {
- pkgdesc="${pkgdesc} - Tape support for storage daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- 'gcc-libs=14.1.1+r58+gfc9fb69ad62'
- 'glibc>=2.31'
- )
- depends=("bareos-common=$pkgver" "bareos-storage=$pkgver" 'libcap' 'bash' 'jansson' 'lzo' 'mtx' "${_pinned_dependencies[@]}")
- install=bareos-storage-tape.install
- backup=(
- 'etc/bareos/mtx-changer.conf'
- 'etc/bareos/bareos-dir.d/storage/Tape.conf.example'
- 'etc/bareos/bareos-sd.d/autochanger/autochanger-0.conf.example'
- 'etc/bareos/bareos-sd.d/device/tapedrive-0.conf.example'
- )
- install -Dm640 \
- "$srcdir/install/etc/bareos/mtx-changer.conf" \
- -t "$pkgdir/etc/bareos"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-dir.d/storage/Tape.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/storage"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/autochanger/autochanger-0.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/autochanger"
- install -Dm640 \
- "$srcdir/install/usr/share/bareos/config/bareos-sd.d/device/tapedrive-0.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-sd.d/device"
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/backends/libbareossd-tape.so" \
- -t "$pkgdir/usr/lib/bareos/backends"
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/scripts/mtx-changer" \
- -t "$pkgdir/usr/lib/bareos/scripts"
- install -Dm644 \
- "$srcdir/install/usr/share/man/man8/bscrypto.8" \
- "$srcdir/install/usr/share/man/man8/btape.8" \
- -t "$pkgdir/usr/share/man/man8"
- install -Dm755 \
- "$srcdir/install/usr/bin/bscrypto" \
- "$srcdir/install/usr/bin/btape" \
- -t "$pkgdir/usr/bin"
- chmod -R o-rx "$pkgdir/etc/bareos"
-}
-
-package_bareos-director-python-plugin() {
- arch=(any)
- pkgdesc="${pkgdesc} - Python plugin for director daemon"
- local _pinned_dependencies
- _pinned_dependencies=(
- )
- depends=("bareos-common=$pkgver" "bareos-director=$pkgver" 'libcap' 'jansson' 'lzo' 'python' "${_pinned_dependencies[@]}")
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/plugins/BareosDirWrapper.py" \
- "$srcdir/install/usr/lib/bareos/plugins/BareosDirPluginBaseclass.py" \
- "$srcdir/install/usr/lib/bareos/plugins/bareos-dir-class-plugin.py" \
- -t "$pkgdir/usr/lib/bareos/plugins"
-}
-
-package_bareos-filedaemon-python-plugin() {
- pkgdesc="${pkgdesc} - Python plugin for file daemon"
- arch=(any)
- local _pinned_dependencies
- _pinned_dependencies=(
- )
- depends=("bareos-common=$pkgver" "bareos-filedaemon=$pkgver" 'python' "${_pinned_dependencies[@]}" 'libcap' 'lzo' 'jansson')
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/plugins/bareos-fd-local-fileset.py" \
- "$srcdir/install/usr/lib/bareos/plugins/BareosFdPluginBaseclass.py" \
- "$srcdir/install/usr/lib/bareos/plugins/BareosFdWrapper.py" \
- -t "$pkgdir/usr/lib/bareos/plugins"
-}
-
-package_bareos-storage-python-plugin() {
- pkgdesc="${pkgdesc} - Python plugin for storage daemon"
- arch=(any)
- local _pinned_dependencies
- _pinned_dependencies=(
- )
- depends=("bareos-common=$pkgver" "bareos-storage=$pkgver" 'lzo' 'python' 'libcap' 'jansson' "${_pinned_dependencies[@]}")
-
- install -Dm755 \
- "$srcdir/install/usr/lib/bareos/plugins/BareosSdPluginBaseclass.py" \
- "$srcdir/install/usr/lib/bareos/plugins/BareosSdWrapper.py" \
- "$srcdir/install/usr/lib/bareos/plugins/bareos-sd-class-plugin.py" \
- -t "$pkgdir/usr/lib/bareos/plugins"
-}
-
-package_bareos-webui() {
- arch=('any')
- pkgdesc="${pkgdesc} - Webui (Bareos web administration)"
- local _pinned_dependencies
- _pinned_dependencies=(
- )
- depends=('php' 'php-fpm' 'jansson')
- optdepend=('nginx' 'apache')
- backup=('etc/bareos-webui/directors.ini'
- 'etc/bareos-webui/configuration.ini'
- 'etc/bareos/bareos-dir.d/console/admin.conf.example'
- 'etc/bareos/bareos-dir.d/profile/webui-admin.conf')
-
- install -dm755 \
- "$pkgdir/etc" \
- "$pkgdir/usr/share/webapps"
- mv \
- "$srcdir/install/usr/local/share/bareos-webui" \
- "$pkgdir/usr/share/webapps/"
- mv \
- "$srcdir/install/etc/bareos-webui" \
- "$pkgdir/etc/"
-
- install -Dm644 \
- "$srcdir/install/etc/httpd/conf.d/bareos-webui.conf" \
- -t "$pkgdir/etc/httpd/conf.d/extra"
- install -Dm644 \
- "$srcdir/install/etc/bareos/bareos-dir.d/console/admin.conf.example" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/console"
- install -Dm644 \
- "$srcdir/install/etc/bareos/bareos-dir.d/profile/webui-admin.conf" \
- -t "$pkgdir/etc/bareos/bareos-dir.d/profile"
-}
-
-makedepends+=(
- $(
- for _pn in "${pkgname[@]}"; do
- (
- eval "$(
- declare -f "package_${_pn}" \
- | sed '
- s/^\s*_pinned_dependencies=(\(.*\));\?$/echo \1/
- t
- /\[ "${CARCH}" /!d
- s/return/exit/
- '
- )"
- ) \
- | tr ' ' '\n' \
- | tr -d '"'"'"
- done \
- | sort -u
- )
-)
diff --git a/bareos/bareos-bconsole.install b/bareos/bareos-bconsole.install
deleted file mode 100644
index e78060cef..000000000
--- a/bareos/bareos-bconsole.install
+++ /dev/null
@@ -1,11 +0,0 @@
-## arg 1: the new package version
-post_install() {
- /usr/lib/bareos/scripts/bareos-config initialize_local_hostname
- /usr/lib/bareos/scripts/bareos-config initialize_passwords
-
- chown -R bareos:bareos /etc/bareos
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/bareos-common.install b/bareos/bareos-common.install
deleted file mode 100644
index 426157081..000000000
--- a/bareos/bareos-common.install
+++ /dev/null
@@ -1,31 +0,0 @@
-# arg 1: the new package version
-pre_install() {
- # Create User/Group
- getent group bareos > /dev/null || groupadd --system bareos
- getent passwd bareos > /dev/null || useradd --system --gid bareos \
- --home-dir /var/lib/bareos --no-create-home bareos
-
-}
-
-# arg 1: the new package version
-post_install() {
- chown bareos:bareos /var/lib/bareos/
- chown bareos:bareos /run/bareos/
- #chown bareos:bareos /var/log/bareos/
-}
-
-# arg 1: the new package version
-# arg 2: the old package version
-pre_upgrade() {
- pre_install
-}
-
-post_upgrade() {
- post_install
-}
-
-# arg 1: the old package version
-post_remove() {
- getent passwd bareos > /dev/null && userdel bareos
- rm -f /etc/bareos/.rndpwd
-}
diff --git a/bareos/bareos-database-mysql.install b/bareos/bareos-database-mysql.install
deleted file mode 100644
index dcfdf0406..000000000
--- a/bareos/bareos-database-mysql.install
+++ /dev/null
@@ -1,24 +0,0 @@
-yellow='\e[0;33m'
-coloroff='\e[0m'
-
-# arg 0: the new package version
-post_install() {
- echo -e "${yellow}NOTE: Please see documentation (section 2.4.2) to setup database:${coloroff}"
- #echo -e "${yellow} http://doc.bareos.org/master/html/bareos-manual-main-reference.html#x1-400002.4.2${coloroff}"
- echo -e "${yellow} http://download.bareos.org/bareos/release/17.2/documentation/html/bareos-manual-main-reference.html#QQ2-1-47${coloroff}"
-
-}
-
-# arg 0: the new package version
-# arg 2: the old package version
-post_upgrade() {
- #echo -e "${yellow}NOTE: Please see documentation (section) 3.1.2 to update database${coloroff}"
- #echo -e "${yellow} http://doc.bareos.org/master/html/bareos-manual-main-reference.html#x1-450003.1.2${coloroff}"
- echo -e "${yellow}NOTE: Please see documentation (section) 4.2.2 to update database${coloroff}"
- echo -e "${yellow} http://download.bareos.org/bareos/release/17.2/documentation/html/bareos-manual-main-reference.html#x1-710004.2.2${coloroff}"
-}
-
-# arg 0: the old package version
-post_remove() {
- echo -e "${yellow}NOTE: To remove all traces of bareos please delete the bareos database.${coloroff}"
-}
diff --git a/bareos/bareos-database-postgresql.install b/bareos/bareos-database-postgresql.install
deleted file mode 100644
index dcfdf0406..000000000
--- a/bareos/bareos-database-postgresql.install
+++ /dev/null
@@ -1,24 +0,0 @@
-yellow='\e[0;33m'
-coloroff='\e[0m'
-
-# arg 0: the new package version
-post_install() {
- echo -e "${yellow}NOTE: Please see documentation (section 2.4.2) to setup database:${coloroff}"
- #echo -e "${yellow} http://doc.bareos.org/master/html/bareos-manual-main-reference.html#x1-400002.4.2${coloroff}"
- echo -e "${yellow} http://download.bareos.org/bareos/release/17.2/documentation/html/bareos-manual-main-reference.html#QQ2-1-47${coloroff}"
-
-}
-
-# arg 0: the new package version
-# arg 2: the old package version
-post_upgrade() {
- #echo -e "${yellow}NOTE: Please see documentation (section) 3.1.2 to update database${coloroff}"
- #echo -e "${yellow} http://doc.bareos.org/master/html/bareos-manual-main-reference.html#x1-450003.1.2${coloroff}"
- echo -e "${yellow}NOTE: Please see documentation (section) 4.2.2 to update database${coloroff}"
- echo -e "${yellow} http://download.bareos.org/bareos/release/17.2/documentation/html/bareos-manual-main-reference.html#x1-710004.2.2${coloroff}"
-}
-
-# arg 0: the old package version
-post_remove() {
- echo -e "${yellow}NOTE: To remove all traces of bareos please delete the bareos database.${coloroff}"
-}
diff --git a/bareos/bareos-director.install b/bareos/bareos-director.install
deleted file mode 100644
index b464fee64..000000000
--- a/bareos/bareos-director.install
+++ /dev/null
@@ -1,19 +0,0 @@
-## arg 1: the new package version
-post_install() {
- /usr/lib/bareos/scripts/bareos-config initialize_local_hostname
- /usr/lib/bareos/scripts/bareos-config initialize_passwords
-
- chown -R bareos:bareos /etc/bareos
-
- /usr/lib/bareos/scripts/bareos-config initialize_database_driver
- /usr/lib/bareos/scripts/bareos-config apply_dbconfig_settings
-
- #for dir in /etc/bareos/bareos-dir-export/ /etc/bareos/bareos-dir-export/client; do
- #chown bareos:bareos "$dir"
- #chmod 750 "$dir"
- #done
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/bareos-filedaemon.install b/bareos/bareos-filedaemon.install
deleted file mode 100644
index d88a62090..000000000
--- a/bareos/bareos-filedaemon.install
+++ /dev/null
@@ -1,11 +0,0 @@
-## arg 1: the new package version
-post_install() {
- /usr/lib/bareos/scripts/bareos-config initialize_local_hostname
- /usr/lib/bareos/scripts/bareos-config initialize_passwords
-
- chown -R bareos:bareos /etc/bareos
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/bareos-storage-fifo.install b/bareos/bareos-storage-fifo.install
deleted file mode 100644
index 8d57d9573..000000000
--- a/bareos/bareos-storage-fifo.install
+++ /dev/null
@@ -1,8 +0,0 @@
-## arg 1: the new package version
-post_install() {
- chown -R bareos:bareos /etc/bareos
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/bareos-storage-tape.install b/bareos/bareos-storage-tape.install
deleted file mode 100644
index 8d57d9573..000000000
--- a/bareos/bareos-storage-tape.install
+++ /dev/null
@@ -1,8 +0,0 @@
-## arg 1: the new package version
-post_install() {
- chown -R bareos:bareos /etc/bareos
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/bareos-storage.install b/bareos/bareos-storage.install
deleted file mode 100644
index 883336373..000000000
--- a/bareos/bareos-storage.install
+++ /dev/null
@@ -1,14 +0,0 @@
-## arg 1: the new package version
-post_install() {
- /usr/lib/bareos/scripts/bareos-config initialize_local_hostname
- /usr/lib/bareos/scripts/bareos-config initialize_passwords
-
- chown -R bareos:bareos /etc/bareos
- chown bareos:bareos /var/lib/bareos/storage/
-
- /usr/lib/bareos/scripts/bareos-config setup_sd_user
-}
-
-post_upgrade() {
- post_install
-}
diff --git a/bareos/check-if-bareos-backup-is-running b/bareos/check-if-bareos-backup-is-running
deleted file mode 100755
index bc3d2e104..000000000
--- a/bareos/check-if-bareos-backup-is-running
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-if [ $# -ne 0 ]; then
- >&2 echo 'check-if-bareos-backup-is-running: too many arguments'
- exit 2
-fi
-
-if cat /proc/net/tcp* \
-| awk '{print $2 " " $3}' \
-| grep -vw '\(000000000000000000000000\)\?00000000:0000' \
-| tr ' ' '\n' \
-| grep -F : \
-| cut -d: -f2 \
-| grep -qxiF '238F'; then
- >&2 echo 'bareos-fd is connected to bareos-sd'
- exit 1
-else
- >&2 echo 'bareos-fd is not connected to bareos-sd'
-fi