orbiter

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2020 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AdaptReadSecret

func AdaptReadSecret(path []string, deps map[string]ReadSecretFunc, mapping map[string]*Secret) (string, error)

func AdaptWriteSecret

func AdaptWriteSecret(path []string, value string, deps map[string]WriteSecretFunc, mapping map[string]*Secret) error

func Destroy

func Destroy(gitClient *git.Client, adapt AdaptFunc) error

func ReadSecret

func ReadSecret(gitClient *git.Client, adapt AdaptFunc, path string) (string, error)

func Takeoff

func Takeoff(ctx context.Context, logger logging.Logger, gitClient *git.Client, orbiterCommit string, masterkey string, recur bool, adapt AdaptFunc) func()

func WriteSecret

func WriteSecret(gitClient *git.Client, adapt AdaptFunc, path, value string) error

Types

type AdaptFunc

type AdaptFunc func(desired *Tree, secrets *Tree, current *Tree) (EnsureFunc, DestroyFunc, ReadSecretFunc, WriteSecretFunc, error)

type Common

type Common struct {
	Kind    string
	Version string
}

type DestroyFunc

type DestroyFunc func() error

type EnsureFunc

type EnsureFunc func(psf PushSecretsFunc, nodeAgentsCurrent map[string]*common.NodeAgentCurrent, nodeAgentsDesired map[string]*common.NodeAgentSpec) (err error)

type Orb

type Orb struct {
	URL       string
	Repokey   string
	Masterkey string
}

type PushSecretsFunc

type PushSecretsFunc func() error

type ReadSecretFunc

type ReadSecretFunc func(path []string) (string, error)

type Secret

type Secret struct {
	Encryption string
	Encoding   string
	Value      string
	Masterkey  string `yaml:"-"`
}

func (*Secret) MarshalYAML

func (s *Secret) MarshalYAML() (interface{}, error)

func (*Secret) UnmarshalYAML

func (s *Secret) UnmarshalYAML(node *yaml.Node) error

type Tree

type Tree struct {
	Common   *Common `yaml:",inline"`
	Original yaml.Node
	Parsed   interface{} `yaml:",inline"`
}

func (*Tree) MarshalYAML

func (c *Tree) MarshalYAML() (interface{}, error)

func (*Tree) UnmarshalYAML

func (c *Tree) UnmarshalYAML(node *yaml.Node) error

type WriteSecretFunc

type WriteSecretFunc func(path []string, value string) error

Jump to

Keyboard shortcuts

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