Merge pull request #13798 from TDT-AG/pr/20201018-extra-command-update

treewide: use new extra_command function for init
This commit is contained in:
Florian Eckert 2020-11-04 08:51:50 +01:00 committed by GitHub
commit 5e86f0d94c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
30 changed files with 41 additions and 51 deletions

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=postfix
PKG_VERSION:=3.5.7
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:= \

View file

@ -3,12 +3,11 @@
START=72
STOP=50
EXTRA_COMMANDS="status abort flush postinst"
EXTRA_HELP=" status Display the service status
abort Stop the service abruptly. Running processes are signaled to stop immediately
flush Force delivery: attempt to deliver every message in the deferred mail queue
postinst Force running a script that checks for users, group, configuration, permissions, etc"
extra_command "status" "Display the service status"
extra_command "abort" "Stop the service abruptly. Running processes are signaled to stop immediately"
extra_command "flush" "Force delivery: attempt to deliver every message in the deferred mail queue"
extra_command "postinst" "Force running a script that checks for users, group, configuration, permissions, etc"
postinst() {
if [ -z "$(postconf -nh myhostname)" ]; then

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=apfree-wifidog
PKG_VERSION:=4.08.1771
PKG_RELEASE:=5
PKG_RELEASE:=6
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/liudf0716/apfree_wifidog.git

View file

@ -9,8 +9,7 @@ USE_PROCD=1
PROG=/usr/bin/wifidogx
CONFIGFILE=/tmp/wifidogx.conf
EXTRA_COMMANDS="status"
EXTRA_HELP=" status Print the status of the service"
extra_command "status" "Print the status of the service"
PX5G_BIN="/usr/sbin/px5g"
OPENSSL_BIN="/usr/bin/openssl"

View file

@ -3,7 +3,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=gnunet
PKG_VERSION:=0.13.3
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=@GNU/gnunet
PKG_HASH:=318e06c4134d1a8ce3b4385d82b11316eaaeb9a4dbc5d4b646453dfc53199296

View file

@ -9,7 +9,8 @@ PROG=/usr/lib/gnunet/libexec/gnunet-service-arm
GNUNET_HOME=/var/run/gnunet
# LOGFILE=$GNUNET_HOME/gnunet.log
CONFIGFILE=$GNUNET_HOME/gnunet.conf
EXTRA_COMMANDS="restart_transport"
extra_command "restart_transport" "Restart transport"
prepare_config() {
local had_exit_service=0;

View file

@ -11,7 +11,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=haproxy
PKG_VERSION:=2.2.4
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://www.haproxy.org/download/2.2/src

View file

@ -6,8 +6,6 @@ STOP=80
USE_PROCD=1
EXTRA_COMMANDS="check"
HAPROXY_BIN="/usr/sbin/haproxy"
HAPROXY_CONFIG="/etc/haproxy.cfg"
@ -20,6 +18,7 @@ start_service() {
procd_close_instance
}
extra_command "check" "Check haproxy config"
check() {
$HAPROXY_BIN -c -q -V -f $HAPROXY_CONFIG
}

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=nginx
PKG_VERSION:=1.19.2
PKG_RELEASE:=3
PKG_RELEASE:=4
PKG_SOURCE:=nginx-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://nginx.org/download/

View file

@ -64,11 +64,8 @@ reload_service() {
}
extra_command "relog" "Reopen log files (without reloading)"
relog() {
[ -d /var/log/nginx ] || mkdir -p /var/log/nginx
procd_send_signal nginx '*' USR1
}
EXTRA_COMMANDS="relog"
EXTRA_HELP=" relog Reopen log files (without reloading)"

View file

@ -17,7 +17,7 @@ include ./openvswitch.mk
#
PKG_NAME:=openvswitch
PKG_VERSION:=$(ovs_version)
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://www.openvswitch.org/releases/
PKG_HASH:=4171e52a8c0ffe160c1daa6687219d902a2a6969b296d223d8dac980ab99a260

View file

@ -8,7 +8,7 @@ START=15
ovs_ctl="/usr/share/openvswitch/scripts/ovs-ctl"; [ -x "$ovs_ctl" ] || ovs_ctl=:
ovn_ctl="/usr/share/ovn/scripts/ovn-ctl"; [ -x "$ovn_ctl" ] || ovn_ctl=:
EXTRA_COMMANDS=status
extra_command "status" "Get status information"
start() {
ovs_action start "$@"

View file

@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=radicale
PKG_VERSION:=1.1.6
PKG_RELEASE:=4
PKG_RELEASE:=5
PYPI_NAME:=Radicale
PKG_HASH:=c007198ea45ef797344672c681d4c13f8b4aa85c15c41a1156225767a405c92b

View file

@ -4,8 +4,7 @@
START=80
STOP=10
EXTRA_COMMANDS="export_storage"
EXTRA_HELP=" export_storage <PATH>
extra_command "export_storage" "<PATH>
- export the storage into the specified folder
- <PATH> can be directly used with the default storage backend of Radicale 2.x.x."

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=seafile-server
PKG_VERSION:=7.1.5
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/haiwen/seafile-server/tar.gz/v$(PKG_VERSION)-server?

View file

@ -2,7 +2,8 @@
START=99
STOP=01
EXTRA_COMMANDS="generate_uci_conf"
extra_command "generate_uci_conf" "Generate uci config"
TOPDIR=/usr/share/seafile
INSTALLPATH=$TOPDIR/seafile-server

View file

@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=simple-adblock
PKG_VERSION:=1.8.4
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_MAINTAINER:=Stan Grishin <stangri@melmac.net>
PKG_LICENSE:=GPL-3.0-or-later

View file

@ -10,12 +10,11 @@ USE_PROCD=1
LC_ALL=C
# shellcheck disable=SC2034
EXTRA_COMMANDS='check dl killcache sizes show version'
# shellcheck disable=SC2034
EXTRA_HELP=' check Checks if specified domain is found in current block-list
dl Force-downloads all enabled block-list
sizes Displays the file-sizes of enabled block-lists
show Shows the service last-run status'
extra_command "check" "Checks if specified domain is found in current block-list"
extra_command "dl" "Force-downloads all enabled block-list"
extra_command "sizes" "Displays the file-sizes of enabled block-listo"
extra_command "show" "Shows the service last-run status"
extra_command "version" "Show version"
readonly packageName='simple-adblock'
readonly serviceName="$packageName $PKG_VERSION"

View file

@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=tgt
PKG_VERSION:=1.0.79
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/fujita/tgt/tar.gz/v$(PKG_VERSION)?

View file

@ -2,8 +2,7 @@
START=91
STOP=10
EXTRA_COMMANDS="show"
EXTRA_HELP=" show Show current configuration of tgtd"
extra_command "show" "Show current configuration of tgtd"
NAME=tgt
PROG=/usr/sbin/tgtd

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=tinc
PKG_VERSION:=1.0.36
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://www.tinc-vpn.org/packages

View file

@ -10,7 +10,8 @@ START=42
SERVICE_USE_PID=1
BIN=/usr/sbin/tincd
EXTRA_COMMANDS="up down"
extra_command "up" "<instance> Setting instance up"
extra_command "down" "<instance> Setting instance down"
LIST_SEP="
"

View file

@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=vpn-policy-routing
PKG_VERSION:=0.2.1
PKG_RELEASE:=13
PKG_RELEASE:=14
PKG_LICENSE:=GPL-3.0-or-later
PKG_MAINTAINER:=Stan Grishin <stangri@melmac.net>

View file

@ -15,8 +15,7 @@ readonly _ERROR_='\033[0;31mERROR\033[0m'
readonly _WARNING_='\033[0;33mWARNING\033[0m'
readonly readmeURL="https://github.com/openwrt/packages/tree/master/net/vpn-policy-routing/files/README.md"
export EXTRA_COMMANDS='support'
export EXTRA_HELP=" support Generates output required to troubleshoot routing issues
extra_command "support" "Generates output required to troubleshoot routing issues
Use '-d' option for more detailed output
Use '-p' option to automatically upload data under VPR paste.ee account
WARNING: while paste.ee uploads are unlisted, they are still publicly available

View file

@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=vpnbypass
PKG_VERSION:=1.3.1
PKG_RELEASE:=9
PKG_RELEASE:=10
PKG_LICENSE:=GPL-3.0-or-later
PKG_MAINTAINER:=Stan Grishin <stangri@melmac.net>

View file

@ -9,7 +9,7 @@ START=94
USE_PROCD=1
# shellcheck disable=SC2034
EXTRA_COMMANDS='version'
extra_command "version" "Print version information"
version() { echo "$PKG_VERSION"; }
readonly __ERROR__='\033[0;31mERROR\033[0m'

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=wifidog
PKG_VERSION:=1.3.0
PKG_RELEASE:=5
PKG_RELEASE:=6
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/wifidog/wifidog-gateway

View file

@ -4,8 +4,7 @@ START=65
USE_PROCD=1
EXTRA_COMMANDS="status"
EXTRA_HELP=" status Print the status of the service"
extra_command "status" "Print the status of the service"
start_service() {
procd_open_instance

View file

@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=docker-ce
PKG_VERSION:=19.03.13
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_LICENSE:=Apache-2.0
PKG_LICENSE_FILES:=components/cli/LICENSE components/engine/LICENSE

View file

@ -3,10 +3,8 @@
USE_PROCD=1
START=25
EXTRA_COMMANDS="uciadd ucidel"
EXTRA_HELP="\
uciadd Add default bridge configuration to network and firewall uci config
ucidel Delete default bridge configuration from network and firewall uci config"
extra_command "uciadd" "Add default bridge configuration to network and firewall uci config"
extra_command "ucidel" "Delete default bridge configuration from network and firewall uci config"
DOCKERD_CONF="/tmp/dockerd/daemon.json"