mirror of
https://github.com/openwrt/packages.git
synced 2025-12-22 01:44:32 +04:00
rtty: update to 9.0.0
Two new command-line parameters have been added since this version: * -g, --group=string Set a group for the device * -i number Set heartbeat interval in seconds changelog: https://github.com/zhaojh329/rtty/releases/tag/v9.0.0 Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
This commit is contained in:
committed by
Tianling Shen
parent
d3a2fb39a7
commit
0858d257e2
@@ -8,12 +8,12 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=rtty
|
PKG_NAME:=rtty
|
||||||
PKG_VERSION:=8.1.5
|
PKG_VERSION:=9.0.0
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL=https://github.com/zhaojh329/rtty/releases/download/v$(PKG_VERSION)
|
PKG_SOURCE_URL=https://github.com/zhaojh329/rtty/releases/download/v$(PKG_VERSION)
|
||||||
PKG_HASH:=b10555e441741dad4baaa7366dfaeef81ea73dfd89fd7c478ecae1ceab74b56a
|
PKG_HASH:=5137cbe2f58588851376f2e74ded7f570320bd7cfc437d47d2485fb4be5042a1
|
||||||
|
|
||||||
PKG_MAINTAINER:=Jianhui Zhao <zhaojh329@gmail.com>
|
PKG_MAINTAINER:=Jianhui Zhao <zhaojh329@gmail.com>
|
||||||
PKG_LICENSE:=MIT
|
PKG_LICENSE:=MIT
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
#config rtty
|
#config rtty
|
||||||
# option interface 'lan'
|
# option interface 'lan'
|
||||||
# option id 'My-Device'
|
# option id 'My-Device'
|
||||||
|
# option group 'My-Group'
|
||||||
# option description 'Description of my device'
|
# option description 'Description of my device'
|
||||||
# option host 'your-server-host' # Server host
|
# option host 'your-server-host' # Server host
|
||||||
# option port '5912' # Server Port
|
# option port '5912' # Server Port
|
||||||
@@ -13,4 +14,5 @@
|
|||||||
# option insecure '1' # Allow insecure server connections when using SSL
|
# option insecure '1' # Allow insecure server connections when using SSL
|
||||||
# option token 'your-token' # generated by rttys
|
# option token 'your-token' # generated by rttys
|
||||||
# option username 'root' # Skip a second login authentication. See man login(1) about the details
|
# option username 'root' # Skip a second login authentication. See man login(1) about the details
|
||||||
|
# option heartbeat '30' # Heartbeat interval in seconds(Default is 30s)
|
||||||
# option verbose '1' # verbose log
|
# option verbose '1' # verbose log
|
||||||
|
|||||||
@@ -8,7 +8,8 @@ BIN=/usr/sbin/rtty
|
|||||||
validate_rtty_section() {
|
validate_rtty_section() {
|
||||||
uci_load_validate rtty rtty "$1" "$2" \
|
uci_load_validate rtty rtty "$1" "$2" \
|
||||||
'interface:uci("network", "@interface"):lan' \
|
'interface:uci("network", "@interface"):lan' \
|
||||||
'id:maxlength(63)' \
|
'id:maxlength(32)' \
|
||||||
|
'group:maxlength(16)' \
|
||||||
'description:maxlength(126)' \
|
'description:maxlength(126)' \
|
||||||
'host:host' \
|
'host:host' \
|
||||||
'port:port' \
|
'port:port' \
|
||||||
@@ -16,6 +17,7 @@ validate_rtty_section() {
|
|||||||
'insecure:bool:0' \
|
'insecure:bool:0' \
|
||||||
'token:maxlength(32)' \
|
'token:maxlength(32)' \
|
||||||
'username:string' \
|
'username:string' \
|
||||||
|
'heartbeat:uinteger' \
|
||||||
'verbose:bool:0'
|
'verbose:bool:0'
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -47,12 +49,14 @@ start_rtty() {
|
|||||||
|
|
||||||
procd_open_instance
|
procd_open_instance
|
||||||
procd_set_param command $BIN -h $host -I "$id" -a
|
procd_set_param command $BIN -h $host -I "$id" -a
|
||||||
|
[ -n "$group" ] && procd_append_param command -g "$group"
|
||||||
[ -n "$port" ] && procd_append_param command -p "$port"
|
[ -n "$port" ] && procd_append_param command -p "$port"
|
||||||
[ -n "$description" ] && procd_append_param command -d "$description"
|
[ -n "$description" ] && procd_append_param command -d "$description"
|
||||||
[ "$ssl" = "1" ] && procd_append_param command -s
|
[ "$ssl" = "1" ] && procd_append_param command -s
|
||||||
[ "$insecure" = "1" ] && procd_append_param command -x
|
[ "$insecure" = "1" ] && procd_append_param command -x
|
||||||
[ -n "$token" ] && procd_append_param command -t "$token"
|
[ -n "$token" ] && procd_append_param command -t "$token"
|
||||||
[ -n "$username" ] && procd_append_param command -f "$username"
|
[ -n "$username" ] && procd_append_param command -f "$username"
|
||||||
|
[ -n "$heartbeat" ] && procd_append_param command -i "$heartbeat"
|
||||||
[ "$verbose" = "1" ] && procd_append_param command -v
|
[ "$verbose" = "1" ] && procd_append_param command -v
|
||||||
procd_set_param respawn
|
procd_set_param respawn
|
||||||
procd_close_instance
|
procd_close_instance
|
||||||
|
|||||||
Reference in New Issue
Block a user