Documentation ¶
Index ¶
- func ComputeChecksum(data []byte) string
- func GetEnv(key string) string
- func Getenv(key string) string
- func ParseImageTag(imageTag string) (string, string)
- func SumChecksum(sums ...[]byte) string
- func TarDir(src fs.ReadDirFS) (*bytes.Buffer, error)
- type Build
- type BuildGroup
- type BuildGroups
- type BuildType
- type Container
- func (c *Container) Apply(opts *types.ContainerConfig)
- func (c *Container) BuildImage(dockerfile []byte, imageName string) error
- func (c *Container) BuildImageByPlatform(dockerfile []byte, imageName string, platform string) error
- func (c *Container) BuildImageByPlatforms(dockerfile []byte, dockerCtx *bytes.Buffer, imageName string, ...) ([]string, error)
- func (c *Container) BuildIntermidiateContainer(image string, dockerFile []byte, platforms ...string) error
- func (c *Container) BuildingContainer(opts types.ContainerConfig) error
- func (c *Container) Commit(imageTag string, comment string, changes ...string) (string, error)
- func (c *Container) CopyContentTo(content, dest string) error
- func (c *Container) CopyDirectoryTo(srcPath, dstPath string) error
- func (c *Container) CopyFileFromContainer(srcPath string) (string, error)
- func (c *Container) CopyFileTo(srcPath, destPath string) error
- func (c *Container) Create(opts types.ContainerConfig) error
- func (c *Container) Exec(cmd ...string) error
- func (c *Container) GetBuild() *Build
- func (c *Container) ImageExists(imageName string, platforms ...string) (bool, error)
- func (c *Container) Inspect() (*types.ContainerConfig, error)
- func (c *Container) InspectImage(image string) (*types.ImageInfo, error)
- func (c *Container) Pull(imageTags ...string) error
- func (c *Container) PullByPlatform(platform string, imageTags ...string) error
- func (c *Container) PullDefault(imageTags ...string) error
- func (c *Container) Push(source, target string, opts ...PushOption) error
- func (c *Container) Ready() error
- func (c *Container) Start() error
- func (c *Container) Stop() error
- func (c *Container) Tag(source, target string) error
- func (c *Container) Wait() error
- type Custom
- type EnvType
- type Leader
- type PushOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseImageTag ¶
func SumChecksum ¶ added in v0.5.1
Types ¶
type Build ¶
type Build struct { Leader Leader Platform types.Platform Custom Custom Registries map[string]*protos2.ContainerRegistry Folder string App string `json:"app"` Image string `json:"image"` BuildType BuildType `json:"build_type"` Runtime utils.RuntimeType Organization string ImageTag string `json:"image_tag"` Registry string ContainifyRegistry string Env EnvType File string Repository string SourcePackages []string SourceFiles []string Verbose bool // contains filtered or unexported fields }
TODO: add target container platform
func InitRuntime ¶
func NewGoServiceBuild ¶
func NewMavenServiceBuild ¶
func NewPythonServiceBuild ¶
func NewServiceBuild ¶
func (*Build) CustomString ¶ added in v0.4.0
type BuildGroup ¶ added in v0.11.0
type BuildGroup struct {
Builds []*Build
}
type BuildGroups ¶ added in v0.11.0
type BuildGroups []*BuildGroup
type BuildType ¶
type BuildType string
type Container ¶
type Container struct { Source fs.ReadDirFS Build *Build ID string Name string Image string Env EnvType Prefix string Opts types.ContainerConfig Verbose bool // contains filtered or unexported fields }
func (*Container) Apply ¶
func (c *Container) Apply(opts *types.ContainerConfig)
func (*Container) BuildImage ¶
func (*Container) BuildImageByPlatform ¶
func (*Container) BuildImageByPlatforms ¶
func (*Container) BuildIntermidiateContainer ¶
func (*Container) BuildingContainer ¶
func (c *Container) BuildingContainer(opts types.ContainerConfig) error
func (*Container) CopyContentTo ¶
func (*Container) CopyDirectoryTo ¶
TODO: ignore hidden folder and files maybe support .dockerignore file or more .dockerinclude file to include folder and files that are ignored by default
func (*Container) CopyFileFromContainer ¶
CopyFileFromContainer reads a single file from a container and returns its content as a string.
func (*Container) CopyFileTo ¶
func (*Container) ImageExists ¶
imageExists checks if the image with the specified tag exists.
func (*Container) InspectImage ¶
func (*Container) PullByPlatform ¶
func (*Container) PullDefault ¶
type EnvType ¶
type EnvType string
type PushOption ¶
type PushOption struct {
Remove bool
}
Click to show internal directories.
Click to hide internal directories.