Documentation ¶
Index ¶
- type BuildContextSource
- type GCSBucket
- func (g *GCSBucket) Cleanup(ctx context.Context, cfg *latest.KanikoBuild) error
- func (g *GCSBucket) ModifyPod(p *v1.Pod) error
- func (g *GCSBucket) Pod(cfg *latest.KanikoBuild, args []string) *v1.Pod
- func (g *GCSBucket) Setup(ctx context.Context, artifact *latest.Artifact, cfg *latest.KanikoBuild, ...) (string, error)
- type LocalDir
- func (g *LocalDir) Cleanup(ctx context.Context, cfg *latest.KanikoBuild) error
- func (g *LocalDir) ModifyPod(p *v1.Pod) error
- func (g *LocalDir) Pod(cfg *latest.KanikoBuild, args []string) *v1.Pod
- func (g *LocalDir) Setup(ctx context.Context, artifact *latest.Artifact, cfg *latest.KanikoBuild, ...) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildContextSource ¶
type BuildContextSource interface { Setup(ctx context.Context, artifact *latest.Artifact, cfg *latest.KanikoBuild, initialTag string) (string, error) Pod(cfg *latest.KanikoBuild, args []string) *v1.Pod ModifyPod(p *v1.Pod) error Cleanup(ctx context.Context, cfg *latest.KanikoBuild) error }
BuildContextSource is the generic type for the different build context sources the kaniko builder can use
func Retrieve ¶
func Retrieve(cfg *latest.KanikoBuild) (BuildContextSource, error)
Retrieve returns the correct build context based on the config
type GCSBucket ¶
type GCSBucket struct {
// contains filtered or unexported fields
}
func (*GCSBucket) ModifyPod ¶
ModifyPod does nothing here, since we just need to let kaniko run to completion
type LocalDir ¶
type LocalDir struct {
// contains filtered or unexported fields
}
LocalDir refers to kaniko using a local directory as a buildcontext skaffold copies the buildcontext into the local directory via kubectl cp
func (*LocalDir) ModifyPod ¶
ModifyPod first copies over the buildcontext tarball into the init container tmp dir via kubectl cp Via kubectl exec, we extract the tarball to the empty dir Then, via kubectl exec, create the /tmp/complete file via kubectl exec to complete the init container