packager

package
v0.6.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CollectStaticFiles

func CollectStaticFiles(cwd string) (map[string]os.File, error)

CollectStaticFiles collects all of the files in the `static/` directory relative to cwd and generates a map of their relative paths.

Types

type BundlePackageJob

type BundlePackageJob struct{}

func (*BundlePackageJob) Package

func (b *BundlePackageJob) Package(log util.FriendlyLogger, ctx *project.Context) error

Package packages the application.

func (*BundlePackageJob) Type

func (b *BundlePackageJob) Type() string

Type returns the job type.

type DockerImagePackageJob

type DockerImagePackageJob struct{}

func (*DockerImagePackageJob) Package

Package packages the application.

func (*DockerImagePackageJob) Type

func (b *DockerImagePackageJob) Type() string

Type returns the job type.

type PackageJob

type PackageJob interface {
	Type() string
	Package(logger util.FriendlyLogger, pctx *project.Context) error
}

PackageJob represents a specific type of packaging, for example modules into bundle, bundle into container image, etc.

func NewBundlePackageJob

func NewBundlePackageJob() PackageJob

func NewDockerImagePackageJob

func NewDockerImagePackageJob() PackageJob

type Packager

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

Packager is responsible for packaging and publishing projects.

func New

func New(log util.FriendlyLogger) *Packager

New creates a new Packager.

func (*Packager) Package

func (p *Packager) Package(ctx *project.Context, jobs ...PackageJob) error

Package executes the given set of PackageJobs, returning an error if any fail.

Jump to

Keyboard shortcuts

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