From: George Sapkin Date: Wed, 30 Jul 2025 13:54:03 +0000 (+0300) Subject: syncthing: fix discovery and relay extra args X-Git-Url: http://git.openwrt.org/?a=commitdiff_plain;h=47644ba468fd03f805bf1afa97df589e1f4160b5;p=feed%2Fpackages.git syncthing: fix discovery and relay extra args Update configuration option examples. Fixes: #26952 Signed-off-by: George Sapkin --- diff --git a/utils/syncthing/Makefile b/utils/syncthing/Makefile index 6188efe753..a71704cb93 100644 --- a/utils/syncthing/Makefile +++ b/utils/syncthing/Makefile @@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=syncthing PKG_VERSION:=1.30.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=syncthing-source-v$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/syncthing/syncthing/releases/download/v$(PKG_VERSION) diff --git a/utils/syncthing/files/stdiscosrv.conf b/utils/syncthing/files/stdiscosrv.conf index e51ddef662..3e04014513 100644 --- a/utils/syncthing/files/stdiscosrv.conf +++ b/utils/syncthing/files/stdiscosrv.conf @@ -4,15 +4,14 @@ config stdiscosrv 'stdiscosrv' option listen ':8443' option db_dir '/etc/stdiscosrv/discovery.db' - # # Find the documents from: https://docs.syncthing.net/users/stdiscosrv.html + # Find the documents from: https://docs.syncthing.net/users/stdiscosrv.html # option cert '/etc/stdiscosrv/cert.pem' # option key '/etc/stdiscosrv/key.pem' + # option db_flush_interval '5m' # option metrics_listen '' - # option replicate '' - # option replication_listen ':19200' - # # CLI options with no value should be defined as booleans and theirs - # # names should be prefixed with '_'. + # CLI options with no value should be defined as booleans and theirs names + # should be prefixed with '_'. + # option _compression '0' # option _debug '0' # option _http '1' - diff --git a/utils/syncthing/files/stdiscosrv.init b/utils/syncthing/files/stdiscosrv.init index 566fb12eb5..7ad243a202 100644 --- a/utils/syncthing/files/stdiscosrv.init +++ b/utils/syncthing/files/stdiscosrv.init @@ -21,7 +21,7 @@ config_cb() { [ "$value" = "0" ] || extra_args="$extra_args -${option//_/-}" ;; *) - extra_args="$extra_args -${option//_/-}=$value" + extra_args="$extra_args --${option//_/-}='$value'" ;; esac } @@ -33,8 +33,7 @@ config_cb() { } } -service_triggers() -{ +service_triggers() { procd_add_reload_trigger "stdiscosrv" } diff --git a/utils/syncthing/files/strelaysrv.conf b/utils/syncthing/files/strelaysrv.conf index 56ac299ff5..b69fb824ff 100644 --- a/utils/syncthing/files/strelaysrv.conf +++ b/utils/syncthing/files/strelaysrv.conf @@ -4,13 +4,13 @@ config strelaysrv 'strelaysrv' option keys '/etc/strelaysrv' option listen ':22067' - # # Find the documents from: https://docs.syncthing.net/users/strelaysrv.html + # Find the documents from: https://docs.syncthing.net/users/strelaysrv.html # option ext_address '' # option global_rate '' # option message_timeout '1m0s' - # option nat_lease 60 - # option nat_renewal 30 - # option nat_timeout 10 + # option nat_lease '60' + # option nat_renewal '30' + # option nat_timeout '10' # option network_timeout '2m0s' # option per_session_rate '' # option ping_interval '1m0s' @@ -18,9 +18,10 @@ config strelaysrv 'strelaysrv' # option protocol 'tcp' # option provided_by '' # option status_srv ':22070' + # option token '' - # # CLI options with no value should be defined as booleans and theirs - # # names should be prefixed with '_'. + # CLI options with no value should be defined as booleans and theirs names + # should be prefixed with '_'. # option _debug '0' # option _nat '0' - + # option _pprof '0' diff --git a/utils/syncthing/files/strelaysrv.init b/utils/syncthing/files/strelaysrv.init index ced126b10a..f7fe4b9530 100644 --- a/utils/syncthing/files/strelaysrv.init +++ b/utils/syncthing/files/strelaysrv.init @@ -18,10 +18,10 @@ config_cb() { eval $option=$value ;; _*) - [ "$value" = "0" ] || extra_args="$extra_args -${option//_/-}" + [ "$value" = "0" ] || extra_args="$extra_args ${option//_/-}" ;; *) - extra_args="$extra_args -${option//_/-}=$value" + extra_args="$extra_args -${option//_/-}='$value'" ;; esac } @@ -29,12 +29,11 @@ config_cb() { list_cb() { local name="$1" local value="$2" - [ "$name" = "_" ] && extra_args="$extra_args --${value//_/-}" || return 0 + [ "$name" = "_" ] && extra_args="$extra_args -${value//_/-}" || return 0 } } -service_triggers() -{ +service_triggers() { procd_add_reload_trigger "strelaysrv" }