mirror of
https://github.com/caiwx86/small-packages.git
synced 2026-11-04 16:03:56 +08:00
update 2026-09-24 16:56:26
This commit is contained in:
1 parent
b31a5c3878
commit
e4cee331e9
6885 files changed
+3240523
No files matched your search
@@ -0,0 +1,7 @@
|
||||
config settings 'main'
|
||||
option core_repository 'svenshi/oxidns'
|
||||
option core_bundle 'full'
|
||||
option config_path '/etc/oxidns/config.yaml'
|
||||
option working_dir '/var/lib/oxidns'
|
||||
option github_token ''
|
||||
option download_proxy ''
|
||||
Executable
+45
@@ -0,0 +1,45 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
|
||||
USE_PROCD=1
|
||||
START=90
|
||||
STOP=10
|
||||
|
||||
PROG="/usr/bin/oxidns"
|
||||
DEFAULT_CONFIG_PATH="/etc/oxidns/config.yaml"
|
||||
DEFAULT_WORKING_DIR="/var/lib/oxidns"
|
||||
|
||||
load_oxidns_settings() {
|
||||
config_load oxidns
|
||||
config_get CONFIG_PATH main config_path "$DEFAULT_CONFIG_PATH"
|
||||
config_get WORKING_DIR main working_dir "$DEFAULT_WORKING_DIR"
|
||||
}
|
||||
|
||||
start_service() {
|
||||
load_oxidns_settings
|
||||
|
||||
if [ ! -x "$PROG" ]; then
|
||||
echo "oxidns binary not found or not executable: $PROG" >&2
|
||||
return 1
|
||||
fi
|
||||
if [ ! -r "$CONFIG_PATH" ]; then
|
||||
echo "oxidns config not found: $CONFIG_PATH" >&2
|
||||
return 1
|
||||
fi
|
||||
|
||||
mkdir -p "$WORKING_DIR"
|
||||
|
||||
procd_open_instance
|
||||
procd_set_param command "$PROG" start -c "$CONFIG_PATH" -d "$WORKING_DIR"
|
||||
procd_set_param respawn 3600 5 5
|
||||
procd_set_param stdout 1
|
||||
procd_set_param stderr 1
|
||||
procd_close_instance
|
||||
}
|
||||
|
||||
reload_service() {
|
||||
procd_send_signal oxidns
|
||||
}
|
||||
|
||||
service_triggers() {
|
||||
procd_add_reload_trigger oxidns
|
||||
}
|
||||
+1971
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,67 @@
|
||||
{
|
||||
"admin/services/oxidns": {
|
||||
"title": "OxiDNS",
|
||||
"order": 60,
|
||||
"action": {
|
||||
"type": "firstchild"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
},
|
||||
"admin/services/oxidns/overview": {
|
||||
"title": "Overview",
|
||||
"order": 10,
|
||||
"action": {
|
||||
"type": "view",
|
||||
"path": "oxidns/overview"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
},
|
||||
"admin/services/oxidns/core": {
|
||||
"title": "Core",
|
||||
"order": 20,
|
||||
"action": {
|
||||
"type": "view",
|
||||
"path": "oxidns/core"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
},
|
||||
"admin/services/oxidns/config": {
|
||||
"title": "Configuration",
|
||||
"order": 30,
|
||||
"action": {
|
||||
"type": "view",
|
||||
"path": "oxidns/config"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
},
|
||||
"admin/services/oxidns/logs": {
|
||||
"title": "Logs",
|
||||
"order": 40,
|
||||
"action": {
|
||||
"type": "view",
|
||||
"path": "oxidns/logs"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
},
|
||||
"admin/services/oxidns/settings": {
|
||||
"title": "Settings",
|
||||
"order": 50,
|
||||
"action": {
|
||||
"type": "view",
|
||||
"path": "oxidns/settings"
|
||||
},
|
||||
"depends": {
|
||||
"acl": [ "luci-app-oxidns" ]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
{
|
||||
"schema_version": 1,
|
||||
"targets": [
|
||||
{
|
||||
"rust_target": "x86_64-unknown-linux-musl",
|
||||
"uname_arches": [ "x86_64", "amd64" ],
|
||||
"aliases": [ "x86_64", "amd64" ]
|
||||
},
|
||||
{
|
||||
"rust_target": "aarch64-unknown-linux-musl",
|
||||
"uname_arches": [ "aarch64", "arm64" ],
|
||||
"aliases": [ "aarch64", "arm64" ]
|
||||
},
|
||||
{
|
||||
"rust_target": "i686-unknown-linux-musl",
|
||||
"uname_arches": [ "i386", "i686" ],
|
||||
"aliases": [ "i386", "i686", "x86" ]
|
||||
},
|
||||
{
|
||||
"rust_target": "arm-unknown-linux-musleabihf",
|
||||
"uname_arches": [ "armv6l", "armv6" ],
|
||||
"aliases": [ "arm", "armhf" ]
|
||||
},
|
||||
{
|
||||
"rust_target": "armv7-unknown-linux-musleabihf",
|
||||
"uname_arches": [ "armv7l", "armv7" ],
|
||||
"aliases": [ "armv7", "armv7l" ]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"luci-app-oxidns": {
|
||||
"description": "Grant access to the OxiDNS LuCI app",
|
||||
"read": {
|
||||
"ubus": {
|
||||
"luci.oxidns": [
|
||||
"status",
|
||||
"core_progress",
|
||||
"config_read",
|
||||
"settings_read",
|
||||
"logs_recent"
|
||||
]
|
||||
}
|
||||
},
|
||||
"write": {
|
||||
"ubus": {
|
||||
"luci.oxidns": [
|
||||
"core_install",
|
||||
"core_reinstall",
|
||||
"core_upload_install",
|
||||
"core_remove",
|
||||
"service_start",
|
||||
"service_stop",
|
||||
"service_restart",
|
||||
"service_enable",
|
||||
"service_disable",
|
||||
"config_validate",
|
||||
"config_save",
|
||||
"settings_save"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user