The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/3735

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===

From d075d9f35cac33ba1a44b2a3163b1efa0c272125 Mon Sep 17 00:00:00 2001
From: jav <[email protected]>
Date: Mon, 28 Aug 2017 11:40:47 +0200
Subject: [PATCH 1/2] LXD Network ovs bridge - Error with interfaces ipv6
 link-local - except just link-local #3727

---
 lxd/networks.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lxd/networks.go b/lxd/networks.go
index de0b7d840..25890c7ef 100644
--- a/lxd/networks.go
+++ b/lxd/networks.go
@@ -666,7 +666,7 @@ func (n *network) Start() error {
                        }
 
                        addrs, err := iface.Addrs()
-                       if err == nil && len(addrs) != 0 {
+                       if err == nil && len(addrs) > 1 {
                                return fmt.Errorf("Only unconfigured network 
interfaces can be bridged")
                        }
 

From 40a487a52dea410fba44318efc91523e92a3aa3f Mon Sep 17 00:00:00 2001
From: jav <[email protected]>
Date: Tue, 29 Aug 2017 12:05:04 +0200
Subject: [PATCH 2/2] LXD Network ovs bridge - Error with interfaces ipv6
 link-local - except just link-local  #3727

---
 lxd/networks.go | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lxd/networks.go b/lxd/networks.go
index 25890c7ef..dd13fcd56 100644
--- a/lxd/networks.go
+++ b/lxd/networks.go
@@ -11,6 +11,7 @@ import (
        "os/exec"
        "strconv"
        "strings"
+       "ipaddress"
 
        "github.com/gorilla/mux"
        log "gopkg.in/inconshreveable/log15.v2"
@@ -670,6 +671,10 @@ func (n *network) Start() error {
                                return fmt.Errorf("Only unconfigured network 
interfaces can be bridged")
                        }
 
+                       if ipaddress.ip_address(addrs[0]).is_link_local is 
false {
+                               return fmt.Errorf("Only interfaces with just 
one link-local address can  be bridged")
+                       }
+
                        err = networkAttachInterface(n.name, entry)
                        if err != nil {
                                return err
_______________________________________________
lxc-devel mailing list
[email protected]
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to