2023-11-14 01:00:30 +00:00
|
|
|
# Maintainer: Luke T. Shumaker <lukeshu@umorpha.io>
|
|
|
|
# Maintainer (AUR): Martin Rys <rys.pw/contact>
|
2022-01-10 00:23:58 +00:00
|
|
|
|
2023-11-14 01:00:30 +00:00
|
|
|
_pkgname=BookStack
|
|
|
|
pkgname=${_pkgname,,}
|
2023-11-14 01:02:45 +00:00
|
|
|
pkgver=23.10.2
|
|
|
|
pkgrel=1
|
2020-03-27 00:11:03 +00:00
|
|
|
pkgdesc='A simple, self-hosted, easy-to-use platform for organising and storing information'
|
|
|
|
arch=('any')
|
2023-11-14 01:03:06 +00:00
|
|
|
url="https://www.bookstackapp.com/"
|
2021-03-22 23:10:36 +00:00
|
|
|
license=('MIT')
|
2020-03-27 00:11:03 +00:00
|
|
|
depends=(
|
2023-02-28 15:08:15 +00:00
|
|
|
'php'
|
|
|
|
'php-gd'
|
2020-03-27 00:11:03 +00:00
|
|
|
)
|
|
|
|
makedepends=('composer')
|
2023-11-05 21:29:02 +00:00
|
|
|
source=(
|
2023-11-14 01:00:30 +00:00
|
|
|
"$_pkgname-$pkgver.tar.gz::https://github.com/BookStackApp/BookStack/archive/v${pkgver}.tar.gz"
|
2023-11-05 21:29:02 +00:00
|
|
|
'bookstack.conf'
|
|
|
|
)
|
2023-11-14 01:02:45 +00:00
|
|
|
sha256sums=('77720d16b42975d1bfbb013b7211f6574a087ffd0535f34594e7e588574b3f6a'
|
2023-12-07 05:27:42 +00:00
|
|
|
'82152fc91366d1bd623c559c03240f070e08d45a084a4c6e2e211f671bee8c78')
|
2023-11-14 01:32:48 +00:00
|
|
|
options=('!strip') # FIXME(lukeshu): stripping hangs, idk why
|
2020-03-27 00:11:03 +00:00
|
|
|
backup=("etc/webapps/$pkgname/config.env")
|
|
|
|
|
|
|
|
package() {
|
2023-11-14 01:00:30 +00:00
|
|
|
cd "$srcdir/$_pkgname-$pkgver"
|
2023-02-28 15:08:15 +00:00
|
|
|
COMPOSER_ALLOW_SUPERUSER=1 composer install --no-dev --ignore-platform-reqs --no-interaction
|
2020-03-27 00:11:03 +00:00
|
|
|
|
2023-02-28 15:08:15 +00:00
|
|
|
install -d "$pkgdir/usr/share/webapps/$pkgname" "$pkgdir/usr/share/licenses/$pkgname" "$pkgdir/etc/webapps/$pkgname"
|
|
|
|
cp -r * "$pkgdir/usr/share/webapps/$pkgname"
|
2023-11-14 01:00:30 +00:00
|
|
|
install -D "$srcdir/$_pkgname-$pkgver/LICENSE" "$pkgdir/usr/share/licenses/$pkgname"
|
2020-03-27 00:11:03 +00:00
|
|
|
|
2023-02-28 15:08:15 +00:00
|
|
|
cp .env.example "$pkgdir/etc/webapps/$pkgname/config.env"
|
2020-03-27 00:11:03 +00:00
|
|
|
|
2023-02-28 15:08:15 +00:00
|
|
|
ln -s "/etc/webapps/$pkgname/config.env" "$pkgdir/usr/share/webapps/$pkgname/.env"
|
|
|
|
rm -rf "$pkgdir/usr/share/webapps/$pkgname/bootstrap/cache"
|
2020-03-27 00:11:03 +00:00
|
|
|
|
2023-02-28 15:08:15 +00:00
|
|
|
mkdir -p "$pkgdir/var/cache/$pkgname"
|
|
|
|
ln -s "/var/cache/$pkgname" "$pkgdir/usr/share/webapps/$pkgname/bootstrap/cache"
|
2020-03-27 00:11:03 +00:00
|
|
|
|
2023-02-28 15:08:15 +00:00
|
|
|
mkdir -p "$pkgdir/var/lib"
|
|
|
|
mv "$pkgdir/usr/share/webapps/$pkgname/storage" "$pkgdir/var/lib/$pkgname"
|
|
|
|
ln -s "/var/lib/$pkgname" "$pkgdir/usr/share/webapps/$pkgname/storage"
|
2023-11-05 21:29:02 +00:00
|
|
|
|
|
|
|
install -Dm644 "${srcdir}/../bookstack.conf" "${pkgdir}/usr/lib/tmpfiles.d/bookstack.conf"
|
2020-03-27 00:11:03 +00:00
|
|
|
}
|