2015-12-17 19:17:50 -05:00
|
|
|
package build
|
|
|
|
|
2016-01-20 18:32:02 -05:00
|
|
|
import (
|
2016-03-29 18:51:14 -04:00
|
|
|
"github.com/docker/docker/api/types/backend"
|
2016-03-18 17:42:40 -04:00
|
|
|
"golang.org/x/net/context"
|
2016-01-20 18:32:02 -05:00
|
|
|
)
|
|
|
|
|
2015-12-17 19:17:50 -05:00
|
|
|
// Backend abstracts an image builder whose only purpose is to build an image referenced by an imageID.
|
|
|
|
type Backend interface {
|
2017-04-13 14:37:32 -04:00
|
|
|
// Build a Docker image returning the id of the image
|
2015-12-17 19:17:50 -05:00
|
|
|
// TODO: make this return a reference instead of string
|
2017-04-13 14:37:32 -04:00
|
|
|
Build(context.Context, backend.BuildConfig) (string, error)
|
|
|
|
}
|
|
|
|
|
|
|
|
type experimentalProvider interface {
|
|
|
|
HasExperimental() bool
|
2015-12-17 19:17:50 -05:00
|
|
|
}
|