Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrUninstallOutsideOfPluginDir = errors.New("cannot uninstall a plugin outside of the plugins directory") ErrUninstallInvalidPluginDir = errors.New("cannot recognize as plugin folder") )
Functions ¶
This section is empty.
Types ¶
type Dependencies ¶
type Dependencies struct { GrafanaVersion string `json:"grafanaVersion"` Plugins []PluginDependency `json:"plugins"` }
type Dependency ¶
type ErrPermissionDenied ¶
type ErrPermissionDenied struct {
Path string
}
func (ErrPermissionDenied) Error ¶
func (e ErrPermissionDenied) Error() string
type ExtractedPluginArchive ¶
type ExtractedPluginArchive struct { ID string Version string Dependencies []*Dependency Path string }
type FS ¶
type FS struct {
// contains filtered or unexported fields
}
func FileSystem ¶
func FileSystem(logger log.PrettyLogger, pluginsDir string) *FS
func (*FS) Add ¶
func (fs *FS) Add(ctx context.Context, pluginID string, pluginArchive *zip.ReadCloser) ( *ExtractedPluginArchive, error)
type InstalledPlugin ¶
type InstalledPlugin struct { ID string `json:"id"` Name string `json:"name"` Type string `json:"type"` Info PluginInfo `json:"info"` Dependencies Dependencies `json:"dependencies"` }
type PluginDependency ¶
type PluginInfo ¶
Click to show internal directories.
Click to hide internal directories.