platforms

package
v2.1.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SupportedPlatforms = []Platform{
	&java.Platform{},
	&golang.Platform{},
	&node.Platform{},
}

SupportedPlatforms is the canonical list of platforms Fabric supports

Functions

This section is empty.

Types

type Builder

type Builder struct {
	Registry *Registry
	Client   *docker.Client
}

func (*Builder) GenerateDockerBuild

func (b *Builder) GenerateDockerBuild(ccType, path string, codePackage io.Reader) (io.Reader, error)

type PackageWriter added in v1.3.0

type PackageWriter interface {
	Write(name string, payload []byte, tw *tar.Writer) error
}

type PackageWriterWrapper added in v1.3.0

type PackageWriterWrapper func(name string, payload []byte, tw *tar.Writer) error

func (PackageWriterWrapper) Write added in v1.3.0

func (pw PackageWriterWrapper) Write(name string, payload []byte, tw *tar.Writer) error

type Platform

type Platform interface {
	Name() string
	GenerateDockerfile() (string, error)
	DockerBuildOptions(path string) (util.DockerBuildOptions, error)
}

Interface for validating the specification and writing the package for the given platform

type Registry added in v1.3.0

type Registry struct {
	Platforms     map[string]Platform
	PackageWriter PackageWriter
}

func NewRegistry added in v1.3.0

func NewRegistry(platformTypes ...Platform) *Registry

func (*Registry) GenerateDockerBuild added in v1.3.0

func (r *Registry) GenerateDockerBuild(ccType, path string, codePackage io.Reader, client *docker.Client) (io.Reader, error)

func (*Registry) GenerateDockerfile added in v1.3.0

func (r *Registry) GenerateDockerfile(ccType string) (string, error)

func (*Registry) StreamDockerBuild added in v1.3.0

func (r *Registry) StreamDockerBuild(ccType, path string, codePackage io.Reader, inputFiles map[string][]byte, tw *tar.Writer, client *docker.Client) error

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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