cutlass

package
v0.0.0-...-814db2d Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2021 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultMemory       string
	DefaultDisk         string
	Cached              bool
	DefaultStdoutStderr io.Writer = &bytes.Buffer{}
)
View Source
var DefaultLogger = NewLogger()

Functions

func ApiGreaterThan

func ApiGreaterThan(version string) (bool, error)

func ApiVersion

func ApiVersion() (string, error)

func CopyCfHome

func CopyCfHome() error

func CopyFixture

func CopyFixture(srcDir string) (string, error)

func CountBuildpack

func CountBuildpack(language string, stack string) (int, error)

func CreateOrUpdateBuildpack

func CreateOrUpdateBuildpack(language, file, stack string) error

func CreateProxyNetwork

func CreateProxyNetwork() (string, error)

func CreateProxyServer

func CreateProxyServer(networkName string) (proxyContainerName string, proxyPort string, err error)

func DeleteBuildpack

func DeleteBuildpack(language string) error

func DeleteContainer

func DeleteContainer(containerName string) error

func DeleteOrphanedRoutes

func DeleteOrphanedRoutes() error

func DeleteProxyNetwork

func DeleteProxyNetwork(networkName string) error

func EnsureUsesProxy

func EnsureUsesProxy(fixturePath, buildpackPath string) error

func ExecuteDockerFile

func ExecuteDockerFile(path, network, command string) (string, error)

func FindRoot

func FindRoot() (string, error)

func InternetTraffic

func InternetTraffic(fixturePath, buildpackPath string, envs []string) ([]string, bool, []string, error)

TODO: Delete after all buildpacks use EnsureUsesProxy

func InternetTrafficForNetwork

func InternetTrafficForNetwork(networkName, fixturePath, buildpackPath string, envs []string, resolve bool) ([]string, bool, []string, error)

func NewLogger

func NewLogger() lager.Logger

func NewProxy

func NewProxy() (*httptest.Server, error)

func NewTLSProxy

func NewTLSProxy() (*httptest.Server, error)

func ParseTrafficAndLogs

func ParseTrafficAndLogs(output string) ([]string, bool, []string, error)

func RandStringRunes

func RandStringRunes(n int) string

func RemovePackagedBuildpack

func RemovePackagedBuildpack(buildpack VersionedBuildpackPackage) error

func SeedRandom

func SeedRandom()

func Stacks

func Stacks() ([]string, error)

func StripColor

func StripColor(input string) string

func UniqueDestination

func UniqueDestination(traffic []string, destination string) error

func UpdateBuildpack

func UpdateBuildpack(language, file, stack string) error

Types

type App

type App struct {
	Name         string
	Path         string
	Stack        string
	Buildpacks   []string
	Memory       string
	Disk         string
	StartCommand string
	Stdout       *Buffer

	HealthCheck string
	// contains filtered or unexported fields
}

func New

func New(fixture string) *App

func (*App) AppGUID

func (a *App) AppGUID() (string, error)

func (*App) ConfirmBuildpack

func (a *App) ConfirmBuildpack(version string) error

func (*App) Destroy

func (a *App) Destroy() error

func (*App) DownloadDroplet

func (a *App) DownloadDroplet(path string) error

func (*App) Files

func (a *App) Files(path string) ([]string, error)

func (*App) Get

func (a *App) Get(path string, headers map[string]string) (string, map[string][]string, error)

func (*App) GetBody

func (a *App) GetBody(path string) (string, error)

func (*App) GetUrl

func (a *App) GetUrl(path string) (string, error)

func (*App) InstanceStates

func (a *App) InstanceStates() ([]string, error)

func (*App) Push

func (a *App) Push() error

func (*App) PushNoStart

func (a *App) PushNoStart() error

func (*App) Restart

func (a *App) Restart() error

func (*App) RunTask

func (a *App) RunTask(command string) ([]byte, error)

func (*App) SetEnv

func (a *App) SetEnv(key, value string)

func (*App) SpaceGUID

func (a *App) SpaceGUID() (string, error)

func (*App) Stop

func (a *App) Stop() error

func (*App) V3Push

func (a *App) V3Push() error

type Buffer

type Buffer struct {
	// contains filtered or unexported fields
}

func (*Buffer) ANSIStrippedString

func (b *Buffer) ANSIStrippedString() string

func (*Buffer) Read

func (b *Buffer) Read(p []byte) (n int, err error)

func (*Buffer) Reset

func (b *Buffer) Reset()

func (*Buffer) String

func (b *Buffer) String() string

func (*Buffer) Write

func (b *Buffer) Write(p []byte) (n int, err error)

type VersionedBuildpackPackage

type VersionedBuildpackPackage struct {
	Version string
	File    string
}

func PackageShimmedBuildpack

func PackageShimmedBuildpack(bpDir, stack string) (VersionedBuildpackPackage, error)

func PackageUniquelyVersionedBuildpack

func PackageUniquelyVersionedBuildpack(stack string, stackAssociationSupported bool) (VersionedBuildpackPackage, error)

func PackageUniquelyVersionedBuildpackExtra

func PackageUniquelyVersionedBuildpackExtra(name, version, stack string, cached, stackAssociationSupported bool) (VersionedBuildpackPackage, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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