diff options
author | Mika Havela <mika.havela@gmail.com> | 2008-02-13 18:36:50 +0000 |
---|---|---|
committer | Mika Havela <mika.havela@gmail.com> | 2008-02-13 18:36:50 +0000 |
commit | f1e2dd41fb3b71f2f0e5082cc057ad33a7c6a0d0 (patch) | |
tree | 04da9517df8ed481fe1aba1c3d432da310d07272 /tinydns-model.lua | |
parent | e3b7de100ac11887cb8abfa9336be995eda1520f (diff) | |
download | acf-tinydns-f1e2dd41fb3b71f2f0e5082cc057ad33a7c6a0d0.tar.bz2 acf-tinydns-f1e2dd41fb3b71f2f0e5082cc057ad33a7c6a0d0.tar.xz |
First view shows some basic information
git-svn-id: svn://svn.alpinelinux.org/acf/tinydns/trunk@717 ab2d0c66-481e-0410-8bed-d214d4d58bed
Diffstat (limited to 'tinydns-model.lua')
-rw-r--r-- | tinydns-model.lua | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/tinydns-model.lua b/tinydns-model.lua index 176da46..223ce44 100644 --- a/tinydns-model.lua +++ b/tinydns-model.lua @@ -11,7 +11,7 @@ local configfile = "???" local function get_version() local cmd = "/sbin/apk_version -vs " .. processname .." 2>/dev/null" local f = io.popen( cmd ) - local cmd_output_result = f:read("*l") + local cmd_output_result = string.match(f:read("*l"),"^%S*") or "Unknown" f:close() return cmd_output_result end @@ -20,7 +20,6 @@ end -- PUBLIC FUNCTIONS function getstatus() --- local opts = getconfig() local status = {} status.version = cfe({ name = "version", label="Program version", @@ -30,21 +29,6 @@ function getstatus() label="Program status", value=procps.pidof(processname), }) - ---[[ - if (opts["remotelogging"]) and not ((opts["remotelogging"]["value"] ~= "") and not (opts["localandnetworklog"]["value"])) then - status.logfile = cfe({ name="logfile", - label="Locally logging to", - value=opts["logfile"]["value"], - }) - end - if (opts["SYSLOGD_OPTS"]) and (opts["SYSLOGD_OPTS"]["-R"]) and (opts["SYSLOGD_OPTS"]["-R"] ~= "") then - status.remote = cfe({ name="remotelogging", - label="Remote logging to", - value=opts["SYSLOGD_OPTS"]["-R"], - }) - end ---]] return status end |