2016-04-14 17:29:27 -07:00
|
|
|
package triton
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"time"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
type Driver interface {
|
2017-10-30 19:26:42 +02:00
|
|
|
GetImage(config Config) (string, error)
|
2016-04-14 17:29:27 -07:00
|
|
|
CreateImageFromMachine(machineId string, config Config) (string, error)
|
|
|
|
|
CreateMachine(config Config) (string, error)
|
|
|
|
|
DeleteImage(imageId string) error
|
|
|
|
|
DeleteMachine(machineId string) error
|
2017-04-26 12:07:45 -07:00
|
|
|
GetMachineIP(machineId string) (string, error)
|
2016-04-14 17:29:27 -07:00
|
|
|
StopMachine(machineId string) error
|
|
|
|
|
WaitForImageCreation(imageId string, timeout time.Duration) error
|
|
|
|
|
WaitForMachineDeletion(machineId string, timeout time.Duration) error
|
|
|
|
|
WaitForMachineState(machineId string, state string, timeout time.Duration) error
|
|
|
|
|
}
|