summaryrefslogtreecommitdiffstats
path: root/tinydns-controller.lua
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2009-12-25 08:52:50 +0000
committerTed Trask <ttrask01@yahoo.com>2009-12-25 08:52:50 +0000
commit0be9cc50c885abe6a85bc398d999ab6cda2eb44a (patch)
tree3125a94294765b3c3772cc44220e9076848f49eb /tinydns-controller.lua
parent3fc2855614b96451c99acd40e5083e5c8396dbb9 (diff)
downloadacf-tinydns-0be9cc50c885abe6a85bc398d999ab6cda2eb44a.tar.bz2
acf-tinydns-0be9cc50c885abe6a85bc398d999ab6cda2eb44a.tar.xz
Change processname to match prefix - this allows multiple instances without editing.
Diffstat (limited to 'tinydns-controller.lua')
-rw-r--r--tinydns-controller.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/tinydns-controller.lua b/tinydns-controller.lua
index 0461ed9..64a224c 100644
--- a/tinydns-controller.lua
+++ b/tinydns-controller.lua
@@ -2,6 +2,11 @@ module(..., package.seeall)
require("controllerfunctions")
require("validator")
+mvc = {}
+mvc.on_load = function(self, parent)
+ self.model.set_processname(string.match(self.conf.prefix, "[^/]+"))
+end
+
default_action = "status"
function status(self)