Documentation ¶
Index ¶
Constants ¶
View Source
const ( DumpResultFilenameRegex = DumpResultPrefix + DumpResultClusterNameRegex + "_" + DumpResultRunIDRegex + DumpResultExtensionRegex DumpResultPathRegex = DumpResultClusterNameRegex + "/" + DumpResultFilenameRegex )
Backward Compatibility: Extracting the metadata from the path
View Source
const ( DumpResultClusterNameRegex = `([A-Za-z0-9\.\-_@]+)` DumpResultRunIDRegex = `([a-z0-9]{26})` DumpResultExtensionRegex = `\.?([a-z0-9\.]+)?` DumpResultPrefix = "kubehound_" DumpResultTarWriterExtension = "tar.gz" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DumpIngestor ¶
type DumpIngestor struct {
// contains filtered or unexported fields
}
func NewDumpIngestor ¶
func NewDumpIngestor(ctx context.Context, collector collector.CollectorClient, compression bool, directoryOutput string, runID *config.RunID) (*DumpIngestor, error)
func (*DumpIngestor) Close ¶
func (d *DumpIngestor) Close(ctx context.Context) error
Close() is invoked by the collector to close all handlers used to dump k8s objects. The function flushes all writers and close all the handlers.
func (*DumpIngestor) DumpK8sObjects ¶
func (d *DumpIngestor) DumpK8sObjects(ctx context.Context) error
func (*DumpIngestor) Metadata ¶ added in v1.5.0
func (d *DumpIngestor) Metadata() (collector.Metadata, error)
func (*DumpIngestor) OutputPath ¶
func (d *DumpIngestor) OutputPath() string
type DumpResult ¶ added in v1.3.3
func NewDumpResult ¶ added in v1.3.3
func NewDumpResult(clusterName, runID string, isCompressed bool) (*DumpResult, error)
func ParsePath ¶ added in v1.3.3
func ParsePath(path string) (*DumpResult, error)
func (*DumpResult) Compressed ¶ added in v1.3.3
func (i *DumpResult) Compressed()
func (*DumpResult) GetFilename ¶ added in v1.3.3
func (i *DumpResult) GetFilename() string
func (*DumpResult) GetFullPath ¶ added in v1.3.3
func (i *DumpResult) GetFullPath() string
./<clusterName>/kubehound_<clusterName>_<run_id>
func (*DumpResult) Validate ¶ added in v1.3.3
func (i *DumpResult) Validate() error
Click to show internal directories.
Click to hide internal directories.