blob: 76727d2b65fde2a2e7bb5ca75336f36f7c6bf180 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
|
# Maintainer: jab416171 <jab416171@gmail.com>
# Maintainer: txtsd <aur.archlinux@ihavea.quest>
# Contributor: Donald Webster <fryfrog@gmail.com>
# Contributor: Martins Mozeiko <martins.mozeiko@gmail.com>
pkgname=jellyseerr
pkgver=2.5.1
pkgrel=1
pkgdesc='Request management and media discovery tool for the Plex ecosystem'
arch=(x86_64 aarch64)
url='https://github.com/Fallenbagel/jellyseerr'
license=('MIT')
depends=(
bash
gcc-libs
glibc
nodejs
)
optdepends=(
'jellyfin-server: The Free Software Media System'
'plex-media-server: Plex Media Server'
'emby-server: The open media solution'
'sonarr: Smart PVR for newsgroup and torrent users'
'radarr: Movie organizer/manager for usenet and torrent users'
)
makedepends=(pnpm)
backup=(
etc/conf.d/jellyseerr
usr/lib/jellyseerr/config/settings.json
)
options=(!strip !debug)
install=jellyseerr.install
source=(
"${pkgname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz"
# "arch.patch::${url}/compare/develop...pnpm-10-for-arch-folks.patch"
arch.patch
jellyseerr.sysusers
jellyseerr.tmpfiles
jellyseerr.service
jellyseerr.conf.d
)
sha256sums=('09f93efa26f456435543966a87760185e6d4449e20cf3323d212d4f874f061c4'
'c7aa1a366c970e9963b3754cad576dddf5fa2598a51f871fd5718a8389077029'
'092221b83ded237f57003587533f623d9bc70455493dae9508bb0edac226f9cd'
'202d6e4c1d4ee555c33fe7e8473c74aef795e145f3bbc885333c003a75e17f14'
'ee4a4ed8b2ff41fe00582e11283526a08a2ed1154e8e278d898d98c8184c65eb'
'5a446cc8fa0a47a49dbbd6920d49eb4569f988e808cbb0bdbb609ab179a94426')
prepare() {
cd "${pkgname}-${pkgver}"
patch -Np1 -i "../arch.patch"
sed -i 's/husky install//' package.json
echo "{\"commitTag\": \"${pkgver}\"}" > committag.json
export NEXT_TELEMETRY_DISABLED=1
pnpm install --frozen-lockfile
}
build() {
cd "${pkgname}-${pkgver}"
export NEXT_TELEMETRY_DISABLED=1
export CYPRESS_INSTALL_BINARY=0
# See: https://aur.archlinux.org/packages/jellyseerr#comment-998270
export SHARP_IGNORE_GLOBAL_LIBVIPS=1
pnpm build
pnpm prune --prod --ignore-scripts
}
package() {
cd "${pkgname}-${pkgver}"
install -dm755 "${pkgdir}/usr/lib/jellyseerr"
# Copy jellyseerr
cp -dr --no-preserve='ownership' ./{.next,dist,public,node_modules} "${pkgdir}/usr/lib/jellyseerr"
cp -d --no-preserve='ownership' ./{package.json,jellyseerr-api.yml,next.config.js} "${pkgdir}/usr/lib/jellyseerr"
# Remove cache
rm -rf "${pkgdir}/usr/lib/jellyseerr/.next/cache"
# Fix paths
find "${pkgdir}/usr/lib/jellyseerr/.next" -type f -print0 | xargs -0 sed -i "s^${srcdir}/${pkgname}-${pkgver}^/usr/lib/jellyseerr^g"
# Install license
install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
# Systemd
cd "${srcdir}"
install -Dm644 jellyseerr.conf.d "${pkgdir}/etc/conf.d/jellyseerr"
install -Dm644 jellyseerr.sysusers "${pkgdir}/usr/lib/sysusers.d/jellyseerr.conf"
install -Dm644 jellyseerr.tmpfiles "${pkgdir}/usr/lib/tmpfiles.d/jellyseerr.conf"
install -Dm644 jellyseerr.service "${pkgdir}/usr/lib/systemd/system/jellyseerr.service"
}
|