grm

package
v0.3.2-rc01 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package grm helps with Google Resource Manager, aka Organizations, Folders, Projects and their role bindings

Index

Constants

View Source
const Retries = 5

Retries is the max number of read-modify-write cycles in case of concurrent policy changes detection

Variables

This section is empty.

Functions

This section is empty.

Types

type Bindings

type Bindings struct {
	Hosting struct {
		Org struct {
			CustomRoles []string `yaml:"orgCustomRoles"`
			Roles       []string `yaml:"orgRoles"`
		}
		Folder struct {
			CustomRoles []string `yaml:"orgCustomRoles"`
			Roles       []string `yaml:"orgRoles"`
		}
		Project struct {
			CustomRoles []string `yaml:"projectCustomRoles"`
			Roles       []string `yaml:"projectRoles"`
		}
	}
	Monitoring struct {
		Org struct {
			CustomRoles []string `yaml:"orgCustomRoles"`
			Roles       []string `yaml:"orgRoles"`
		}
	}
}

Bindings structure

type FolderDeployment

type FolderDeployment struct {
	Core *deploy.Core
}

FolderDeployment struct

func NewFolderDeployment

func NewFolderDeployment() *FolderDeployment

NewFolderDeployment create deployment structure

func (*FolderDeployment) Deploy

func (folderDeployment *FolderDeployment) Deploy() (err error)

Deploy FolderDeployment for now, only check the folder exist and is ACTIVE: It does NOT create the folder.

type OrgBindingsDeployment

type OrgBindingsDeployment struct {
	Artifacts struct {
		Member         string
		OrganizationID string `yaml:"organizationID"`
	}
	Core     *deploy.Core
	Settings struct {
		CustomRoles []string `yaml:"customRoles"`
		Roles       []string
	}
}

OrgBindingsDeployment struct

func NewOrgBindingsDeployment

func NewOrgBindingsDeployment() *OrgBindingsDeployment

NewOrgBindingsDeployment create deployment structure

func (*OrgBindingsDeployment) Deploy

func (orgBindingsDeployment *OrgBindingsDeployment) Deploy() (err error)

Deploy use retries on a read-modify-write cycle

type ProjectBindingsDeployment

type ProjectBindingsDeployment struct {
	Artifacts struct {
		Member    string
		ProjectID string `yaml:"projectID"`
	}
	Core     *deploy.Core
	Settings struct {
		CustomRoles []string `yaml:"customRoles"`
		Roles       []string
	}
}

ProjectBindingsDeployment struct

func NewProjectBindingsDeployment

func NewProjectBindingsDeployment() *ProjectBindingsDeployment

NewProjectBindingsDeployment create deployment structure

func (*ProjectBindingsDeployment) Deploy

func (projectBindingsDeployment *ProjectBindingsDeployment) Deploy() (err error)

Deploy use retries on a read-modify-write cycle

type ProjectDeployment

type ProjectDeployment struct {
	Core *deploy.Core
}

ProjectDeployment struct

func NewProjectDeployment

func NewProjectDeployment() *ProjectDeployment

NewProjectDeployment create deployment structure

func (*ProjectDeployment) Deploy

func (projectDeployment *ProjectDeployment) Deploy() (err error)

Deploy ProjectDeployment check if a project exist, try to create it is missing and role projectCreator as been delegated (optional)

Jump to

Keyboard shortcuts

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