1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Vendoring @ab62dd6bf06bf0

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
(cherry picked from commit 663159e9ac)
This commit is contained in:
Jana Radhakrishnan 2016-06-18 19:16:51 -07:00 committed by Tibor Vass
parent fe2a9bea38
commit 2b45db42b2
3 changed files with 17 additions and 3 deletions

View file

@ -65,7 +65,7 @@ clone git github.com/RackSec/srslog 259aed10dfa74ea2961eddd1d9847619f6e98837
clone git github.com/imdario/mergo 0.2.1
#get libnetwork packages
clone git github.com/docker/libnetwork 13be89d1cf79760acae842a32ad8531567220286
clone git github.com/docker/libnetwork ab62dd6bf06bf0637d66d529931b69a5544468cb
clone git github.com/docker/go-events 39718a26497694185f8fb58a7d6f31947f3dc42d
clone git github.com/armon/go-radix e39d623f12e8e41c7b5529e9a9dd67a1e2261f80
clone git github.com/armon/go-metrics eb0af217e5e9747e41dd5303755356b62d28e3ec

View file

@ -1099,14 +1099,22 @@ func (n *network) getSvcRecords(ep *endpoint) []etchosts.Record {
n.Lock()
defer n.Unlock()
if ep == nil {
return nil
}
var recs []etchosts.Record
sr, _ := n.ctrlr.svcRecords[n.id]
epName := ep.Name()
for h, ip := range sr.svcMap {
if ep != nil && strings.Split(h, ".")[0] == ep.Name() {
if strings.Split(h, ".")[0] == epName {
continue
}
if len(ip) == 0 {
log.Warnf("Found empty list of IP addresses for service %s on network %s (%s)", h, n.Name(), n.ID())
continue
}
recs = append(recs, etchosts.Record{
Hosts: h,
IP: ip[0].String(),

View file

@ -397,6 +397,12 @@ func (nDB *NetworkDB) bulkSyncNode(networks []string, node string, unsolicited b
return false
}
// Do not bulk sync state which is in the
// process of getting deleted.
if entry.deleting {
return false
}
params := strings.Split(path[1:], "/")
tEvent := TableEvent{
Type: TableEventTypeCreate,