2022-12-31 10:09:44 +01:00
|
|
|
# Maintainer: Martin Rys <rys.pw/contact>
|
|
|
|
|
|
|
|
pkgname=bookstack
|
|
|
|
_camelname=BookStack
|
2024-10-10 02:00:29 +02:00
|
|
|
pkgver=24.10
|
2022-12-31 10:09:44 +01:00
|
|
|
pkgrel=1
|
|
|
|
pkgdesc='A simple, self-hosted, easy-to-use platform for organising and storing information'
|
|
|
|
arch=('any')
|
|
|
|
url="https://github.com/BookStackApp/BookStack"
|
|
|
|
license=('MIT')
|
|
|
|
depends=(
|
|
|
|
'php'
|
|
|
|
'php-gd'
|
|
|
|
'php-fpm'
|
|
|
|
)
|
|
|
|
makedepends=('composer')
|
|
|
|
source=("$pkgname-$pkgver.tar.gz::https://github.com/BookStackApp/BookStack/archive/v${pkgver}.tar.gz")
|
2024-10-10 02:00:29 +02:00
|
|
|
sha256sums=('11f010509798e0da0861c032b7b5cfe5595ebca9ee4eae56eb57425bc49e8798')
|
2022-12-31 10:09:44 +01:00
|
|
|
options=('!strip')
|
|
|
|
backup=("etc/webapps/$pkgname/config.env")
|
|
|
|
install=bookstack.install
|
|
|
|
|
|
|
|
build() {
|
|
|
|
cd "$srcdir/$_camelname-$pkgver"
|
|
|
|
|
|
|
|
COMPOSER_ALLOW_SUPERUSER=1 composer install --no-dev --ignore-platform-reqs --no-interaction --optimize-autoloader
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd "$srcdir/$_camelname-$pkgver"
|
|
|
|
|
|
|
|
install -d "$pkgdir/usr/share/webapps/$pkgname" "$pkgdir/usr/share/licenses/$pkgname" "$pkgdir/etc/webapps/$pkgname"
|
|
|
|
cp -r * "$pkgdir/usr/share/webapps/$pkgname"
|
|
|
|
install -D "$srcdir/$_camelname-$pkgver/LICENSE" "$pkgdir/usr/share/licenses/$pkgname"
|
|
|
|
|
|
|
|
cp .env.example "$pkgdir/etc/webapps/$pkgname/config.env"
|
|
|
|
|
|
|
|
ln -s "/etc/webapps/$pkgname/config.env" "$pkgdir/usr/share/webapps/$pkgname/.env"
|
|
|
|
rm -rf "$pkgdir/usr/share/webapps/$pkgname/bootstrap/cache"
|
|
|
|
|
|
|
|
mkdir -p "$pkgdir/var/cache/$pkgname"
|
|
|
|
chown http:http "$pkgdir/var/cache/$pkgname"
|
|
|
|
ln -s "/var/cache/$pkgname" "$pkgdir/usr/share/webapps/$pkgname/bootstrap/cache"
|
|
|
|
|
|
|
|
mkdir -p "$pkgdir/var/lib"
|
|
|
|
mv "$pkgdir/usr/share/webapps/$pkgname/storage" "$pkgdir/var/lib/$pkgname"
|
|
|
|
chown -R http:http "$pkgdir/var/lib/$pkgname"
|
|
|
|
chmod 775 "$pkgdir/var/lib/$pkgname"
|
|
|
|
ln -s "/var/lib/$pkgname" "$pkgdir/usr/share/webapps/$pkgname/storage"
|
|
|
|
}
|