Documentation
¶
Index ¶
- Constants
- Variables
- func BuildReleaseArtifacts(ctx context.Context, opts BuildReleaseArtifactsOpts, logger hclog.Logger) error
- func GenerateAndAddDockerfileToTar(tw *tar.Writer, dockerfileTarPath, fromImage string, runCommands []string, ...) error
- func GetMacSigningCommandMounts(creds *mac_signing.Credentials) []string
- func GetQuillImage() string
- func GetSecretsCommandMounts(secrets []secrets.Secret) []string
- func GetSecretsRunMounts(secrets []secrets.Secret) string
- func SetMacSigningTempEnvVars(creds *mac_signing.Credentials) error
- func SetTempEnvVars(secrets []secrets.Secret) error
- func ValidateBuildkitdAddress(ctx context.Context, address string) error
- func ValidateBuildkitdDriver(ctx context.Context, driver string) error
- func ValidateBuildkitdDriverOpts(ctx context.Context, driver string, driverOpts []string) error
- func ValidateBuildxDriver(ctx context.Context, driver string) error
- func ValidateImageNameWithDigest(imageName string) error
- type BuildReleaseArtifactsOpts
- type Builder
- type DockerfileOpts
- type Logger
- type NewBuilderOpts
Constants ¶
View Source
const ( ContainerSourceDir = "git" ContainerArtifactsDir = "result" DefaultQuillImage = "registry.werf.io/trdl/quill:028f446b1b76be918781b24e7f77a6b4c0c74972" )
Variables ¶
View Source
var ErrImageNameWithoutRequiredDigest = errors.New("the image name must contain an digest \"REPO[:TAG]@DIGEST\" (e.g. \"ubuntu:18.04@sha256:538529c9d229fb55f50e6746b119e899775205d62c0fc1b7e679b30d02ecb6e8\")")
Functions ¶
func BuildReleaseArtifacts ¶
func GetMacSigningCommandMounts ¶
func GetMacSigningCommandMounts(creds *mac_signing.Credentials) []string
func GetQuillImage ¶
func GetQuillImage() string
func GetSecretsCommandMounts ¶
func GetSecretsRunMounts ¶
func SetMacSigningTempEnvVars ¶
func SetMacSigningTempEnvVars(creds *mac_signing.Credentials) error
func SetTempEnvVars ¶
func ValidateBuildkitdDriver ¶
ValidateBuildkitdDriver accepts an empty driver, meaning trdl provisions no buildkitd of its own.
func ValidateBuildkitdDriverOpts ¶
ValidateBuildkitdDriverOpts rejects an option the driver cannot honor while the configuration is being written, rather than at release time. The options have no environment counterpart, so this check is reachable for every value that can ever arrive.
func ValidateBuildxDriver ¶
ValidateBuildxDriver accepts an empty driver, meaning the setting is not in use. The build streams a tarball to stdout (`-o - -`), which the default "docker" driver cannot export, so an unsupported driver is rejected here instead of failing opaquely mid-build.
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
func NewBuilder ¶
func NewBuilder(ctx context.Context, opts *NewBuilderOpts) (*Builder, error)
func (*Builder) Build ¶
func (b *Builder) Build(ctx context.Context, contextReader *nio.PipeReader, tarWriter *nio.PipeWriter) error
type DockerfileOpts ¶
type DockerfileOpts struct {
EnvVars map[string]string
Labels map[string]string
Secrets []secrets.Secret
MacSigningCredentials *mac_signing.Credentials
}
type NewBuilderOpts ¶
Click to show internal directories.
Click to hide internal directories.