plugin

package
v1.6.6 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DownloadPlugins

func DownloadPlugins(fd FileDownloader) error

DownloadPlugins this function downloads and/or checks that a plugin executable exits on the filesystem

func GetPluginLocation

func GetPluginLocation(pluginName string) (string, error)

GetPluginLocation returns the location of the plugin on the filesystem via plugin name. If the plugin is not configured in the configmap, an error is returned.

Types

type FileDownloader

type FileDownloader interface {
	Get(url string) (resp *http.Response, err error)
}

FileDownloader is an interface that allows us to mock the http.Get function

type FileDownloaderImpl

type FileDownloaderImpl struct {
}

FileDownloaderImpl is the default/real implementation of the FileDownloader interface

func (FileDownloaderImpl) Get

func (fd FileDownloaderImpl) Get(url string) (resp *http.Response, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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