forked from freifunk-franken/firmware
makes fff-web config a uci-defaults script
Signed-off-by: Tobias Klaus <tk+ff@meskal.net> Reviewed-by: Jan Kraus <mayosemmel@gmail.com>
This commit is contained in:
parent
e73b1d0401
commit
d16f7cdc0a
|
@ -1,35 +0,0 @@
|
||||||
|
|
||||||
config uhttpd public
|
|
||||||
list listen_http 80
|
|
||||||
option home /www/public
|
|
||||||
option rfc1918_filter 1
|
|
||||||
option cgi_prefix /cgi-bin
|
|
||||||
option script_timeout 60
|
|
||||||
option network_timeout 30
|
|
||||||
option tcp_keepalive 1
|
|
||||||
option config "_"
|
|
||||||
|
|
||||||
config uhttpd ssl
|
|
||||||
list listen_https 443
|
|
||||||
option home /www/ssl
|
|
||||||
option rfc1918_filter 1
|
|
||||||
option cert /etc/uhttpd.crt
|
|
||||||
option key /etc/uhttpd.key
|
|
||||||
option cgi_prefix /cgi-bin
|
|
||||||
option script_timeout 60
|
|
||||||
option network_timeout 30
|
|
||||||
option tcp_keepalive 1
|
|
||||||
option config "/etc/httpd.conf"
|
|
||||||
|
|
||||||
|
|
||||||
# Certificate defaults for px5g key generator
|
|
||||||
config cert px5g
|
|
||||||
|
|
||||||
# Validity time
|
|
||||||
option days 1400
|
|
||||||
|
|
||||||
# RSA key size
|
|
||||||
option bits 2048
|
|
||||||
|
|
||||||
# Common name
|
|
||||||
option commonname OpenWrt
|
|
|
@ -0,0 +1,34 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
uci batch <<EOF
|
||||||
|
delete uhttpd.public
|
||||||
|
delete uhttpd.ssl
|
||||||
|
delete uhttpd.px5g
|
||||||
|
set uhttpd.public=uhttpd
|
||||||
|
add_list uhttpd.public.listen_http='80'
|
||||||
|
set uhttpd.public.home='/www/public'
|
||||||
|
set uhttpd.public.rfc1918_filter='1'
|
||||||
|
set uhttpd.public.cgi_prefix='/cgi-bin'
|
||||||
|
set uhttpd.public.script_timeout='60'
|
||||||
|
set uhttpd.public.network_timeout='30'
|
||||||
|
set uhttpd.public.tcp_keepalive='1'
|
||||||
|
set uhttpd.public.config='_'
|
||||||
|
set uhttpd.ssl=uhttpd
|
||||||
|
add_list uhttpd.ssl.listen_https='443'
|
||||||
|
set uhttpd.ssl.home='/www/ssl'
|
||||||
|
set uhttpd.ssl.rfc1918_filter='1'
|
||||||
|
set uhttpd.ssl.cert='/etc/uhttpd.crt'
|
||||||
|
set uhttpd.ssl.key='/etc/uhttpd.key'
|
||||||
|
set uhttpd.ssl.cgi_prefix='/cgi-bin'
|
||||||
|
set uhttpd.ssl.script_timeout='60'
|
||||||
|
set uhttpd.ssl.network_timeout='30'
|
||||||
|
set uhttpd.ssl.tcp_keepalive='1'
|
||||||
|
set uhttpd.ssl.config='/etc/httpd.conf'
|
||||||
|
set uhttpd.px5g=cert
|
||||||
|
set uhttpd.px5g.days='1400'
|
||||||
|
set uhttpd.px5g.bits='2048'
|
||||||
|
set uhttpd.px5g.commonname='OpenWrt'
|
||||||
|
EOF
|
||||||
|
|
||||||
|
uci commit
|
||||||
|
exit 0
|
Loading…
Reference in New Issue