base-files: add network_is_up()
SVN-Revision: 31978
This commit is contained in:
parent
c998280a7c
commit
c11151bc70
1 changed files with 6 additions and 0 deletions
|
@ -54,5 +54,11 @@ __network_device()
|
|||
json_get_var "$__var" "$__field"
|
||||
}
|
||||
|
||||
network_is_up()
|
||||
{
|
||||
local __up
|
||||
__network_device __up "$1" up && [ $__up -eq 1 ]
|
||||
}
|
||||
|
||||
network_get_device() { __network_device "$1" "$2" l3_device; }
|
||||
network_get_physdev() { __network_device "$1" "$2" device; }
|
||||
|
|
Loading…
Reference in a new issue