Documentation ¶
Index ¶
- Variables
- type Instance
- func (bi *Instance) Build() error
- func (bi *Instance) CheckReleaseBucket() error
- func (bi *Instance) CopyStagedFromGCS(stagedBucket, buildVersion string) error
- func (bi *Instance) DeleteLocalSourceTarball(workDir string) error
- func (bi *Instance) Push() error
- func (bi *Instance) PushContainerImages() error
- func (bi *Instance) PushReleaseArtifacts(srcPath, gcsPath string) error
- func (bi *Instance) StageLocalArtifacts() error
- func (bi *Instance) StageLocalSourceTree(workDir, buildVersion string) error
- type Make
- type Options
Constants ¶
This section is empty.
Variables ¶
var DefaultExtraVersionMarkers = []string{}
var ExtraGcpStageFiles = []stageFile{ { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, }
ExtraGcpStageFiles defines extra GCP files to be staged if `StageExtraFiles` in `Options` is set to `true`.
var ExtraWindowsStageFiles = []stageFile{ { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, { // contains filtered or unexported fields }, }
ExtraWindowsStageFiles defines extra Windows files to be staged if `StageExtraFiles` in `Options` is set to `true`.
Functions ¶
This section is empty.
Types ¶
type Instance ¶
type Instance struct {
// contains filtered or unexported fields
}
Instance is the main structure for creating and pushing builds.
func NewInstance ¶
NewInstance can be used to create a new build `Instance`. TODO: Prefer functional options here instead.
func (*Instance) Build ¶
Build starts a Kubernetes build with the options defined in the build `Instance`.
func (*Instance) CheckReleaseBucket ¶
CheckReleaseBucket verifies that a release bucket exists and the current authenticated GCP user has write permissions to it.
func (*Instance) CopyStagedFromGCS ¶
CopyStagedFromGCS copies artifacts from GCS and between buckets as needed. TODO: Investigate if it's worthwhile to use any of the bi.objStore.Get*Path()
functions here or create a new one to populate staging paths
func (*Instance) DeleteLocalSourceTarball ¶ added in v0.12.0
DeleteLocalSourceTarball the deletion of the tarball is now decoupled from StageLocalSourceTree to be able to use it during the anago.stage function.
func (*Instance) PushContainerImages ¶
PushContainerImages will publish container images into the set `Registry`. It also validates if the remove manifests are correct, which can be turned of by setting `ValidateRemoteImageDigests` to `false`.
func (*Instance) PushReleaseArtifacts ¶
PushReleaseArtifacts can be used to push local artifacts from the `srcPath` to the remote `gcsPath`. The Bucket has to be set via the `Bucket` option.
func (*Instance) StageLocalArtifacts ¶
StageLocalArtifacts locally stages the release artifacts.
func (*Instance) StageLocalSourceTree ¶
StageLocalSourceTree creates a src.tar.gz from the Kubernetes sources and uploads it to GCS.
type Make ¶
type Make struct {
// contains filtered or unexported fields
}
Make is the main structure for building Kubernetes releases.
type Options ¶
type Options struct { // Specify an alternate bucket for pushes (normally 'devel' or 'ci'). Bucket string // Specify an alternate build directory (relative to RepoRoot). Will be automatically determined // if not set. BuildDir string // Used to make determinations on where to push artifacts // Can be overridden using `GCSRoot`. // // May be one of: 'devel', 'ci', 'release' BuildType string // If set, push docker images to specified registry/project. Registry string // Absolute path to the kubernetes repository root directory // defaults to current working directory RepoRoot string // Comma separated list which can be used to upload additional version // files to GCS. The path is relative and is append to a GCS path. (--ci // only). ExtraVersionMarkers []string // The top-level GCS directory builds will be released to. // If specified, it will override BuildType. // // When unset: // - BuildType: "ci" // - final path: gs://<bucket>/ci // // When set: // - BuildType: "ci" // - GCSRoot: "new-root" // - final path: gs://<bucket>/new-root // // This option exists to handle the now-deprecated GCSSuffix option, which // was not plumbed through GCSRoot string // Version to be used. Usually automatically discovered, but it can be // used to overwrite this behavior. Version string // Append suffix to version name if set. VersionSuffix string // Used to configure options for CI builds. CI bool // Configure docker client for gcr.io authentication to allow communication // with non-public registries. ConfigureDocker bool // Specifies a fast build. Fast bool // Do not exit error if the build already exists on the GCS path. AllowDup bool // Do not update the latest file. NoUpdateLatest bool // Do not mark published bits on GCS as publicly readable. PrivateBucket bool // Validate that the remote image digests exists. ValidateRemoteImageDigests bool // Stage additional files defined by `ExtraGcpStageFiles` and // `ExtraWindowsStageFiles`, otherwise they will be skipped. StageExtraFiles bool // This sets the KUBE_BUILD_PLATFORMS value for make release/quick-release commands KubeBuildPlatforms string }
Options are the main options to pass to `Instance`.