Configuration of nfs |
routines.ycp |
Network NFS routines | |
|
Network NFS routines
Imports
Local Functions |
local
SpecToServPath (string spec)
->
term
- Parameters:
-
spec "server:/path/specification"
- Return value:
-
`couple("server", "/path/specification")
local
FstabTableItems (list<map> fstab)
->
list<term>
Creates a list of ui table items for nfs fstab entries
- Parameters:
-
fstab list of nfs fstab entries
- Return value:
-
itemized table entries
- Example
-
UI::ChangeWidget(`id(`fstable), `Items, FstabTableItems(nfs_entries));
local
CheckHostName (string name)
->
boolean
Check for the validity of a hostname: nonempty, shorter than 50 chars, [-A-Za-z._]. If invalid, a message is displayed.
- Parameters:
-
name a hostname
- Return value:
-
whether valid
local
IsMpInFstab (list<map> fstab, string mpoint)
->
boolean
Check if a mountpoint is in the fstab. If yes, display a message.
- Parameters:
-
fstab in .etc.fstab format (must contain the key "file") mpoint mount point
- Return value:
-
is it there?
local
CheckPath (string name)
->
boolean
Check for the validity of a path/mountpoint: nonempty, fewer than 70 chars, starts with a slash. If invalid, a message is displayed.
- Parameters:
-
name path
- Return value:
-
whether valid
local
check_options (string options)
->
string
Checks the nfs options for /etc/fstab: nonempty, comma separated list of foo,nofoo,bar=baz (see nfs(5))
- Parameters:
-
options options
- Return value:
-
a translated string with error message, emtpy string if ok
local
StripExtraSlash (string p)
->
string
Strips a superfluous slash off the end of a pathname.
- Parameters:
-
p pathname
- Return value:
-
stripped pathname
local
IsPortmapInstalled ()
->
boolean
Check whether pormap is installed, ask user to install it if it is missing
- Return value:
-
true if portmap is installed