maybe works again
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
9ad173a845
commit
284e9161de
12
add.go
12
add.go
|
@ -77,7 +77,15 @@ func (c *NewCluster) AddHypervisor(hostname string, cpus int, mem int) *Hypervis
|
||||||
return h
|
return h
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *NewCluster) AddDroplet(uuid string, hostname string, cpus int, mem int) *Droplet {
|
func (c *NewCluster) AddEvent(e *Event) {
|
||||||
|
c.e.Events = append(c.e.Events, e)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *NewCluster) AddDroplet(d *Droplet) {
|
||||||
|
c.d.Droplets = append(c.d.Droplets, d)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *NewCluster) AddDropletSimple(uuid string, hostname string, cpus int, mem int) *Droplet {
|
||||||
d := c.FindDropletByName(hostname)
|
d := c.FindDropletByName(hostname)
|
||||||
if d != nil {
|
if d != nil {
|
||||||
return d
|
return d
|
||||||
|
@ -93,7 +101,7 @@ func (c *NewCluster) AddDroplet(uuid string, hostname string, cpus int, mem int)
|
||||||
d.Cpus = 1
|
d.Cpus = 1
|
||||||
}
|
}
|
||||||
d.Memory = SetGB(mem * 32)
|
d.Memory = SetGB(mem * 32)
|
||||||
c.d.Droplets = append(c.d.Droplets, d)
|
c.AddDroplet(d)
|
||||||
return d
|
return d
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue