summaryrefslogtreecommitdiffstats
path: root/squid-model.lua
diff options
context:
space:
mode:
Diffstat (limited to 'squid-model.lua')
-rw-r--r--squid-model.lua22
1 files changed, 19 insertions, 3 deletions
diff --git a/squid-model.lua b/squid-model.lua
index 3b55d60..5806a0a 100644
--- a/squid-model.lua
+++ b/squid-model.lua
@@ -70,15 +70,31 @@ get_squid_version = function()
local retval = ""
local ptr = io.popen( "/usr/sbin/squid -v" )
- retval = ptr:read( "*l" )
- ptr:close()
- if retval == nil then
+ if ptr ~= nil then
+ retval = ptr:read( "*l" )
+ ptr:close()
+ else
retval = "Error - can't retrieve squid version"
end
return retval
end
+get_winbind_version = function()
+
+ local retval = ""
+
+ local ptr = io.popen( "/usr/sbin/winbindd -V" )
+ if ptr ~= nil then
+ retval = ptr:read( "*l" )
+ ptr:close()
+ else
+ retval = "Error - can't retrieve winbindd version"
+ end
+
+ return retval
+end
+
get_status_winbindd = function()
local retval = "stopped"