Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AllowTypesPlugin ¶
type AllowTypesPlugin struct {
// contains filtered or unexported fields
}
func NewAllowTypesPlugin ¶
func NewAllowTypesPlugin(args []string) (*AllowTypesPlugin, error)
func (*AllowTypesPlugin) Authorize ¶
func (p *AllowTypesPlugin) Authorize(ctx context.Context, req *authorization.AuthorizeRequest) error
type Config ¶
type Config struct {
// If the plugin should be started by file-butler as another process:
// Cmd is the command and args to run the plugin.
// Example: "go run ./plugin/simple"
Cmd []string
// If the plugin is started as a standalone process:
// Addr is the host:port the plugin listens on.
Addr string
// BuiltIn is the identifier for a built-in plugin.
BuiltIn string
// Args are the arguments to pass to the plugin. (only used with Cmd and BuiltIn)
Args []string
// Name is the unique name of the plugin used to identify it.
Name string
LogLevel hclog.Level
}
Config defines the configuration required to start a plugin.
There are three types: - Cmd: An external binary or script that should be started using this command. - Addr: The host:port to an already running process that should be connected to. Only grpc is supported. - BuiltIn: If a built-in plugin should be used. These will not ran as a part of the file-butler application.
type Plugin ¶
type Plugin interface {
Name() string
Stop() error
shared.Authorizer
}
Click to show internal directories.
Click to hide internal directories.