github.com/raghuse92/packer@v1.3.2/builder/oracle/oci/driver.go (about)

     1  package oci
     2  
     3  import (
     4  	"context"
     5  
     6  	"github.com/oracle/oci-go-sdk/core"
     7  )
     8  
     9  // Driver interfaces between the builder steps and the OCI SDK.
    10  type Driver interface {
    11  	CreateInstance(ctx context.Context, publicKey string) (string, error)
    12  	CreateImage(ctx context.Context, id string) (core.Image, error)
    13  	DeleteImage(ctx context.Context, id string) error
    14  	GetInstanceIP(ctx context.Context, id string) (string, error)
    15  	TerminateInstance(ctx context.Context, id string) error
    16  	WaitForImageCreation(ctx context.Context, id string) error
    17  	WaitForInstanceState(ctx context.Context, id string, waitStates []string, terminalState string) error
    18  }