From 2fb09eb0dee06e74f94b6def6493066214c5f4a9 Mon Sep 17 00:00:00 2001 From: Mika Havela Date: Thu, 4 Sep 2008 15:13:00 +0000 Subject: Split Bgp and Zebra into separate controllers. Earlier there was no chance to start/stop zebra (only bgp) and the whole package was a strange mix of bgp and zebra. Now these processes has own Menuitems and are controlled separately (they both exist in acf-quagga though). git-svn-id: svn://svn.alpinelinux.org/acf/quagga/trunk@1447 ab2d0c66-481e-0410-8bed-d214d4d58bed --- zebra-model.lua | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 zebra-model.lua (limited to 'zebra-model.lua') diff --git a/zebra-model.lua b/zebra-model.lua new file mode 100644 index 0000000..12d62b9 --- /dev/null +++ b/zebra-model.lua @@ -0,0 +1,32 @@ +module(..., package.seeall) + +-- Load libraries +require("modelfunctions") + +-- Set variables +local path="PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin " + +local configfile = "/etc/quagga/zebra.conf" +local processname = "zebra" +local packagename = "quagga" + +-- ################################################################################ +-- PUBLIC FUNCTIONS + +function startstop_service(action) + return modelfunctions.startstop_service(processname, action) +end + +function getstatus() + return modelfunctions.getstatus(processname, packagename, "Zebra Status") +end + +function getconfigfile() + return modelfunctions.getfiledetails(configfile) +end + +function setconfigfile(filedetails) + filedetails.value.filename.value = configfile + return modelfunctions.setfiledetails(filedetails) +end + -- cgit v1.2.3