cmd

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2025 License: AGPL-3.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const AgentPluginDir = ".compliance-framework/plugins"
View Source
const AgentPolicyDir = ".compliance-framework/policies"

Variables

This section is empty.

Functions

func AgentCmd

func AgentCmd() *cobra.Command

func DownloadPluginCmd

func DownloadPluginCmd() *cobra.Command

func DownloadPolicyCmd

func DownloadPolicyCmd() *cobra.Command

Types

type AgentRunner

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

func (*AgentRunner) DownloadPlugins

func (ar *AgentRunner) DownloadPlugins() error

DownloadPlugins checks each item in the config and retrieves the source of the plugin building a set of unique sources. It then checks if the source is a path that exists on the filesystem, if it isn't, it will download the plugin to the filesystem.

We also update the map of plugin sources, this could be an identity map if it's a local file or maps from the URL to the local file if we downloaded a remote file.

We return any errors that occurred during the download process. TODO: What is the right error handling here?

func (*AgentRunner) DownloadPolicies

func (ar *AgentRunner) DownloadPolicies() error

func (*AgentRunner) Run

func (ar *AgentRunner) Run() error

type DownloadRunner

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

func (*DownloadRunner) Run

func (d *DownloadRunner) Run(cmd *cobra.Command, args []string) error

type PolicyDownloadRunner

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

func (*PolicyDownloadRunner) Run

func (d *PolicyDownloadRunner) Run(cmd *cobra.Command, args []string) error

Jump to

Keyboard shortcuts

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