resource

package
v0.75.0-no-limit Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2016 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrAborted = errors.New("script aborted")

Functions

func GenerateResourceHash

func GenerateResourceHash(source atc.Source, resourceType string) string

func ResourcesDir

func ResourcesDir(suffix string) string

Types

type ArtifactDestination

type ArtifactDestination interface {
	StreamIn(string, io.Reader) error
}

type ArtifactSource

type ArtifactSource interface {
	StreamTo(ArtifactDestination) error

	// VolumeOn returns a Volume object that contains the artifact from the
	// ArtifactSource which is on a particular Worker. If a volume cannot be found
	// or a volume manager cannot be found on the worker then it will return
	// false.
	VolumeOn(worker.Worker) (baggageclaim.Volume, bool, error)
}

type Cache

type Cache interface {
	IsInitialized() (bool, error)
	Initialize() error
}

type CacheIdentifier

type CacheIdentifier interface {
	FindOn(lager.Logger, baggageclaim.Client) (baggageclaim.Volume, bool, error)
	CreateOn(lager.Logger, baggageclaim.Client) (baggageclaim.Volume, error)

	VolumeIdentifier() db.VolumeIdentifier
}

type ContainerImage

type ContainerImage string

type EmptyMetadata

type EmptyMetadata struct{}

func (EmptyMetadata) Env

func (m EmptyMetadata) Env() []string

type ErrResourceScriptFailed

type ErrResourceScriptFailed struct {
	Path       string
	Args       []string
	ExitStatus int

	Stderr string
}

func (ErrResourceScriptFailed) Error

func (err ErrResourceScriptFailed) Error() string

type IOConfig

type IOConfig struct {
	Stdout io.Writer
	Stderr io.Writer
}

type Metadata

type Metadata interface {
	Env() []string
}

type Resource

func NewResource

func NewResource(container worker.Container) Resource

type ResourceCacheIdentifier

type ResourceCacheIdentifier struct {
	Type    ResourceType
	Version atc.Version
	Source  atc.Source
	Params  atc.Params
}

func (ResourceCacheIdentifier) CreateOn

func (identifier ResourceCacheIdentifier) CreateOn(logger lager.Logger, vm baggageclaim.Client) (baggageclaim.Volume, error)

func (ResourceCacheIdentifier) FindOn

func (ResourceCacheIdentifier) VolumeIdentifier

func (identifier ResourceCacheIdentifier) VolumeIdentifier() db.VolumeIdentifier

type ResourceType

type ResourceType string

type Session

type Session struct {
	ID        worker.Identifier
	Metadata  worker.Metadata
	Ephemeral bool
}

type TrackerDB

type TrackerDB interface {
	InsertVolume(data db.Volume) error
}

type TrackerFactory

type TrackerFactory struct {
	DB TrackerDB
}

func (TrackerFactory) TrackerFor

func (factory TrackerFactory) TrackerFor(client worker.Client) Tracker

type TrackerMetadata

type TrackerMetadata struct {
	ExternalURL  string
	PipelineName string
	ResourceName string
}

func (TrackerMetadata) Env

func (m TrackerMetadata) Env() []string

type VersionedSource

type VersionedSource interface {
	ifrit.Runner

	Version() atc.Version
	Metadata() []atc.MetadataField

	StreamOut(string) (io.ReadCloser, error)
	StreamIn(string, io.Reader) error
}

type VolumeMount

type VolumeMount struct {
	Volume    baggageclaim.Volume
	MountPath string
}

Directories

Path Synopsis
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL