summaryrefslogtreecommitdiff
path: root/setup-interfaces.in
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2012-06-20 16:39:46 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2012-06-20 16:39:46 +0000
commit70dab89b61e1e6ad9ed8b96d3c948385d1b07f53 (patch)
tree430a84925c5c1086bfae7c32c31dec7bcd7e5d85 /setup-interfaces.in
parent625a07f49ca1699b6b4ad2257b7761c797b1e959 (diff)
downloadalpine-conf-70dab89b61e1e6ad9ed8b96d3c948385d1b07f53.zip
setup-interfaces: do not ask to bridge bridge interfaces
Diffstat (limited to 'setup-interfaces.in')
-rwxr-xr-xsetup-interfaces.in6
1 files changed, 5 insertions, 1 deletions
diff --git a/setup-interfaces.in b/setup-interfaces.in
index a99cc30..d8c7ff3 100755
--- a/setup-interfaces.in
+++ b/setup-interfaces.in
@@ -109,6 +109,10 @@ bridge_list_ports() {
fi
}
+is_bridge() {
+ test -r $1.bridge_ports
+}
+
config_iface() {
local iface=$1
local prefix=$2
@@ -117,7 +121,7 @@ config_iface() {
local conf=$prefix$iface.conf
local answer=
- while [ -n "$ask_bridge" ]; do
+ while [ -n "$ask_bridge" ] && ! is_bridge $iface; do
ask "Do you want to bridge the interface $iface?" no
case "$resp" in
yes|y) resp=yes; break;;