infrastructure

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2022 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const InfrastructureInfo string = "infrastructure.json"

A json file containing the infrastructure information

View Source
const RegoPolicyDirectory string = "/tmp/adminconfig/"

A directory containing rego files that define admin config policies

View Source
const ValidationPath string = "/tmp/taxonomy/infraattributes.json#/definitions/Infrastructure"

Variables

This section is empty.

Functions

This section is empty.

Types

type AttributeManager

type AttributeManager struct {
	Log            zerolog.Logger
	Infrastructure infraattributes.Infrastructure
	Mux            *sync.RWMutex
}

AttributeManager provides access to infrastructure attributes

func NewAttributeManager

func NewAttributeManager() (*AttributeManager, error)

func (*AttributeManager) GetAttribute

func (m *AttributeManager) GetAttribute(name taxonomy.Attribute, instance string) *taxonomy.InfrastructureElement

GetAttribute returns an infrastructure attribute based on the attribute and instance names

func (*AttributeManager) GetInstanceType

func (m *AttributeManager) GetInstanceType(name taxonomy.Attribute) *taxonomy.InstanceType

GetInstanceType returns the instance type associated with the attribute TODO: validate that there is only one instance type associated with the given attribute

func (*AttributeManager) GetOptions

Options for file monitor including the monitored directory and the relevant file extension

func (*AttributeManager) OnError

func (m *AttributeManager) OnError(err error)

notification from the file system monitor about an error while getting access to the infrastructure file

func (*AttributeManager) OnNotify

func (m *AttributeManager) OnNotify()

notification from the file monitor on change in the infrastructure json file

Jump to

Keyboard shortcuts

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