cache

package
v0.20240703.0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package cache provides types and functionality for reasoning about the content cached on a particular VHD version through both components.json and manifest.json.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Components

type Components struct {
	ContainerImages []ContainerImage `json:"containerImages"`
	DownloadFiles   []DownloadFile   `json:"downloadFiles"`
}

Components represents the components.json file.

type ContainerImage

type ContainerImage struct {
	DownloadURL           string                 `json:"downloadURL"`
	MultiArchVersions     []string               `json:"multiArchVersions"`
	Amd64OnlyVersions     []string               `json:"amd64OnlyVersions"`
	PrefetchOptimizations []PrefetchOptimization `json:"prefetchOptimizations"`
}

ContainerImage represents fields that occur on components.json.

type Dependency

type Dependency struct {
	Versions  []string          `json:"versions"`
	Installed map[string]string `json:"installed"`
	Pinned    map[string]string `json:"pinned"`
	Edge      string            `json:"edge"`
}

Dependency represents fields that occur on manifest.json.

type DownloadFile

type DownloadFile struct {
	FileName         string   `json:"fileName"`
	DownloadLocation string   `json:"downloadLocation"`
	DownloadURL      string   `json:"downloadURL"`
	Versions         []string `json:"versions"`
}

DownloadFile represents DownloadFile fields that occur on components.json.

type Manifest

type Manifest struct {
	Containerd             Dependency `json:"containerd"`
	Runc                   Dependency `json:"runc"`
	NvidiaContainerRuntime Dependency `json:"nvidia-container-runtime"`
	NvidiaDrivers          Dependency `json:"nvidia-drivers"`
	Kubernetes             Dependency `json:"kubernetes"`
}

Manifest represents the manifest.json file.

type OnVHD

type OnVHD struct {
	FromManifest                 *Manifest                 `json:"cachedFromManifest"`
	FromComponentContainerImages map[string]ContainerImage `json:"cachedFromComponentContainerImages"`
	FromComponentDownloadedFiles map[string]DownloadFile   `json:"cachedFromComponentDownloadedFiles"`
}

CachedOnVHD represents the cached components on the VHD.

func GetOnVHD

func GetOnVHD() *OnVHD

GetOnVHD returns the set of components and binaries that have been cached on the particular VHD corresponding to the given agentbakersvc version.

type PrefetchOptimization

type PrefetchOptimization struct {
	Version  string   `json:"version"`
	Binaries []string `json:"binaries"`
}

PrefetchOptimization represents fields that occur on components.json.

type Versions

type Versions struct {
	Versions []string `json:"versions"`
}

Versions of components on manifest.json.

Jump to

Keyboard shortcuts

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