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
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=builds.sr.ht
pkgver=0.41.3
pkgrel=0
pkgdesc="sr.ht build service"
url="https://git.sr.ht/~sircmpwn/builds.sr.ht"
arch="all"
license="AGPLv3"
depends="
py3-ansi2html
py3-celery
py3-gunicorn
py3-pgpy
py3-redis
py3-srht
py3-yaml
"
makedepends="py-setuptools nodejs sassc go"
subpackages="$pkgname-images:_images $pkgname-worker:_worker $pkgname-openrc"
source="
$pkgname-$pkgver.tar.gz::https://git.sr.ht/~sircmpwn/$pkgname/archive/${pkgver}.tar.gz
builds.sr.ht.confd
builds.sr.ht.initd
builds.sr.ht-worker.confd
builds.sr.ht-worker.initd
"
install="$pkgname.pre-install"
builddir="$srcdir/$pkgname-$pkgver"
export PKGVER=$pkgver
options="$options !check"
build() {
cd "$builddir"
python3 setup.py build
cd worker
go build
}
package() {
cd "$builddir"
python3 setup.py install --root="$pkgdir" --optimize=1
install -Dm755 "$srcdir"/builds.sr.ht.initd \
"$pkgdir"/etc/init.d/builds.sr.ht
install -Dm644 "$srcdir"/builds.sr.ht.confd \
"$pkgdir"/etc/conf.d/builds.sr.ht
}
_images() {
depends="builds.sr.ht"
pkgdesc="builds.sr.ht build images"
cd "$builddir"
mkdir -p "$subpkgdir"/var/lib/
cp -R images "$subpkgdir"/var/lib/
}
_worker() {
depends="builds.sr.ht-images"
pkgdesc="builds.sr.ht build worker"
cd "$builddir"/worker
install -Dm755 worker "$subpkgdir"/usr/bin/builds.sr.ht-worker
install -Dm755 "$srcdir"/builds.sr.ht-worker.initd \
"$subpkgdir"/etc/init.d/builds.sr.ht-worker
install -Dm644 "$srcdir"/builds.sr.ht-worker.confd \
"$subpkgdir"/etc/conf.d/builds.sr.ht-worker
}
sha512sums="158b58618c3202dc4790fa981b6e3aa9faa2cf4a875af6d78ba46c3048dc109a9e38bb6d510ccab13a2cdbfb2c54e9c40cf53ab1a054fc64bdc95411db5e21ec builds.sr.ht-0.41.3.tar.gz
68e4abe868cd16c00d96cc54be62272a2248333bf5ad12bb6519f976f8956bba1c3b2fd7f9d9bc87eb52fa31c9ef1f3ef1f96afccbb8f780ac470a3f2a229b3a builds.sr.ht.confd
d48e195c72b3475bd3f070fc75e068966a686b3c51e398448c3894a4ee141e1c30f5a41b667afd924fb67dc86eea9f5552c6e9d187db065c4537dfd6fb5eb12c builds.sr.ht.initd
5aa18804ddfee263763b035780679b98cf4877de193c254f24fab7ce56f304556af9a377bfca36635c21b4380892e8d458a420021919934080cc43feda1694c4 builds.sr.ht-worker.confd
36e22f965a824ee368fa70c2d230f337003591009eb9f64d34b56ef28d6dad626107cba12d958d22faa04886688ea4b8b92580e4aee701da7f61522aafc44c73 builds.sr.ht-worker.initd"