projects
/
openwrt
/
staging
/
dedeckeh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
branding: add LEDE branding
[openwrt/staging/dedeckeh.git]
/
package
/
network
/
services
/
uhttpd
/
files
/
uhttpd.init
diff --git
a/package/network/services/uhttpd/files/uhttpd.init
b/package/network/services/uhttpd/files/uhttpd.init
index 1ebe38e8d304e85885f3dc78c241c67206c803a9..1b457a2b37ab8a2beb5168dbc6eaf37a97a9c567 100755
(executable)
--- a/
package/network/services/uhttpd/files/uhttpd.init
+++ b/
package/network/services/uhttpd/files/uhttpd.init
@@
-45,8
+45,8
@@
generate_keys() {
[ -x "$PX5G_BIN" ] && {
$PX5G_BIN selfsigned -der \
[ -x "$PX5G_BIN" ] && {
$PX5G_BIN selfsigned -der \
- -days ${days:-730} -newkey rsa:${bits:-
1024
} -keyout "${UHTTPD_KEY}.new" -out "${UHTTPD_CERT}.new" \
- -subj /C="${country:-DE}"/ST="${state:-Saxony}"/L="${location:-Leipzig}"/CN="${commonname:-
OpenWrt
}"
+ -days ${days:-730} -newkey rsa:${bits:-
2048
} -keyout "${UHTTPD_KEY}.new" -out "${UHTTPD_CERT}.new" \
+ -subj /C="${country:-DE}"/ST="${state:-Saxony}"/L="${location:-Leipzig}"/CN="${commonname:-
Lede
}"
sync
mv "${UHTTPD_KEY}.new" "${UHTTPD_KEY}"
mv "${UHTTPD_CERT}.new" "${UHTTPD_CERT}"
sync
mv "${UHTTPD_KEY}.new" "${UHTTPD_KEY}"
mv "${UHTTPD_CERT}.new" "${UHTTPD_CERT}"
@@
-80,6
+80,7
@@
start_instance()
[ -f /usr/lib/uhttpd_ubus.so ] && {
append_arg "$cfg" ubus_prefix "-u"
append_arg "$cfg" ubus_socket "-U"
[ -f /usr/lib/uhttpd_ubus.so ] && {
append_arg "$cfg" ubus_prefix "-u"
append_arg "$cfg" ubus_socket "-U"
+ append_bool "$cfg" ubus_cors "-X" 0
}
append_arg "$cfg" script_timeout "-t"
append_arg "$cfg" network_timeout "-T"
}
append_arg "$cfg" script_timeout "-t"
append_arg "$cfg" network_timeout "-T"
@@
-94,6
+95,11
@@
start_instance()
append_bool "$cfg" no_dirlists "-D" 0
append_bool "$cfg" rfc1918_filter "-R" 0
append_bool "$cfg" no_dirlists "-D" 0
append_bool "$cfg" rfc1918_filter "-R" 0
+ config_get alias_list "$cfg" alias
+ for alias in $alias_list; do
+ procd_append_param command -y "$alias"
+ done
+
config_get http "$cfg" listen_http
for listen in $http; do
procd_append_param command -p "$listen"
config_get http "$cfg" listen_http
for listen in $http; do
procd_append_param command -p "$listen"
@@
-130,12
+136,11
@@
start_instance()
append_bool "$cfg" redirect_https "-q" 0
}
append_bool "$cfg" redirect_https "-q" 0
}
- procd_close_instance
+ for file in /etc/uhttpd/*.json; do
+ [ -s "$file" ] && procd_append_param command -H "$file"
+ done
- # Check if daemon is running, if not then
- # re-execute in foreground to display error.
-# sleep 1 && service_check $UHTTPD_BIN || \
-# $UHTTPD_BIN -f $UHTTPD_ARGS
+ procd_close_instance
}
service_triggers()
}
service_triggers()