M sr.ht/lists.sr.ht/APKBUILD => sr.ht/lists.sr.ht/APKBUILD +19 -6
@@ 1,10 1,10 @@
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=lists.sr.ht
-pkgver=0.48.19
+pkgver=0.48.28
pkgrel=0
pkgdesc="sr.ht mailing list service"
url="https://git.sr.ht/~sircmpwn/lists.sr.ht"
-arch="noarch"
+arch="all"
license="AGPLv3"
depends="
py3-emailthreads
@@ 16,13 16,15 @@ depends="
py3-redis
py3-gunicorn
"
-makedepends="py-setuptools nodejs sassc"
+makedepends="py-setuptools nodejs sassc go"
subpackages="$pkgname-openrc $pkgname-nginx:_nginx"
source="
$pkgname-$pkgver.tar.gz::https://git.sr.ht/~sircmpwn/$pkgname/archive/$pkgver.tar.gz
sr.ht-nginx-$pkgver.tar.gz::https://git.sr.ht/~sircmpwn/sr.ht-nginx/archive/master.tar.gz
lists.sr.ht.initd
lists.sr.ht.confd
+ lists.sr.ht-api.initd
+ lists.sr.ht-api.confd
lists.sr.ht-process.initd
lists.sr.ht-process.confd
lists.sr.ht-lmtp.initd
@@ 36,15 38,22 @@ install="$pkgname.post-install $pkgname.post-upgrade"
build() {
python3 setup.py build
+ cd api
+ go build -o listssrht-api
}
package() {
python3 setup.py install --root="$pkgdir" --optimize=1
+ install -Dm755 api/listssrht-api "$pkgdir"/usr/bin/listssrht-api
mkdir -p "$pkgdir"/etc/init.d
install -Dm755 "$srcdir"/lists.sr.ht.initd \
"$pkgdir"/etc/init.d/lists.sr.ht
install -Dm644 "$srcdir"/lists.sr.ht.confd \
"$pkgdir"/etc/conf.d/lists.sr.ht
+ install -Dm755 "$srcdir"/lists.sr.ht-api.initd \
+ "$pkgdir"/etc/init.d/lists.sr.ht-api
+ install -Dm644 "$srcdir"/lists.sr.ht-api.confd \
+ "$pkgdir"/etc/conf.d/lists.sr.ht-api
install -Dm755 "$srcdir"/lists.sr.ht-lmtp.initd \
"$pkgdir"/etc/init.d/lists.sr.ht-lmtp
install -Dm644 "$srcdir"/lists.sr.ht-lmtp.confd \
@@ 66,13 75,17 @@ _nginx() {
"$subpkgdir"/etc/nginx/http.d/lists.sr.ht.conf
}
-sha512sums="fadf4d33817591fd76d2770795d80360386860b79c11d5b13c5ed061093074457104ffb130c76daaec8a7e9f0c31a9dac5b341aadacee4b16fda8850df6e322c lists.sr.ht-0.48.19.tar.gz
-0b2b6b2916799e20d05d6e35fdb20ac0cded65e254beb79a3aa91d4faa20fe6c93bd3e178acb2d2966841a7ce4f0149b0a863db1d57a36407ff85833779d3959 sr.ht-nginx-0.48.19.tar.gz
+sha512sums="
+141cc402c55e7ffa47f467bab245ed546c09fe77f1e23f9da485ab9627e650e062b19af1821a0d7d1566228880e8bc23f04727239677b94307ac6c4582111698 lists.sr.ht-0.48.28.tar.gz
+812803fbdcf6e9de3d44e8b1de9bf20f1031a3ddf68bcb9ada13cfa5c79543d5e29f01d6e072d8d4a6841573e656da8e0830ec13d64812055011bc4af42df107 sr.ht-nginx-0.48.28.tar.gz
50817a0e37f99f3620e539f539492567d1a69f12bfafd69c6f33eb79ba0822ee8e84bdd6c544e548f2dd40fe941e91272e22ee16948d571832029a4122bfb8e6 lists.sr.ht.initd
66d39dc5d1341c6b249035c80b90fe10c602eafc162eb084b485ad68b435378b846eda0658573d7190a4137e045f9ed87989caefbc019c6d4eac61e76523f207 lists.sr.ht.confd
+2460050d9d6e6d2ebf623c2734a31fd2d1aeaaf8161a6a2d5fdc701b3d38f8844951f2361745aad175ce0edd3b92a0bfe326beb04a239f59fb902a000f32d6f9 lists.sr.ht-api.initd
+ddd380a46dbf7f6c1fd883f2b1f80e984ba7e11bf71a53e60152549737b3253e9e7010ccdeae66811f3b2f6a8bafe241f57fc36a12b9f80379900355bb68c8ef lists.sr.ht-api.confd
b70ef07ee3247b33167111e301804d69416e8ebe020ea28587a4fd7d8fa0a81c7228309a5aa344d83f32578a7a66466f9484eac5332cfe264a538178645fd202 lists.sr.ht-process.initd
66d114850cc9002a2491458fb91947da35010e521f28a89828b0fd5ef76463a8298bd4f921f22a67c70cfc85cdf13a62a8eee71925eb6e531d81e36ff1e78982 lists.sr.ht-process.confd
4527cf69c943fcdf4ca8b9a02e3916fcadd03781995b34123b8b2a953e7962fd62f51cee5b22cb35ee702be8599015ae59dbd49583e7451a84bb1cc68f557c86 lists.sr.ht-lmtp.initd
47e703f2820bc6161909eb5434cba80b4c801fd4f18ee2b984afb217bbe43f21391ff86a8855d470b122131db1f2714a7c8c5aa58a6666123a8520327bdc0b11 lists.sr.ht-lmtp.confd
5f06d373d62096eea3c1bc6cabc220151f23705cd544be4b73d3ef488a4cffebfa5bd72455af7a1fc3b10fe08a894737fe627a1e2e2395a22d4bd08bd3042586 lists.sr.ht-webhooks.initd
-66d114850cc9002a2491458fb91947da35010e521f28a89828b0fd5ef76463a8298bd4f921f22a67c70cfc85cdf13a62a8eee71925eb6e531d81e36ff1e78982 lists.sr.ht-webhooks.confd"
+66d114850cc9002a2491458fb91947da35010e521f28a89828b0fd5ef76463a8298bd4f921f22a67c70cfc85cdf13a62a8eee71925eb6e531d81e36ff1e78982 lists.sr.ht-webhooks.confd
+"
A sr.ht/lists.sr.ht/lists.sr.ht-api.confd => sr.ht/lists.sr.ht/lists.sr.ht-api.confd +8 -0
@@ 0,0 1,8 @@
+# Run the daemon as this user:
+# LISTS_USER=lists
+
+# Bind the API service to this address:
+# LISTS_BIND=:5106
+
+# Extra arguments to pass to Gunicorn
+# LISTS_ARGS=
A sr.ht/lists.sr.ht/lists.sr.ht-api.initd => sr.ht/lists.sr.ht/lists.sr.ht-api.initd +24 -0
@@ 0,0 1,24 @@
+#!/sbin/openrc-run
+name="lists.sr.ht-api"
+description="lists.sr.ht API service"
+supervisor=supervise-daemon
+LISTS_USER=${LISTS_USER:-lists}
+LISTS_BIND=${LISTS_BIND:-:5106}
+LISTS_ARGS=${LISTS_ARGS:-}
+LOGS=/var/log/lists.sr.ht-api.log
+supervise_daemon_args="-1 $LOGS -2 $LOGS"
+command="/usr/bin/listssrht-api"
+command_args="-b $LISTS_BIND"
+command_user="$LISTS_USER:$LISTS_USER"
+pidfile="/run/${RC_SVCNAME}.pid"
+
+depend() {
+ need net
+ use redis
+ use postgresql
+ use pgbouncer
+}
+
+start_pre() {
+ checkpath -f "$LOGS" -m 644 -o "$LISTS_USER:$LISTS_USER"
+}