client

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	ParagliderControllerClient
	ControllerAddress string
}

func (*Client) AddPermitListRules

func (c *Client) AddPermitListRules(namespace string, cloud string, resourceName string, rules []*paragliderpb.PermitListRule) error

Add permit list rules to a resource

func (*Client) CreateResource

func (c *Client) CreateResource(namespace string, cloud string, resourceName string, resource *paragliderpb.ResourceDescriptionString) (map[string]string, error)

Create a resource

func (*Client) DeletePermitListRules

func (c *Client) DeletePermitListRules(namespace string, cloud string, resourceName string, rules []string) error

Delete permit list rules from a resource

func (*Client) DeleteTag

func (c *Client) DeleteTag(tag string) error

Delete an entire tag and all its member associations under it

func (*Client) DeleteTagMembers

func (c *Client) DeleteTagMembers(tag string, member string) error

Delete member from a tag

func (*Client) GetPermitList

func (c *Client) GetPermitList(namespace string, cloud string, resourceName string) ([]*paragliderpb.PermitListRule, error)

Get a permit list for a resource

func (*Client) GetTag

func (c *Client) GetTag(tag string) (*tagservicepb.TagMapping, error)

Get the members of a tag

func (*Client) ListNamespaces

func (c *Client) ListNamespaces() (map[string][]config.CloudDeployment, error)

List all configured namespaces

func (*Client) ListTags

func (c *Client) ListTags() ([]*tagservicepb.TagMapping, error)

ListTags lists all tags and their mappings

func (*Client) ResolveTag

func (c *Client) ResolveTag(tag string) ([]*tagservicepb.TagMapping, error)

Resolve a tag down to all IP/URI members

func (*Client) SetTag

func (c *Client) SetTag(tag string, tagMapping *tagservicepb.TagMapping) error

Set a tag as a member of a group or as a mapping to a URI/IP

type ParagliderControllerClient

type ParagliderControllerClient interface {
	GetPermitList(namespace string, cloud string, resourceName string) ([]*paragliderpb.PermitListRule, error)
	AddPermitListRules(namespace string, cloud string, resourceName string, rules []*paragliderpb.PermitListRule) error
	DeletePermitListRules(namespace string, cloud string, resourceName string, rules []string) error
	CreateResource(namespace string, cloud string, resourceName string, resource *paragliderpb.ResourceDescriptionString) (map[string]string, error)
	GetTag(tag string) (*tagservicepb.TagMapping, error)
	ResolveTag(tag string) ([]*tagservicepb.TagMapping, error)
	SetTag(tag string, tagMapping *tagservicepb.TagMapping) error
	DeleteTag(tag string) error
	DeleteTagMembers(tag string, members []string) error
	ListNamespaces() (map[string][]config.CloudDeployment, error)
}

Jump to

Keyboard shortcuts

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