installer

package
v0.0.0-...-96442b1 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

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

Index

Constants

View Source
const (
	// PackagesPath is the path to the packages directory.
	PackagesPath = "/opt/datadog-packages"
	// TmpDirPath is the path to the temporary directory used for package installation.
	TmpDirPath = "/opt/datadog-packages"
	// LocksPack is the path to the locks directory.
	LocksPack = "/var/run/datadog-installer/locks"
	// DefaultConfigsDir is the default Agent configuration directory
	DefaultConfigsDir = "/etc"
)

Variables

This section is empty.

Functions

func DefaultPackages

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

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

Types

type Installer

type Installer interface {
	IsInstalled(ctx context.Context, pkg string) (bool, error)
	State(pkg string) (repository.State, error)
	States() (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

	GarbageCollect(ctx context.Context) 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.

Directories

Path Synopsis
Package errors contains errors used by the installer.
Package errors contains errors used by the installer.
Package repository contains the packaging logic of the updater.
Package repository contains the packaging logic of the updater.
Package service provides a way to interact with os services
Package service provides a way to interact with os services

Jump to

Keyboard shortcuts

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