Documentation ¶
Index ¶
- Constants
- Variables
- func GetImageForExecution(ctx context.Context, containerRuntime forge.ContainerRuntime, ...) (forge.Image, error)
- func TaskReferenceToDirectory(ref *azuredevops.TaskReference) (string, error)
- func TaskToContainerConfig(ref *azuredevops.TaskReference, task *azuredevops.Task, execution Execution, ...) (*forge.ContainerConfig, error)
- type Execution
- type Mapping
Constants ¶
View Source
const ( // DefaultNode10ImageReference is the default image to use // when a task specifies a "Node10" execution. DefaultNode10ImageReference = "docker.io/library/node:10" // DefaultNode16ImageReference is the default image to use // when a task specifies a "Node16" execution. DefaultNode16ImageReference = "docker.io/library/node:16" // DefaultNodeImageReference is the default image to use // when a task specifies a "Node" execution. DefaultNodeImageReference = DefaultNode16ImageReference )
Variables ¶
View Source
var ( DefaultRootPath = containerfs.WorkingDir DefaultTaskPath = DefaultRootPath + "/task" )
View Source
var ( // Node10ImageReference is the image to use // when a task specifies a "Node10" execution. Node10ImageReference = DefaultNode10ImageReference // Node16ImageReference is the image to use // when a task specifies a "Node16" execution. Node16ImageReference = DefaultNode16ImageReference // NodeImageReference is the image to use // when a task specifies a "Node" execution. NodeImageReference = DefaultNodeImageReference )
View Source
var DefaultMapping = &Mapping{ TaskPath: DefaultTaskPath, }
Functions ¶
func GetImageForExecution ¶
func GetImageForExecution(ctx context.Context, containerRuntime forge.ContainerRuntime, execution Execution) (forge.Image, error)
GetImageForExecution ...
func TaskReferenceToDirectory ¶
func TaskReferenceToDirectory(ref *azuredevops.TaskReference) (string, error)
TaskReferenceToDirectory is a re-export of DefaultMapping.TaskReferenceToDirectory for convenience purposes.
func TaskToContainerConfig ¶
func TaskToContainerConfig(ref *azuredevops.TaskReference, task *azuredevops.Task, execution Execution, inputs map[string]string) (*forge.ContainerConfig, error)
Types ¶
type Mapping ¶
type Mapping struct {
TaskPath string
}
func (*Mapping) TaskReferenceToDirectory ¶
func (m *Mapping) TaskReferenceToDirectory(ref *azuredevops.TaskReference) (string, error)
TaskReferenceToDirectory takes an *azuredevops.TaskReference and returns the path to the directory where the corresponding task.json can be found on the host machine.
func (*Mapping) TaskToContainerConfig ¶
func (m *Mapping) TaskToContainerConfig(ref *azuredevops.TaskReference, task *azuredevops.Task, execution Execution, inputs map[string]string) (*forge.ContainerConfig, error)
Click to show internal directories.
Click to hide internal directories.