2020-03-27 00:11:03 +00:00
|
|
|
# Maintainer: Spencer Muise <smuise@spencermuise.ca>
|
|
|
|
pkgname=bookstack
|
|
|
|
_camelname=BookStack
|
2021-02-17 21:46:15 +00:00
|
|
|
pkgver=0.31.6
|
2021-02-20 19:29:12 +00:00
|
|
|
pkgrel=2
|
2020-03-27 00:11:03 +00:00
|
|
|
pkgdesc='A simple, self-hosted, easy-to-use platform for organising and storing information'
|
|
|
|
arch=('any')
|
|
|
|
url="https://github.com/BookStackApp/BookStack"
|
|
|
|
license=('custom')
|
|
|
|
depends=(
|
2021-01-30 02:21:37 +00:00
|
|
|
'php7'
|
|
|
|
'php7-gd'
|
|
|
|
'php7-tidy'
|
|
|
|
'php7-fpm'
|
2020-03-27 00:11:03 +00:00
|
|
|
)
|
|
|
|
makedepends=('composer')
|
|
|
|
source=("$pkgname-$pkgver.tar.gz::https://github.com/BookStackApp/BookStack/archive/v${pkgver}.tar.gz")
|
2021-02-17 21:46:15 +00:00
|
|
|
md5sums=('c3610bbba3fa663e0f8fb8a512f789f8')
|
2021-02-20 19:29:12 +00:00
|
|
|
options=('!strip')
|
2020-03-27 00:11:03 +00:00
|
|
|
backup=("etc/webapps/$pkgname/config.env")
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd "$srcdir/$_camelname-$pkgver"
|
2020-11-08 18:19:05 +00:00
|
|
|
composer install --no-scripts --no-dev --ignore-platform-reqs --no-interaction
|
2020-03-27 00:11:03 +00:00
|
|
|
|
|
|
|
install -d "$pkgdir/usr/share/webapps/$pkgname" "$pkgdir/usr/share/licenses/$pkgname" "$pkgdir/etc/webapps/$pkgname"
|
2020-11-08 18:19:05 +00:00
|
|
|
cp -r * "$pkgdir/usr/share/webapps/$pkgname"
|
2020-03-27 00:11:03 +00:00
|
|
|
install -D "$srcdir/$_camelname-$pkgver/LICENSE" "$pkgdir/usr/share/licenses/$pkgname"
|
|
|
|
|
2020-11-08 18:19:05 +00:00
|
|
|
cp .env.example "$pkgdir/etc/webapps/$pkgname/config.env"
|
2020-03-27 00:11:03 +00:00
|
|
|
|
|
|
|
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"
|
2021-02-20 19:29:12 +00:00
|
|
|
chown http:http "$pkgdir/var/cache/$pkgname"
|
2020-03-27 00:11:03 +00:00
|
|
|
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"
|
2021-02-20 19:29:12 +00:00
|
|
|
chown -R http:http "$pkgdir/var/lib/$pkgname"
|
2020-03-27 00:11:03 +00:00
|
|
|
chmod 775 "$pkgdir/var/lib/$pkgname"
|
|
|
|
ln -s "/var/lib/$pkgname" "$pkgdir/usr/share/webapps/$pkgname/storage"
|
|
|
|
}
|