bundle

package
v0.0.0-...-0a82276 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2024 License: AGPL-3.0 Imports: 32 Imported by: 2

Documentation

Overview

Package bundle defines an API endpoint for functions dealing with bundles.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(registry facade.FacadeRegistry)

Register is called to expose a package of facades onto a given registry.

Types

type APIv8

type APIv8 struct {
	*BundleAPI
}

APIv8 provides the Bundle API facade for version 8. It drops IncludeSeries from ExportBundle params, and drops series entirely from ExportBundle output

type Backend

type Backend interface {
	ExportPartial(cfg state.ExportConfig, store objectstore.ObjectStore) (description.Model, error)
	GetExportConfig() state.ExportConfig
	Charm(url string) (charm.Charm, error)
}

func NewStateShim

func NewStateShim(st *state.State) Backend

NewStateShim creates new state shim to be used by bundle Facade.

type BundleAPI

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

BundleAPI implements the Bundle interface and is the concrete implementation of the API end point.

func NewBundleAPI

func NewBundleAPI(
	st Backend,
	store objectstore.ObjectStore,
	auth facade.Authorizer,
	tag names.ModelTag,
	networkService NetworkService,
	logger corelogger.Logger,
) (*BundleAPI, error)

NewBundleAPI returns the new Bundle API facade.

func (*BundleAPI) ExportBundle

ExportBundle exports the current model configuration as bundle.

func (*BundleAPI) GetChangesMapArgs

GetChangesMapArgs returns the list of changes required to deploy the given bundle data. The changes are sorted by requirements, so that they can be applied in order. V4 GetChangesMapArgs is not supported on anything less than v4

type NetworkService

type NetworkService interface {
	// GetAllSpaces returns all spaces for the model.
	GetAllSpaces(ctx context.Context) (network.SpaceInfos, error)
}

NetworkService is the interface that is used to interact with the network spaces/subnets.

Jump to

Keyboard shortcuts

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