Documentation ¶
Overview ¶
Package pluginmanager is responsible for plugin discovery and installation
Index ¶
- Constants
- func AvailablePlugins() ([]plugin.Discovered, error)
- func AvailablePluginsFromLocalSource(localPath string) ([]plugin.Discovered, error)
- func Clean() error
- func DeletePlugin(options DeletePluginOptions) error
- func DescribePlugin(pluginName string, target cliv1alpha1.Target) (desc *cliapi.PluginDescriptor, err error)
- func DiscoverPlugins() ([]plugin.Discovered, []plugin.Discovered)
- func DiscoverPluginsFromLocalSource(localPath string) ([]plugin.Discovered, error)
- func DiscoverServerPlugins() ([]plugin.Discovered, error)
- func DiscoverStandalonePlugins() (plugins []plugin.Discovered, err error)
- func DiscoveredFromPluginDescriptor(p *cliapi.PluginDescriptor) plugin.Discovered
- func FindVersion(recommendedPluginVersion, requestedVersion string) string
- func GetRecommendedVersionOfPlugin(pluginName string, target cliv1alpha1.Target) (string, error)
- func InitializePlugin(descriptor *cliapi.PluginDescriptor) error
- func InstallPlugin(pluginName, version string, target cliv1alpha1.Target) error
- func InstallPluginsFromLocalSource(pluginName, version string, target cliv1alpha1.Target, localPath string, ...) error
- func InstalledPlugins() (serverPlugins, standalonePlugins []cliapi.PluginDescriptor, err error)
- func InstalledServerPlugins() ([]cliapi.PluginDescriptor, error)
- func InstalledStandalonePlugins() ([]cliapi.PluginDescriptor, error)
- func SyncPlugins() error
- func UpgradePlugin(pluginName, version string, target cliv1alpha1.Target) error
- func ValidatePlugin(p *cliapi.PluginDescriptor) (err error)
- type DeletePluginOptions
Constants ¶
const ( // ManifestFileName is the file name for the manifest. ManifestFileName = "manifest.yaml" // PluginFileName is the file name for the plugin descriptor. PluginFileName = "plugin.yaml" )
Variables ¶
This section is empty.
Functions ¶
func AvailablePlugins ¶
func AvailablePlugins() ([]plugin.Discovered, error)
AvailablePlugins returns the list of available plugins including discovered and installed plugins. Plugin discovery happens for all active contexts
func AvailablePluginsFromLocalSource ¶
func AvailablePluginsFromLocalSource(localPath string) ([]plugin.Discovered, error)
AvailablePluginsFromLocalSource returns the list of available plugins from local source
func DeletePlugin ¶
func DeletePlugin(options DeletePluginOptions) error
DeletePlugin deletes a plugin.
func DescribePlugin ¶
func DescribePlugin(pluginName string, target cliv1alpha1.Target) (desc *cliapi.PluginDescriptor, err error)
DescribePlugin describes a plugin.
func DiscoverPlugins ¶
func DiscoverPlugins() ([]plugin.Discovered, []plugin.Discovered)
DiscoverPlugins returns all the discovered plugins including standalone and context-scoped plugins Context scoped plugin discovery happens for all active contexts
func DiscoverPluginsFromLocalSource ¶
func DiscoverPluginsFromLocalSource(localPath string) ([]plugin.Discovered, error)
DiscoverPluginsFromLocalSource returns the available plugins that are discovered from the provided local path
func DiscoverServerPlugins ¶
func DiscoverServerPlugins() ([]plugin.Discovered, error)
DiscoverServerPlugins returns the available plugins associated all the active contexts
func DiscoverStandalonePlugins ¶
func DiscoverStandalonePlugins() (plugins []plugin.Discovered, err error)
DiscoverStandalonePlugins returns the available standalone plugins
func DiscoveredFromPluginDescriptor ¶
func DiscoveredFromPluginDescriptor(p *cliapi.PluginDescriptor) plugin.Discovered
DiscoveredFromPluginDescriptor returns discovered plugin object from k8sV1alpha1
func FindVersion ¶
func GetRecommendedVersionOfPlugin ¶
func GetRecommendedVersionOfPlugin(pluginName string, target cliv1alpha1.Target) (string, error)
GetRecommendedVersionOfPlugin returns recommended version of the plugin
func InitializePlugin ¶
func InitializePlugin(descriptor *cliapi.PluginDescriptor) error
InitializePlugin initializes the plugin configuration
func InstallPlugin ¶
func InstallPlugin(pluginName, version string, target cliv1alpha1.Target) error
InstallPlugin installs a plugin from the given repository.
func InstallPluginsFromLocalSource ¶
func InstallPluginsFromLocalSource(pluginName, version string, target cliv1alpha1.Target, localPath string, installTestPlugin bool) error
InstallPluginsFromLocalSource installs plugin from local source directory
func InstalledPlugins ¶
func InstalledPlugins() (serverPlugins, standalonePlugins []cliapi.PluginDescriptor, err error)
InstalledPlugins returns the list of installed context-scoped and standalone plugins.
func InstalledServerPlugins ¶
func InstalledServerPlugins() ([]cliapi.PluginDescriptor, error)
InstalledServerPlugins returns the installed server plugins.
func InstalledStandalonePlugins ¶
func InstalledStandalonePlugins() ([]cliapi.PluginDescriptor, error)
InstalledStandalonePlugins returns the installed standalone plugins.
func SyncPlugins ¶
func SyncPlugins() error
SyncPlugins automatically downloads all available plugins to users machine
func UpgradePlugin ¶
func UpgradePlugin(pluginName, version string, target cliv1alpha1.Target) error
UpgradePlugin upgrades a plugin from the given repository.
func ValidatePlugin ¶
func ValidatePlugin(p *cliapi.PluginDescriptor) (err error)
ValidatePlugin validates the plugin descriptor.
Types ¶
type DeletePluginOptions ¶
type DeletePluginOptions struct { Target cliv1alpha1.Target PluginName string ForceDelete bool }