Documentation ¶
Index ¶
- Variables
- func ReverseSlice[T comparable](s []T)
- type Cookbook
- type CookbookListItem
- type CookbookListResult
- type CookbookMeta
- type CookbookVersion
- type Interface
- type Node
- type NodeList
- type PolicyGroup
- type Role
- type RoleList
- type Service
- func (s Service) GetClient() *chef.Client
- func (s Service) GetCookbook(ctx context.Context, name string) (*Cookbook, error)
- func (s Service) GetCookbookVersion(ctx context.Context, name string, version string) (*Cookbook, error)
- func (s Service) GetCookbooks(ctx context.Context) (*CookbookListResult, error)
- func (s Service) GetDatabagItemContent(ctx context.Context, databag string, item string) (chef.DataBagItem, error)
- func (s Service) GetDatabagItems(ctx context.Context, name string) (*chef.DataBagListResult, error)
- func (s Service) GetDatabags(ctx context.Context) (interface{}, error)
- func (s Service) GetEnvironment(ctx context.Context, name string) (*chef.Environment, error)
- func (s Service) GetEnvironments(ctx context.Context) (interface{}, error)
- func (s Service) GetGroup(ctx context.Context, name string) (chef.Group, error)
- func (s Service) GetGroups(ctx context.Context) (interface{}, error)
- func (s Service) GetLatestCookbooks(ctx context.Context) (*CookbookListResult, error)
- func (s Service) GetNode(ctx context.Context, name string) (*Node, error)
- func (s Service) GetNodes(ctx context.Context) (*NodeList, error)
- func (s Service) GetPolicies(ctx context.Context) (chef.PoliciesGetResponse, error)
- func (s Service) GetPolicy(ctx context.Context, name string) (chef.PolicyGetResponse, error)
- func (s Service) GetPolicyGroup(ctx context.Context, name string) (PolicyGroup, error)
- func (s Service) GetPolicyGroups(ctx context.Context) (chef.PolicyGroupGetResponse, error)
- func (s Service) GetPolicyRevision(ctx context.Context, name string, revision string) (chef.RevisionDetailsResponse, error)
- func (s Service) GetRole(ctx context.Context, name string) (*Role, error)
- func (s Service) GetRoles(ctx context.Context) (*RoleList, error)
- func (s Service) SearchNodes(ctx context.Context, q string) (*NodeList, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrCookbookNotFound = errors.New("cookbook not found") ErrCookbookVersionNotFound = errors.New("cookbook version not found") ErrCookbookFileNotFound = errors.New("cookbook file not found") ErrInternalServerError = errors.New("internal server error") )
View Source
var ( ErrDatabagNotFound = errors.New("databag not found") ErrDatabagItemNotFound = errors.New("databag item not found") )
View Source
var ErrEnvironmentNotFound = errors.New("environment not found")
View Source
var ErrPathNotFound = errors.New("attribute not found at path")
View Source
var ErrRoleNotFound = errors.New("role not found")
Functions ¶
func ReverseSlice ¶
func ReverseSlice[T comparable](s []T)
Types ¶
type CookbookListItem ¶
type CookbookListResult ¶
type CookbookListResult struct {
Cookbooks []CookbookListItem `json:"cookbooks"`
}
type CookbookMeta ¶
type CookbookMeta struct {
chef.CookbookMeta
}
type CookbookVersion ¶
type CookbookVersion struct {
Version string
}
type Node ¶
func (Node) GetEffectiveAttributeValue ¶
GetEffectiveAttributeValue returns the effective attribute value of a given path considering attribute precedence.
func (Node) MergeAttributes ¶
MergeAttributes returns the merged set of all node attributes taking attribute precedence into consideration. Ref: https://docs.chef.io/attribute_precedence/
type PolicyGroup ¶
type PolicyGroup struct {
chef.PolicyGroup
}
type Service ¶
type Service struct { Interface // contains filtered or unexported fields }
func (Service) GetCookbook ¶
GetCookbook should get the latest version of the cookbook
func (Service) GetCookbookVersion ¶
func (Service) GetCookbooks ¶
func (s Service) GetCookbooks(ctx context.Context) (*CookbookListResult, error)
func (Service) GetDatabagItemContent ¶
func (Service) GetDatabagItems ¶
func (Service) GetEnvironment ¶
func (Service) GetEnvironments ¶
func (Service) GetLatestCookbooks ¶
func (s Service) GetLatestCookbooks(ctx context.Context) (*CookbookListResult, error)
func (Service) GetPolicies ¶
func (Service) GetPolicyGroup ¶
func (Service) GetPolicyGroups ¶
func (Service) GetPolicyRevision ¶
Click to show internal directories.
Click to hide internal directories.