puppet

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package puppet provides an interface to interact with the Cloud VPS Puppet ENC API, which makes it possible to assign Puppet roles and hiera data for instances, prefixes or for the entire project.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Client *gophercloud.ServiceClient
}

Client interacts with the Cloud VPS Puppet ENC API.

func (Client) CreatePrefix

func (client Client) CreatePrefix(prefix Prefix) (r CreatePrefixResult)

func (Client) DeletePrefix

func (client Client) DeletePrefix(prefix Prefix) (r DeletePrefixResult)

func (Client) GetPrefixById

func (client Client) GetPrefixById(id int) (r GetPrefixResult)

func (Client) UpdatePrefix

func (client Client) UpdatePrefix(prefix Prefix) (r UpdatePrefixResult)

type CreatePrefixResult

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

func (CreatePrefixResult) Extract

func (r CreatePrefixResult) Extract() (*Prefix, error)

type DeletePrefixResult

type DeletePrefixResult struct {
	gophercloud.Result
}

type GetPrefixResult

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

func (GetPrefixResult) Extract

func (r GetPrefixResult) Extract() (*Prefix, error)

type Prefix

type Prefix struct {
	// Id is the internal identifier of this prefix.
	Id int `json:"id"`

	// Name is the name of this prefix.
	Name string `json:"prefix"`

	// Roles is the list of Puppet roles assigned to this role.
	Roles []string `json:"roles"`

	// Hiera is the map of hiera data applied to this role.
	Hiera map[string]any `json:"hiera"`
}

Prefix represents a "prefix" (which in reality represents a single instance, all instances whose name start with a certain prefix or all instances in the entire project) that can have roles and hiera data assigned to it.

type UpdatePrefixResult

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

func (UpdatePrefixResult) Extract

func (r UpdatePrefixResult) Extract() (*Prefix, error)

Jump to

Keyboard shortcuts

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