summaryrefslogtreecommitdiffstats
path: root/etc/inc/pkg-utils.inc
diff options
context:
space:
mode:
Diffstat (limited to 'etc/inc/pkg-utils.inc')
-rw-r--r--etc/inc/pkg-utils.inc15
1 files changed, 15 insertions, 0 deletions
diff --git a/etc/inc/pkg-utils.inc b/etc/inc/pkg-utils.inc
index 431d675..bf99a64 100644
--- a/etc/inc/pkg-utils.inc
+++ b/etc/inc/pkg-utils.inc
@@ -1348,4 +1348,19 @@ function stop_packages() {
}
}
+function get_pkg_interfaces_select_source($include_localhost=false) {
+ $interfaces = get_configured_interface_with_descr();
+ $ssifs = array();
+ foreach ($interfaces as $iface => $ifacename) {
+ $tmp["name"] = $ifacename;
+ $tmp["value"] = $iface;
+ $ssifs[] = $tmp;
+ }
+ if ($include_localhost) {
+ $tmp["name"] = "Localhost";
+ $tmp["value"] = "lo0";
+ $ssifs[] = $tmp;
+ }
+ return $ssifs;
+}
?> \ No newline at end of file
OpenPOWER on IntegriCloud