func (d *driver) configure() error { if d.store == nil { return types.NoServiceErrorf("datastore is not available") } if d.vxlanIdm == nil { return d.initializeVxlanIdm() } return nil }
} /************** * IPAM Errors **************/ // Well-known errors returned by IPAM var ( ErrIpamInternalError = types.InternalErrorf("IPAM Internal Error") ErrInvalidAddressSpace = types.BadRequestErrorf("Invalid Address Space") ErrInvalidPool = types.BadRequestErrorf("Invalid Address Pool") ErrInvalidSubPool = types.BadRequestErrorf("Invalid Address SubPool") ErrInvalidRequest = types.BadRequestErrorf("Invalid Request") ErrPoolNotFound = types.BadRequestErrorf("Address Pool not found") ErrOverlapPool = types.ForbiddenErrorf("Address pool overlaps with existing pool on this address space") ErrNoAvailablePool = types.NoServiceErrorf("No available pool") ErrNoAvailableIPs = types.NoServiceErrorf("No available addresses on this pool") ErrNoIPReturned = types.NoServiceErrorf("No address returned") ErrIPAlreadyAllocated = types.ForbiddenErrorf("Address already in use") ErrIPOutOfRange = types.BadRequestErrorf("Requested address is out of range") ErrPoolOverlap = types.ForbiddenErrorf("Pool overlaps with other one on this address space") ErrBadPool = types.BadRequestErrorf("Address space does not contain specified address pool") ) /******************************* * IPAM Service Interface *******************************/ // Ipam represents the interface the IPAM service plugins must implement // in order to allow injection/modification of IPAM database. type Ipam interface {