Compare commits

..

No commits in common. "cb7f9e1e2ddccaad375d215f95792e4aefdf75ac" and "d5b339d2b51e29ba0c6f247c267761c4b860ceb9" have entirely different histories.

10 changed files with 50 additions and 26 deletions

View file

@ -6,23 +6,24 @@ pkgver=0.2.4
pkgrel=1 pkgrel=1
pkgdesc="Push update support for Nextcloud clients" pkgdesc="Push update support for Nextcloud clients"
arch=('x86_64') arch=('x86_64')
url="https://apps.nextcloud.com/apps/notify_push" url="https://github.com/nextcloud/notify_push"
license=('AGPL') license=('AGPL')
depends=('nextcloud') depends=('nextcloud')
makedepends=('rust') makedepends=('rust')
optdepends=('redis: use a local redis server') optdepends=('redis: use a local redis server')
install="$pkgname.install"
source=( source=(
"$pkgname-$pkgver.tar.gz::https://github.com/nextcloud/notify_push/archive/v$pkgver.tar.gz" "$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz"
'pacman.hook' "$pkgname.hook"
'systemd.service' "$pkgname.service"
) )
b2sums=('5136f254c51994924f89eb986ae77f0034b51ac9f8c09e5acb17cd9070e3a5f1241e9795d8fde05ce17ee383b56a95c92f84f871d2471ea5f5ec401578421dcf' b2sums=('5136f254c51994924f89eb986ae77f0034b51ac9f8c09e5acb17cd9070e3a5f1241e9795d8fde05ce17ee383b56a95c92f84f871d2471ea5f5ec401578421dcf'
'4ed61b199e995ecd29ef41505e8ce08a7e784c9e08350e2512b6cb6ad3b30d2601052d208e0d2f7d78e025971fa25a3091deb8eed232475bbd7155776ab99400' '1dd7720beba1482e1759f7dea8e9c07ae32f2107fc45fe94388993e66ad9a442771209af086b36e0cc50ab36e7a3990c6f3a120e24a525292f906e0d1a3434cd'
'21f677df863f7d52b1fb5689e1270b1df592d4502d63fab21a922fe29191dc82402909b4c4b45b2f3f41e93965312fc375ec492ca44692dcab7aaa884f7300a9') '28f2c102b1370ef7d9bc5bc736f71ccb4708e50285a1f6592535efe2ad0c301e99707021bdc4fe2be131082b1589329334b30ad0ad1e6a6764c189fb4f287170')
prepare() { prepare() {
# kludgy workaround to specify target architecture # kludgy workaround to specify target architecture
sed -i "s/ARCH/$CARCH/" systemd.service sed -i "s/ARCH/$CARCH/" "$pkgname.service"
cd "$_pkgname-$pkgver" cd "$_pkgname-$pkgver"
cargo fetch --locked --target "$CARCH-unknown-linux-gnu" cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
@ -39,25 +40,25 @@ check() {
} }
package() { package() {
# systemd integration local _appdir="$pkgdir/usr/share/webapps/nextcloud/apps/$_pkgname"
install -vDm644 systemd.service "$pkgdir/usr/lib/systemd/system/$pkgname.service"
cd "$_pkgname-$pkgver" cd "$_pkgname-$pkgver"
# documentation # documentation
install -vDm644 -t "$pkgdir/usr/share/doc/$pkgname" README.md install -Dm644 -t "$pkgdir/usr/share/doc/$pkgname" \
install -vDm644 "$srcdir/pacman.hook" \ README.md \
"$pkgdir/usr/share/doc/$pkgname/$pkgname.hook" "$srcdir/$pkgname.hook"
# app files # app files
local _appdir="$pkgdir/usr/share/webapps/nextcloud/apps/$_pkgname" install -d "$_appdir"
install -vd "$_appdir" cp -a . "$_appdir"
cp -va . "$_appdir"
# binary # binary
install -vDm755 -t "$_appdir/bin/$CARCH" "target/release/$_pkgname" install -Dm755 -t "$_appdir/bin/$CARCH" "target/release/$_pkgname"
# remove unnecessary files & folders # systemd integration
install -Dm644 -t "$pkgdir/usr/lib/systemd/system" "$srcdir/$pkgname.service"
# cleanup
cd "$_appdir" cd "$_appdir"
rm .dockerignore rm .dockerignore
cat .nextcloudignore | xargs echo rm -rf | sh cat .nextcloudignore | xargs echo rm -rf | sh

View file

@ -0,0 +1,17 @@
# Specify path to Nextcloud's config.php
NC_CLIENT_PUSH_ARGS="/etc/webapps/nextcloud/config/config.php"
# If using the config.php isn't possible, you can configure the push server by
# setting the following environment variables:
#PORT=7867 Listen port for push server
#SOCKET_PATH=/run/nextcloud/push.sock
#DATABASE_URL connection url for the Nextcloud database, e.g. postgres://user:password@db_host/db_name
#DATABASE_PREFIX database prefix configured in Nextcloud, e.g. oc_
#REDIS_URL connection url for redis, e.g. redis://redis_host
#NEXTCLOUD_URL url for the nextcloud instance, e.g. https://cloud.example.com
#LOG log level of the push server, e.g. error, warn, info, debug or trace
#METRICS_PORT Exposes Prometheus-compatible metrics on configured port if set
#ALLOW_SELF_SIGNED Disable certificate verification by setting this to true
# If both the config.php and environment variables are provided, the environment
# variables will overwrite the value from config.php

View file

@ -1,4 +1,4 @@
# Copy or symlink this file in /usr/share/libalpm/hooks/ to force a # Copy, move or symlink this file in /usr/share/libalpm/hooks/ to force a
# restart when nextcloud-app-client-push is updated. # restart when nextcloud-app-client-push is updated.
[Trigger] [Trigger]

View file

@ -0,0 +1,7 @@
post_install() {
echo "Run systemctl enable --now nextcloud-app-client-push.service"
echo "Enable the Nextcloud app via 'occ app:enable notify_push'"
echo "Set up the push server via 'occ notify_push:setup https://cloud.example.com/push'"
echo "Perform a self check via 'occ notify_push:self-test"
echo "See /usr/share/doc/nextcloud-app-client-push for README.md and a pacman hook"
}

View file

@ -1,6 +1,5 @@
[Unit] [Unit]
Description=Push daemon for Nextcloud clients Description=Push daemon for Nextcloud clients
Documentation=https://apps.nextcloud.com/apps/notify_push https://github.com/nextcloud/notify_push
[Service] [Service]
# If NC_CLIENT_PUSH_ARGS needs to be adjusted, it should be adjusted # If NC_CLIENT_PUSH_ARGS needs to be adjusted, it should be adjusted

@ -1 +1 @@
Subproject commit 9aa63363aa0e5fe4df6b6bf8595fe7cdc79038d7 Subproject commit c2d15dc05b08911cd032d113b0149ccbc6762cd3

@ -1 +1 @@
Subproject commit 44343ccee49742d26483342c120530f2d6d0aa25 Subproject commit 5ba4e55056bf6294bf2111cdd0616e505797608e

@ -1 +1 @@
Subproject commit 50d7e098f31615826a6d0312c7aaffe67df358e0 Subproject commit 9c2c23014f9fb65ca9a0965f944741c841cb371e

@ -1 +1 @@
Subproject commit 49fc95fe3c18e36c5b494db8f32ae4b8522b6bc2 Subproject commit 6c5cb5e68e8f6950ba7023ddf846569cb3d5999a

View file

@ -2,7 +2,7 @@
_gemname=oj _gemname=oj
pkgname=ruby-$_gemname pkgname=ruby-$_gemname
pkgver=3.13.7 pkgver=3.13.6
pkgrel=1 pkgrel=1
pkgdesc='The fastest JSON parser and object serializer' pkgdesc='The fastest JSON parser and object serializer'
arch=('x86_64') arch=('x86_64')
@ -13,7 +13,7 @@ makedepends=('ruby-rdoc')
options=(!emptydirs) options=(!emptydirs)
source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem") source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem")
noextract=("$_gemname-$pkgver.gem") noextract=("$_gemname-$pkgver.gem")
b2sums=('7d6b5c69d5e4e21cf1b22f5a54e781a65c7320c3a38a61db5f0b1823f3c5124a97dcdc79f59744211aeb2958d18dd3886726b0a8781e0f4d88b1d6f842281d8f') b2sums=('18d1ea3ee6ea8300f82fb86647b8658358b9a6e96775f0c9b81fdd4c1e387839fb41f2fe9c682b43c042ab061cafc4594053bc83eb3a30f6bf15d50297a26286')
package() { package() {
local _gemdir="$(ruby -e'puts Gem.default_dir')" local _gemdir="$(ruby -e'puts Gem.default_dir')"