Documentation
¶
Index ¶
Constants ¶
View Source
const ( // StatusUnknown "STATUS_UNKNOWN" - Status of the build is unknown. StatusUnknown = "STATUS_UNKNOWN" // StatusQueued "QUEUED" - Build is queued; work has not yet begun. StatusQueued = "QUEUED" // StatusWorking "WORKING" - Build is being executed. StatusWorking = "WORKING" // StatusSuccess "SUCCESS" - Build finished successfully. StatusSuccess = "SUCCESS" // StatusFailure "FAILURE" - Build failed to complete successfully. StatusFailure = "FAILURE" // StatusInternalError "INTERNAL_ERROR" - Build failed due to an internal cause. StatusInternalError = "INTERNAL_ERROR" // StatusTimeout "TIMEOUT" - Build took longer than was allowed. StatusTimeout = "TIMEOUT" // StatusCancelled "CANCELLED" - Build was canceled by a user. StatusCancelled = "CANCELLED" // RetryDelay is the time to wait in between polling the status of the cloud build RetryDelay = 1 * time.Second )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Build ¶
type Build struct { ImageName string Tag string Artifact *config.Artifact // The artifact used in the build. }
Build is the result corresponding to each Artifact built.
type BuildResult ¶
type BuildResult struct {
Builds []Build
}
BuildResult holds the results of builds
type Builder ¶
type Builder interface {
Build(ctx context.Context, out io.Writer, tagger tag.Tagger, artifacts []*config.Artifact) (*BuildResult, error)
}
Builder is an interface to the Build API of Skaffold. It must build and make the resulting image accesible to the cluster. This could include pushing to a authorized repository or loading the nodes with the image. If artifacts is supplied, the builder should only rebuild those artifacts.
type GoogleCloudBuilder ¶
type GoogleCloudBuilder struct {
*config.BuildConfig
}
func NewGoogleCloudBuilder ¶
func NewGoogleCloudBuilder(cfg *config.BuildConfig) (*GoogleCloudBuilder, error)
type LocalBuilder ¶
type LocalBuilder struct { *config.BuildConfig // contains filtered or unexported fields }
LocalBuilder uses the host docker daemon to build and tag the image
func NewLocalBuilder ¶
func NewLocalBuilder(cfg *config.BuildConfig, kubeContext string) (*LocalBuilder, error)
NewLocalBuilder returns an new instance of a LocalBuilder
func (*LocalBuilder) Build ¶ added in v0.3.0
func (l *LocalBuilder) Build(ctx context.Context, out io.Writer, tagger tag.Tagger, artifacts []*config.Artifact) (*BuildResult, error)
Build runs a docker build on the host and tags the resulting image with its checksum. It streams build progress to the writer argument.
Click to show internal directories.
Click to hide internal directories.