Development
This commit is contained in:
parent
e77ebdb100
commit
226a2e2e06
10 changed files with 444 additions and 368 deletions
|
|
@ -11,17 +11,16 @@
|
|||
"label": "%MENU_LABEL%",
|
||||
"client_requirement": "client_is_viewer+",
|
||||
"items": [
|
||||
{ "type": "nav_item", "label": "General", "map_to": "view_general", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "VLANs", "map_to": "view_vlans", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "Inter-VLAN Exceptions","map_to": "view_inter_vlan", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "Upstream DNS", "map_to": "view_upstream_dns", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DNS Blocklists", "map_to": "view_blocklists", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "Port Forwarding", "map_to": "view_port_forwarding","client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DHCP", "map_to": "view_dhcp" },
|
||||
{ "type": "nav_item", "label": "Host Overrides", "map_to": "view_host_overrides", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DDNS", "map_to": "view_ddns" },
|
||||
{ "type": "nav_item", "label": "VPN", "map_to": "view_vpn" },
|
||||
{ "type": "nav_item", "label": "Banned IPs", "map_to": "view_banned_ips", "client_requirement": "client_is_administrator+" }
|
||||
{ "type": "nav_item", "label": "General", "map_to": "view_general", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "VLANs", "map_to": "view_vlans", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "Inter-VLAN Exceptions", "map_to": "view_inter_vlan", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DNS Server", "map_to": "view_dns_server", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "Port Forwarding", "map_to": "view_port_forwarding", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DHCP", "map_to": "view_dhcp" },
|
||||
{ "type": "nav_item", "label": "Host Overrides", "map_to": "view_host_overrides", "client_requirement": "client_is_administrator+" },
|
||||
{ "type": "nav_item", "label": "DDNS", "map_to": "view_ddns" },
|
||||
{ "type": "nav_item", "label": "VPN", "map_to": "view_vpn" },
|
||||
{ "type": "nav_item", "label": "Banned IPs", "map_to": "view_banned_ips", "client_requirement": "client_is_administrator+" }
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -30,9 +29,9 @@
|
|||
"align": "right",
|
||||
"client_requirement": "client_is_viewer+",
|
||||
"items": [
|
||||
{ "type": "nav_item", "label": "Preferences", "map_to": "view_preferences" },
|
||||
{ "type": "nav_item", "label": "Preferences", "map_to": "view_preferences" },
|
||||
{ "type": "nav_item", "label": "Manage Accounts", "map_to": "view_manage_accounts", "client_requirement": "client_is_manager+" },
|
||||
{ "type": "nav_action", "label": "Log Out", "action": "log_out" }
|
||||
{ "type": "nav_action", "label": "Log Out", "action": "log_out" }
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -499,7 +499,7 @@
|
|||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/apply_interface",
|
||||
"action": "/action/general_cardnetworkinterface_save",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
|
|
@ -524,7 +524,7 @@
|
|||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/apply_interface",
|
||||
"action": "/action/general_cardnetworkinterface_save",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
|
|
@ -537,6 +537,62 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "card",
|
||||
"label": "Upstream DNS",
|
||||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/general_cardupstreamdns_save",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Strict Order",
|
||||
"name": "strict_order",
|
||||
"input_type": "checkbox",
|
||||
"value": "%DNS_STRICT_ORDER%",
|
||||
"hint": "Query DNS providers in list order rather than in parallel."
|
||||
},
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Cache Size",
|
||||
"name": "cache_size",
|
||||
"input_type": "number",
|
||||
"value": "%DNS_CACHE_SIZE%",
|
||||
"min": 0,
|
||||
"hint": "Max DNS responses to cache per instance. Set to 0 to disable caching."
|
||||
},
|
||||
{
|
||||
"type": "editable_list",
|
||||
"label": "DNS Providers",
|
||||
"name": "upstream_servers",
|
||||
"items": "%DNS_UPSTREAM_SERVERS_JSON%",
|
||||
"item_placeholder": "e.g. 1.1.1.1",
|
||||
"add_label": "Add Provider",
|
||||
"validate": "ip",
|
||||
"hint": "DNS resolvers queried for external hostnames. Supports IPv4 and IPv6."
|
||||
},
|
||||
{
|
||||
"type": "button_row",
|
||||
"items": [
|
||||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/general_cardupstreamdns_save",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
"type": "button_cancel",
|
||||
"text": "Cancel"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"client_requirement": "client_is_administrator+"
|
||||
},
|
||||
{
|
||||
"type": "card",
|
||||
"id": "iface-config-card",
|
||||
|
|
@ -578,12 +634,30 @@
|
|||
"input_type": "select",
|
||||
"value": "",
|
||||
"options": [
|
||||
{"value": "576", "label": "576"},
|
||||
{"value": "1280", "label": "1280"},
|
||||
{"value": "1492", "label": "1492"},
|
||||
{"value": "1500", "label": "1500"},
|
||||
{"value": "4096", "label": "4096"},
|
||||
{"value": "9000", "label": "9000"}
|
||||
{
|
||||
"value": "576",
|
||||
"label": "576"
|
||||
},
|
||||
{
|
||||
"value": "1280",
|
||||
"label": "1280"
|
||||
},
|
||||
{
|
||||
"value": "1492",
|
||||
"label": "1492"
|
||||
},
|
||||
{
|
||||
"value": "1500",
|
||||
"label": "1500"
|
||||
},
|
||||
{
|
||||
"value": "4096",
|
||||
"label": "4096"
|
||||
},
|
||||
{
|
||||
"value": "9000",
|
||||
"label": "9000"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -623,7 +697,7 @@
|
|||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/apply_general",
|
||||
"action": "/action/general_cardlogging_save",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
|
|
@ -651,22 +725,13 @@
|
|||
"value": "%GENERAL_DNSMASQ_LOG_QUERIES%",
|
||||
"hint": "Log every DNS query. High volume \u2014 enable for debugging only."
|
||||
},
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Daily Task Time",
|
||||
"name": "daily_execute_time_24hr_local",
|
||||
"input_type": "text",
|
||||
"value": "%GENERAL_DAILY_EXECUTE_TIME%",
|
||||
"placeholder": "e.g. 02:30",
|
||||
"hint": "24-hour local time for the daily blocklist refresh timer."
|
||||
},
|
||||
{
|
||||
"type": "button_row",
|
||||
"items": [
|
||||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/apply_general",
|
||||
"action": "/action/general_cardlogging_save",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
|
|
@ -682,12 +747,12 @@
|
|||
},
|
||||
{
|
||||
"type": "card",
|
||||
"label": "Configuration Changes",
|
||||
"label": "Pending Changes",
|
||||
"client_requirement": "client_is_administrator+",
|
||||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/apply_general",
|
||||
"action": "/action/general_cardpendingchanges_save",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
|
|
@ -704,7 +769,7 @@
|
|||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/apply_general",
|
||||
"action": "/action/general_cardpendingchanges_save",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
|
|
@ -723,81 +788,6 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "view_upstream_dns",
|
||||
"client_requirement": "client_is_viewer+",
|
||||
"items": [
|
||||
{
|
||||
"type": "page_header",
|
||||
"items": [
|
||||
{
|
||||
"type": "h1",
|
||||
"text": "Upstream DNS"
|
||||
},
|
||||
{
|
||||
"type": "p",
|
||||
"text": "Upstream resolvers and caching behaviour for dnsmasq."
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "card",
|
||||
"label": "Upstream DNS Settings",
|
||||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/apply_upstream_dns",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Strict Order",
|
||||
"name": "strict_order",
|
||||
"input_type": "checkbox",
|
||||
"value": "%DNS_STRICT_ORDER%",
|
||||
"hint": "Query DNS providers in list order rather than in parallel."
|
||||
},
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Cache Size",
|
||||
"name": "cache_size",
|
||||
"input_type": "number",
|
||||
"value": "%DNS_CACHE_SIZE%",
|
||||
"min": 0,
|
||||
"hint": "Max DNS responses to cache per instance. Set to 0 to disable caching."
|
||||
},
|
||||
{
|
||||
"type": "editable_list",
|
||||
"label": "DNS Providers",
|
||||
"name": "upstream_servers",
|
||||
"items": "%DNS_UPSTREAM_SERVERS_JSON%",
|
||||
"item_placeholder": "e.g. 1.1.1.1",
|
||||
"add_label": "Add Provider",
|
||||
"validate": "ip",
|
||||
"hint": "DNS resolvers queried for external hostnames. Supports IPv4 and IPv6."
|
||||
},
|
||||
{
|
||||
"type": "button_row",
|
||||
"items": [
|
||||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/apply_upstream_dns",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
"type": "button_cancel",
|
||||
"text": "Cancel"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"client_requirement": "client_is_administrator+"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "view_banned_ips",
|
||||
"client_requirement": "client_is_viewer+",
|
||||
|
|
@ -1053,7 +1043,7 @@
|
|||
]
|
||||
},
|
||||
{
|
||||
"id": "view_blocklists",
|
||||
"id": "view_dns_server",
|
||||
"client_requirement": "client_is_viewer+",
|
||||
"items": [
|
||||
{
|
||||
|
|
@ -1061,11 +1051,11 @@
|
|||
"items": [
|
||||
{
|
||||
"type": "h1",
|
||||
"text": "DNS Blocklists"
|
||||
"text": "DNS Server"
|
||||
},
|
||||
{
|
||||
"type": "p",
|
||||
"text": "Upstream blocklist sources downloaded and merged by the daily systemd timer."
|
||||
"text": "Blocklist sources and DNS server settings."
|
||||
}
|
||||
]
|
||||
},
|
||||
|
|
@ -1093,22 +1083,11 @@
|
|||
"class": "col-mono"
|
||||
}
|
||||
],
|
||||
"toolbar": {
|
||||
"items": [
|
||||
{
|
||||
"type": "button_secondary",
|
||||
"text": "Refresh All Now",
|
||||
"action": "/action/update_blocklists",
|
||||
"method": "post",
|
||||
"client_requirement": "client_is_administrator+"
|
||||
}
|
||||
]
|
||||
},
|
||||
"row_actions": [
|
||||
{
|
||||
"text": "Edit",
|
||||
"class": "btn-ghost btn-sm",
|
||||
"action": "/action/edit_blocklist",
|
||||
"action": "/action/dnsserver_tableblocklist_rowedit",
|
||||
"method": "inline_edit",
|
||||
"client_requirement": "client_is_administrator+",
|
||||
"fields": [
|
||||
|
|
@ -1136,7 +1115,7 @@
|
|||
{
|
||||
"text": "Delete",
|
||||
"class": "btn-danger btn-sm",
|
||||
"action": "/action/delete_blocklist",
|
||||
"action": "/action/dnsserver_tableblocklists_rowdelete",
|
||||
"method": "post",
|
||||
"client_requirement": "client_is_administrator+"
|
||||
}
|
||||
|
|
@ -1150,7 +1129,7 @@
|
|||
"items": [
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/add_blocklist",
|
||||
"action": "/action/dnsserver_cardaddblocklist_add",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
|
|
@ -1189,7 +1168,60 @@
|
|||
{
|
||||
"type": "button_primary",
|
||||
"text": "Add Blocklist",
|
||||
"action": "/action/add_blocklist",
|
||||
"action": "/action/dnsserver_cardaddblocklist_add",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
"type": "button_cancel",
|
||||
"text": "Cancel"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "card",
|
||||
"label": "Blocklist Refresh",
|
||||
"client_requirement": "client_is_administrator+",
|
||||
"items": [
|
||||
{
|
||||
"type": "raw_html",
|
||||
"html": "%BLOCKLIST_STATS_HTML%"
|
||||
},
|
||||
{
|
||||
"type": "button_row",
|
||||
"items": [
|
||||
{
|
||||
"type": "button_secondary",
|
||||
"text": "Refresh All Now",
|
||||
"action": "/action/dnsserver_cardblocklistrefresh_refresh",
|
||||
"method": "post"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "form",
|
||||
"action": "/action/dnsserver_cardblocklistrefresh_save",
|
||||
"method": "post",
|
||||
"items": [
|
||||
{
|
||||
"type": "field",
|
||||
"label": "Daily Task Time",
|
||||
"name": "daily_execute_time_24hr_local",
|
||||
"input_type": "text",
|
||||
"value": "%GENERAL_DAILY_EXECUTE_TIME%",
|
||||
"placeholder": "e.g. 02:30",
|
||||
"hint": "24-hour local time for the daily blocklist refresh."
|
||||
},
|
||||
{
|
||||
"type": "button_row",
|
||||
"items": [
|
||||
{
|
||||
"type": "button_primary",
|
||||
"text": "Save",
|
||||
"action": "/action/dnsserver_cardblocklistrefresh_save",
|
||||
"method": "post"
|
||||
},
|
||||
{
|
||||
|
|
@ -2738,4 +2770,4 @@
|
|||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue