Documentation ¶
Index ¶
- Constants
- Variables
- func AuthWithRegistry(c *dagger.Client, container *dagger.Container, opt RegistryAuthOptions) (*dagger.Container, error)
- func BuildImage(dockerFilePath string, client *dagger.Client, container *dagger.Container) (*dagger.Container, error)
- func GetContainer(c *dagger.Client, image string) (*dagger.Container, error)
- func GetContainerImagePerStack(stack string, version string) (string, error)
- func GetDaggerDir(c *dagger.Client, dir string) (*dagger.Directory, error)
- func GetDaggerDirWithEntriesCheck(c *dagger.Client, dir string) (*dagger.Directory, error)
- func ListEntries(d *dagger.Directory, failIsEmpty bool, ctx *context.Context) ([]string, error)
- func MountDir(c *dagger.Container, workDir *dagger.Directory, execPath string) (..., error)
- func NewDaggerClient(workDir string, ctx *context.Context, isWorkDirSetInClient bool) (..., error)
- func NormaliseDaggerPath(path string) string
- func PushImage(container *dagger.Container, url string, ctx context.Context) (string, error)
- func SetEnvVarsInContainer(c *dagger.Container, envVars map[string]string) (*dagger.Container, error)
- func VerifyFileEntriesInMountedDir(c *dagger.Client, dir string, files []string, ctx context.Context) error
- type DaggerContainerImage
- type DaggerSecret
- type RegistryAuthOptions
Constants ¶
View Source
const ContainerMountPathPrefix = "/build"
Variables ¶
View Source
var StackImagesMap = map[string]string{
"PYTHON": "python:3.8.5-slim-buster",
"DOCKER": "docker:23.0.1-dind",
"TERRAFORM": "hashicorp/terraform:1.3.9",
"TERRAGRUNT": "alpine/terragrunt",
"AWS": "alpine:latest",
"ALPINE": "alpine:latest",
}
Functions ¶
func AuthWithRegistry ¶
func BuildImage ¶
func BuildImage(dockerFilePath string, client *dagger.Client, container *dagger.Container) (*dagger.Container, error)
BuildImage builds the image of the dagger client.
func GetContainer ¶
GetContainer returns the container of the dagger client.
func GetContainerImagePerStack ¶
GetContainerImagePerStack returns the container image of the dagger client.
func GetDaggerDir ¶
GetDaggerDir returns the working directory of the dagger client.
func GetDaggerDirWithEntriesCheck ¶
GetDaggerDirWithEntriesCheck returns the working directory of the dagger client.
func ListEntries ¶
ListEntries lists the entries in a dagger directory.
func MountDir ¶
func MountDir(c *dagger.Container, workDir *dagger.Directory, execPath string) (*dagger. Container, error)
MountDir mounts a directory from the host to the container.
func NewDaggerClient ¶
func NormaliseDaggerPath ¶
NormaliseDaggerPath will check if the path includes a / at the beginning; if so, just return it; if not, add it.
func SetEnvVarsInContainer ¶
Types ¶
type DaggerContainerImage ¶
func GetContainerImageCustom ¶
func GetContainerImageCustom(imageURL, version string) (DaggerContainerImage, error)
GetContainerImageCustom DaggerContainerImage represents the container image of the dagger client.
type DaggerSecret ¶
type RegistryAuthOptions ¶
type RegistryAuthOptions struct { RegistryAddress string RegistryUser string RegistrySecret DaggerSecret }
Click to show internal directories.
Click to hide internal directories.