diff --git a/luasrc/model/cbi/whoogle.lua b/luasrc/model/cbi/whoogle.lua index 4edd549..c326a4c 100644 --- a/luasrc/model/cbi/whoogle.lua +++ b/luasrc/model/cbi/whoogle.lua @@ -11,7 +11,7 @@ m = taskd.docker_map("whoogle", "whoogle", "/usr/libexec/apps/whoogle/whoogle.sh translate("Whoogle is a free open-source self-hosted metasearch engine that allows you to search and get your Google results without ads, JavaScript trackers, or AMP links. It also ignores cookies, and does not perform any IP address tracking.") .. translate("Official website:") .. ' https://hub.docker.com/r/benbusby/whoogle-search/') -s = m:section(SimpleSection, translate("Service Status"), translate("whoogle status:")) +s = m:section(SimpleSection, translate("Service Status")) s:append(Template("whoogle/status")) s = m:section(TypedSection, "whoogle", translate("Setup"), translate("The following parameters will only take effect during installation or upgrade:")) diff --git a/luasrc/view/whoogle/status.htm b/luasrc/view/whoogle/status.htm index d55b3bc..be2ea29 100644 --- a/luasrc/view/whoogle/status.htm +++ b/luasrc/view/whoogle/status.htm @@ -1,16 +1,14 @@ <% local util = require "luci.util" local container_status = util.trim(util.exec("/usr/libexec/apps/whoogle/whoogle.sh status")) -local container_install = (string.len(container_status) > 0) -local container_running = container_status == "running" +local container_running = string.match(string.lower(container_status), "^up%W") -%>
-
<% if container_running then %> - + <% else %> - + <% end %>
@@ -24,8 +22,7 @@ if container_running then
- - +
-<% end %> +<% end %> \ No newline at end of file