New package: ntfy-2.0.0
This commit is contained in:
parent
8bddaddb36
commit
12aef41feb
|
@ -0,0 +1,3 @@
|
|||
#!/bin/sh
|
||||
exec 2>&1
|
||||
exec chpst -u _ntfy:_ntfy ntfy serve
|
|
@ -0,0 +1,31 @@
|
|||
diff --git a/server/server.yml b/server/server.yml
|
||||
index 1b26899..5de6ac1 100644
|
||||
--- a/server/server.yml
|
||||
+++ b/server/server.yml
|
||||
@@ -36,7 +36,7 @@
|
||||
# If set, also publish messages to a Firebase Cloud Messaging (FCM) topic for your app.
|
||||
# This is optional and only required to save battery when using the Android app.
|
||||
#
|
||||
-# firebase-key-file: <filename>
|
||||
+# firebase-key-file: /var/lib/ntfy/firebase.key
|
||||
|
||||
# If "cache-file" is set, messages are cached in a local SQLite database instead of only in-memory.
|
||||
# This allows for service restarts without losing messages in support of the since= parameter.
|
||||
@@ -68,7 +68,7 @@
|
||||
# If you are running ntfy with systemd, make sure this cache file is owned by the
|
||||
# ntfy user and group by running: chown ntfy.ntfy <filename>.
|
||||
#
|
||||
-# cache-file: <filename>
|
||||
+# cache-file: /var/lib/ntfy/cache.db
|
||||
# cache-duration: "12h"
|
||||
# cache-startup-queries:
|
||||
# cache-batch-size: 0
|
||||
@@ -89,7 +89,7 @@
|
||||
# If you are running ntfy with systemd, make sure this user database file is owned by the
|
||||
# ntfy user and group by running: chown ntfy.ntfy <filename>.
|
||||
#
|
||||
-# auth-file: <filename>
|
||||
+# auth-file: /var/lib/ntfy/user.db
|
||||
# auth-default-access: "read-write"
|
||||
|
||||
# If set, the X-Forwarded-For header is used to determine the visitor IP address
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/main.go b/main.go
|
||||
index 5b1428d..2f7087a 100644
|
||||
--- a/main.go
|
||||
+++ b/main.go
|
||||
@@ -24,7 +24,7 @@ the Matrix room (https://matrix.to/#/#ntfy:matrix.org).
|
||||
|
||||
ntfy %s (%s), runtime %s, built at %s
|
||||
Copyright (C) 2022 Philipp C. Heckel, licensed under Apache License 2.0 & GPLv2
|
||||
-`, version, commit[:7], runtime.Version(), date)
|
||||
+`, version, commit, runtime.Version(), date)
|
||||
|
||||
app := cmd.New()
|
||||
app.Version = version
|
|
@ -0,0 +1,30 @@
|
|||
# Template file for 'ntfy'
|
||||
pkgname=ntfy
|
||||
version=2.0.0
|
||||
revision=1
|
||||
build_style=go
|
||||
go_import_path="heckel.io/ntfy"
|
||||
go_ldflags="-X main.version=${version} -X main.commit=v${version}
|
||||
-X main.date=${SOURCE_DATE_EPOCH}"
|
||||
hostmakedepends="nodejs"
|
||||
short_desc="Send push notifications to your phone or desktop using PUT/POST"
|
||||
maintainer="Joel Beckmeyer <joel@beckmeyer.us>"
|
||||
license="Apache-2.0,GPL-2.0-only"
|
||||
homepage="https://ntfy.sh"
|
||||
distfiles="https://github.com/binwiederhier/ntfy/archive/refs/tags/v${version}.tar.gz"
|
||||
checksum=08bbb642efcc476e45c7168c2b475c3ad83e5bf2fb901c79fd2c6b76f3326a4a
|
||||
system_accounts="_ntfy"
|
||||
make_dirs="/var/lib/ntfy 0700 _ntfy _ntfy"
|
||||
_ntfy_homedir="/var/lib/ntfy"
|
||||
conf_files="/etc/ntfy/server.yml"
|
||||
|
||||
pre_build() {
|
||||
make web
|
||||
mkdir -p dist/ntfy_linux_server server/docs
|
||||
touch server/docs/index.html server/site/app.html
|
||||
}
|
||||
|
||||
post_install() {
|
||||
vsv ntfy-server
|
||||
vinstall server/server.yml 644 etc/ntfy
|
||||
}
|
Loading…
Reference in New Issue