installer

package
v0.0.0-...-a4a88c6 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Overview

Package installer provides a package manager that installs and uninstalls packages.

Package installer contains the installer subcommands

Index

Constants

This section is empty.

Variables

View Source
var PackagesList = []Package{
	{Name: "datadog-apm-inject", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-java", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-ruby", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-js", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-dotnet", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-python", /* contains filtered or unexported fields */},
	{Name: "datadog-apm-library-php", /* contains filtered or unexported fields */},
	{Name: "datadog-agent", /* contains filtered or unexported fields */},
}

PackagesList lists all known packages. Not all of them are installable

Functions

func DefaultPackages

func DefaultPackages(env *env.Env) []string

DefaultPackages resolves the default packages URLs to install based on the environment.

func Setup

func Setup(ctx context.Context, env *env.Env) error

Setup is the main function to resolve packages to install and install them

Types

type Installer

type Installer interface {
	IsInstalled(ctx context.Context, pkg string) (bool, error)

	AvailableDiskSpace() (uint64, error)
	State(pkg string) (repository.State, error)
	States() (map[string]repository.State, error)
	ConfigState(pkg string) (repository.State, error)
	ConfigStates() (map[string]repository.State, error)

	Install(ctx context.Context, url string, args []string) error
	Remove(ctx context.Context, pkg string) error
	Purge(ctx context.Context)

	InstallExperiment(ctx context.Context, url string) error
	RemoveExperiment(ctx context.Context, pkg string) error
	PromoteExperiment(ctx context.Context, pkg string) error

	InstallConfigExperiment(ctx context.Context, pkg string, version string) error
	RemoveConfigExperiment(ctx context.Context, pkg string) error
	PromoteConfigExperiment(ctx context.Context, pkg string) error

	GarbageCollect(ctx context.Context) error

	InstrumentAPMInjector(ctx context.Context, method string) error
	UninstrumentAPMInjector(ctx context.Context, method string) error

	Close() error
}

Installer is a package manager that installs and uninstalls packages.

func NewInstaller

func NewInstaller(env *env.Env) (Installer, error)

NewInstaller returns a new Package Manager.

type Package

type Package struct {
	Name string
	// contains filtered or unexported fields
}

Package represents a package known to the installer

Directories

Path Synopsis
Package env provides the environment variables for the installer.
Package env provides the environment variables for the installer.
Package errors contains errors used by the installer.
Package errors contains errors used by the installer.
Package packages contains the install/upgrades/uninstall logic for packages
Package packages contains the install/upgrades/uninstall logic for packages
embedded
Package embedded provides embedded files for the installer.
Package embedded provides embedded files for the installer.
Package repository contains the packaging logic of the updater.
Package repository contains the packaging logic of the updater.

Jump to

Keyboard shortcuts

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