Documentation ¶
Index ¶
- Constants
- func ExcludeIgnored(directory string) ([]string, error)
- func InjectDockerfile(contextPath string, dockerfilePath string) error
- func TarBuildContext(source string) error
- type AliyunOSSBuildContextReader
- type AzureBlobBuildContextReader
- type BuildContextReader
- func GetBuildContextReader(buildContext *v1alpha1.BuildContext, k8sConfigPath string) (BuildContextReader, error)
- func NewGCSBuildContextReader(buildContext *v1alpha1.GCSContext, k8sClient kubernetes.Interface) BuildContextReader
- func NewS3BuildContextReader(buildContext *v1alpha1.S3Context, k8sClient kubernetes.Interface) BuildContextReader
- type GCSBuildContextReader
- type GitBuildContextReader
- type LocalBuildContextReader
- type S3BuildContextReader
Constants ¶
const ( // DefaultRemote is the default remote DefaultRemote = "origin" // DefaultBranch is the default branch DefaultBranch = "master" )
Variables ¶
This section is empty.
Functions ¶
func ExcludeIgnored ¶
ExcludeIgnored excludes any explicitly ignored files or directories from the build context
func InjectDockerfile ¶
InjectDockerfile embeds the generated ocibuilder dockerfile into your build context tar looking in /ocib/context/context.tar.gz
func TarBuildContext ¶
TarBuildContext tars a build context and places the context back in /ocib/context directory
Types ¶
type AliyunOSSBuildContextReader ¶
type AliyunOSSBuildContextReader struct {
// contains filtered or unexported fields
}
AliyunOSSBuildContextReader implements BuildContextReader to fetch build context stored on Aliyun OSS
func NewAliyunOSSBuildContextReader ¶
func NewAliyunOSSBuildContextReader(buildContext *v1alpha1.AliyunOSSContext, k8sClient kubernetes.Interface) *AliyunOSSBuildContextReader
NewAliyunOSSBuildContextReader returns a new Aliyun OSS build context reader
func (*AliyunOSSBuildContextReader) Read ¶
func (contextReader *AliyunOSSBuildContextReader) Read() (string, error)
Read reads and stores build context from OSS
type AzureBlobBuildContextReader ¶
type AzureBlobBuildContextReader struct {
// contains filtered or unexported fields
}
AzureBlobBuildContextReader implements BuildContextReader for the context stored on Azure Storage Blob
func NewAzureBlobBuildContextReader ¶
func NewAzureBlobBuildContextReader(buildContext *v1alpha1.AzureBlobContext, k8sClient kubernetes.Interface) *AzureBlobBuildContextReader
NewAzureBlobBuildContextReader returns a new build context reader for Azure Storage Blob
func (*AzureBlobBuildContextReader) Read ¶
func (contextReader *AzureBlobBuildContextReader) Read() (string, error)
Read reads the build context from Azure Storage Blob and stores it at a preconfigured path
type BuildContextReader ¶
BuildContextReader enables reading build context from a store
func GetBuildContextReader ¶
func GetBuildContextReader(buildContext *v1alpha1.BuildContext, k8sConfigPath string) (BuildContextReader, error)
GetBuildContextReader returns a build context based on the store
func NewGCSBuildContextReader ¶
func NewGCSBuildContextReader(buildContext *v1alpha1.GCSContext, k8sClient kubernetes.Interface) BuildContextReader
NewGCSBuildContextReader returns a new build context reader for GCS
func NewS3BuildContextReader ¶
func NewS3BuildContextReader(buildContext *v1alpha1.S3Context, k8sClient kubernetes.Interface) BuildContextReader
NewS3BuildContextReader returns a new build context reader for S3
type GCSBuildContextReader ¶
type GCSBuildContextReader struct {
// contains filtered or unexported fields
}
GCSBuildContextReader implements the BuildContextReader to read build context from Google Cloud Storage
func (*GCSBuildContextReader) Read ¶
func (contextReader *GCSBuildContextReader) Read() (string, error)
Read reads the build context from GCS
type GitBuildContextReader ¶
type GitBuildContextReader struct {
// contains filtered or unexported fields
}
GitBuildContextReader is the context reader for pulling context from git
func NewGitBuildContextReader ¶
func NewGitBuildContextReader(buildContext *v1alpha1.GitContext, k8sClient kubernetes.Interface) *GitBuildContextReader
NewGitBuildContextReader returns a build context stored on the git
func (*GitBuildContextReader) Read ¶
func (contextReader *GitBuildContextReader) Read() (string, error)
type LocalBuildContextReader ¶
type LocalBuildContextReader struct {
// contains filtered or unexported fields
}
LocalBuildContextReader implements BuildContextReader for local build contexts
func NewLocalBuildContextReader ¶
func NewLocalBuildContextReader(buildContext *v1alpha1.LocalContext) *LocalBuildContextReader
NewLocalBuildContextReader returns a local build context reader
func (*LocalBuildContextReader) Read ¶
func (contextReader *LocalBuildContextReader) Read() (string, error)
Read reads the build context from the local
type S3BuildContextReader ¶
type S3BuildContextReader struct {
// contains filtered or unexported fields
}
S3BuildContextReader implements the context reader for the S3 storage
func (*S3BuildContextReader) Read ¶
func (contextReader *S3BuildContextReader) Read() (string, error)
Read reads the context stored on S3BuildContextReader