config

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveToFile

func SaveToFile(config *Config, filename string) error

Types

type Config

type Config struct {
	Organization string          `yaml:"organization"`
	OrgUnits     []OrgUnitConfig `yaml:"org_units,omitempty"`
	Users        []UserConfig    `yaml:"users,omitempty"`
	Groups       []GroupConfig   `yaml:"groups,omitempty"`
}

func LoadFromFile

func LoadFromFile(filename string) (*Config, error)

func (*Config) Validate

func (c *Config) Validate() error

type GroupConfig

type GroupConfig struct {
	Name        string         `yaml:"name"`
	Email       string         `yaml:"email"`
	Description string         `yaml:"description,omitempty"`
	Members     []MemberConfig `yaml:"members,omitempty"`
}

type MemberConfig

type MemberConfig struct {
	Email string `yaml:"email"`
	Role  string `yaml:"role,omitempty"`
}

type OrgUnitConfig

type OrgUnitConfig struct {
	Name              string `yaml:"name"`
	Description       string `yaml:"description,omitempty"`
	ParentOrgUnitPath string `yaml:"parent_org_unit_path,omitempty"`
	OrgUnitPath       string `yaml:"org_unit_path,omitempty"`
	BlockInheritance  bool   `yaml:"block_nheritance,omitempty"`
}

type UserConfig

type UserConfig struct {
	FirstName      string `yaml:"given_name"`
	LastName       string `yaml:"family_name"`
	PrimaryEmail   string `yaml:"primary_email"`
	SecondaryEmail string `yaml:"secondary_email,omitempty"`
	OrgUnitPath    string `yaml:"org_unit_path,omitempty"`
}

Jump to

Keyboard shortcuts

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