installpackage

package
v1.25.2 Latest Latest
Warning

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

Go to latest
Published: Dec 25, 2022 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const ProxyVersion = "v1.1.2" // renovate: depName=aquaproj/aqua-proxy

Variables

This section is empty.

Functions

This section is empty.

Types

type ChecksumCalculator added in v1.20.0

type ChecksumCalculator interface {
	Calculate(fs afero.Fs, filename, algorithm string) (string, error)
}

type DownloadParam added in v1.18.0

type DownloadParam struct {
	Package         *config.Package
	Checksums       *checksum.Checksums
	Dest            string
	Asset           string
	RequireChecksum bool
}

type Executor added in v1.15.0

type Executor interface {
	GoBuild(ctx context.Context, exePath, src, exeDir string) (int, error)
	GoInstall(ctx context.Context, path, gobin string) (int, error)
}

type Installer

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

func New

func New(param *config.Param, downloader domain.PackageDownloader, rt *runtime.Runtime, fs afero.Fs, linker domain.Linker, executor Executor, chkDL domain.ChecksumDownloader, chkCalc ChecksumCalculator, unarchiver Unarchiver, policyChecker domain.PolicyChecker) *Installer

func (*Installer) Copy added in v1.20.0

func (inst *Installer) Copy(dest, src string) error

func (*Installer) InstallAqua added in v1.22.0

func (inst *Installer) InstallAqua(ctx context.Context, logE *logrus.Entry, version string) error

func (*Installer) InstallPackage

func (inst *Installer) InstallPackage(ctx context.Context, logE *logrus.Entry, param *domain.ParamInstallPackage) error

func (*Installer) InstallPackages

func (inst *Installer) InstallPackages(ctx context.Context, logE *logrus.Entry, param *domain.ParamInstallPackages) error

func (*Installer) InstallProxy

func (inst *Installer) InstallProxy(ctx context.Context, logE *logrus.Entry) error

func (*Installer) SetCopyDir added in v1.20.0

func (inst *Installer) SetCopyDir(copyDir string)

func (*Installer) WaitExe added in v1.20.0

func (inst *Installer) WaitExe(ctx context.Context, logE *logrus.Entry, exePath string) error

type MockChecksumCalculator added in v1.22.0

type MockChecksumCalculator struct {
	Checksum string
	Err      error
}

func (*MockChecksumCalculator) Calculate added in v1.22.0

func (calc *MockChecksumCalculator) Calculate(fs afero.Fs, filename, algorithm string) (string, error)

type MockUnarchiver added in v1.22.0

type MockUnarchiver struct {
	Err error
}

func (*MockUnarchiver) Unarchive added in v1.22.0

func (unarchiver *MockUnarchiver) Unarchive(src *unarchive.File, dest string, logE *logrus.Entry, fs afero.Fs, prgOpts *unarchive.ProgressBarOpts) error

type ParamVerifyChecksum added in v1.20.0

type ParamVerifyChecksum struct {
	ChecksumID string
	Checksum   *checksum.Checksum
	Checksums  *checksum.Checksums
	Pkg        *config.Package
	AssetName  string
	Body       io.Reader
	TempDir    string
}

type Unarchiver added in v1.20.0

type Unarchiver interface {
	Unarchive(src *unarchive.File, dest string, logE *logrus.Entry, fs afero.Fs, prgOpts *unarchive.ProgressBarOpts) error
}

Jump to

Keyboard shortcuts

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