Detect cancelled allocation more cleanly
to avoid the weave script trying to parse an error message as a CIDR
This commit is contained in:
1 parent
1beaf79e47
commit
98b80c59d9
5 files changed
+26
-4
No files matched your search
@@ -184,6 +184,15 @@ func hasBeenCancelled(cancelChan <-chan bool) func() bool {
|
||||
}
|
||||
}
|
||||
|
||||
type errorCancelled struct {
|
||||
kind string
|
||||
ident string
|
||||
}
|
||||
|
||||
func (e *errorCancelled) Error() string {
|
||||
return fmt.Sprintf("%s request for %s cancelled", e.kind, e.ident)
|
||||
}
|
||||
|
||||
// Actor client API
|
||||
|
||||
// Allocate (Sync) - get new IP address for container with given name in range
|
||||
|
||||
Reference in new issue
Block a user