6e35afcb3aac90e8129a3e89952148fa4a4a8fff
[project/luci.git] / applications / luci-statistics / src / model / cbi / admin_statistics / df.lua
1 --[[
2
3 Luci configuration model for statistics - collectd df plugin configuration
4 (c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
5
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12 $Id$
13
14 ]]--
15
16 m = Map("luci_statistics", "DF Plugin",
17 [[Das DF-Plugin sammelt Informationen über den belegten und verfügbaren Speicherplatz auf den
18 angegebenen Geräten, Mountpunkten oder Dateisystemtypen.]])
19
20 -- collectd_df config section
21 s = m:section( NamedSection, "collectd_df", "luci_statistics", "Pluginkonfiguration" )
22
23 -- collectd_df.enable
24 enable = s:option( Flag, "enable", "Plugin aktivieren" )
25 enable.default = 0
26
27 -- collectd_df.devices (Device)
28 devices = s:option( Value, "Devices", "Gerätedateien", "Einträge mit Leerzeichen trennen" )
29 devices.default = "/dev/mtdblock/4"
30 devices.rmempty = true
31 devices:depends( "enable", 1 )
32
33 -- collectd_df.mountpoints (MountPoint)
34 mountpoints = s:option( Value, "MountPoints", "Mountpunkte", "Einträge mit Leerzeichen trennen" )
35 mountpoints.default = "/jffs"
36 mountpoints.rmempty = true
37 mountpoints:depends( "enable", 1 )
38
39 -- collectd_df.fstypes (FSType)
40 fstypes = s:option( Value, "FSTypes", "Dateisystemtypen", "Einträge mit Leerzeichen trennen" )
41 fstypes.default = "tmpfs"
42 fstypes.rmempty = true
43 fstypes:depends( "enable", 1 )
44
45 -- collectd_df.ignoreselected (IgnoreSelected)
46 ignoreselected = s:option( Flag, "IgnoreSelected", "Logik umkehren und alle Datenträger überwachen die nicht auf die obigen Kriterien zutreffen" )
47 ignoreselected.default = 0
48 ignoreselected:depends( "enable", 1 )
49
50 return m