installers

package
v0.60.0-rc.5 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package installers processes the installers_v2.json file

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetProductURL

func GetProductURL(url string, product string, version string, arch string) (string, error)

GetProductURL returns the URL for a product/version/arch pair from a installers_v2.json URL

Types

type Arch

type Arch struct {
	URL string `json:"url"`
}

Arch is the architecture-specific URL for an installer

type Installers

type Installers struct {
	URL      string
	Products map[string]Product
}

Installers contains the product-specific URLs for an installer Example: {"datadog-agent": {...} }

func ListVersions

func ListVersions(url string) (*Installers, error)

ListVersions returns a list of available product versions from a installers_v2.json URL

func (*Installers) UnmarshalJSON

func (i *Installers) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface

type Product

type Product struct {
	Version map[string]Version
}

Product contains the version-specific URLs for an installer product Example: {"7.50.0-1": {...} }

func (*Product) UnmarshalJSON

func (i *Product) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface

type Version

type Version struct {
	Arch map[string]Arch
}

Version contains the architecture-specific URLs for an installer version Example: {"x86_64": {...} }

func (*Version) UnmarshalJSON

func (i *Version) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface

Jump to

Keyboard shortcuts

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