iamexampledata

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: May 14, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package iamexampledata provides predefined example data for the IAM example service.

Index

Constants

View Source
const (
	RootAdminMember                       = "user:root"
	EinrideAdminMember                    = "user:einride-admin"
	EinrideGothenburgFreightPlannerMember = "user:einride-gothenburg-freight-planner"
	EinrideBatcaveWorkerMember            = "user:einride-batcave-worker"
)

Example IAM policy members.

Variables

This section is empty.

Functions

func BootstrapRootAdmin

func BootstrapRootAdmin(ctx context.Context, spannerClient *spanner.Client) error

BootstrapRootAdmin bootstraps an IAM database with RootAdminMember as iamexamplev1.FreightServiceServer root admin.

func Einride

func Einride() *iamexamplev1.Shipper

Einride returns the Einride example shipper.

func EinrideBatcave

func EinrideBatcave() *iamexamplev1.Site

EinrideBatcave returns an iamexamplev1.Site representing Einride's Batcave.

func EinrideBatcaveSetIamPolicyRequest

func EinrideBatcaveSetIamPolicyRequest() *iam.SetIamPolicyRequest

EinrideBatcaveSetIamPolicyRequest returns an iam.SetIamPolicyRequest for the Einride Batcave site resource.

func EinrideGothenburgOffice

func EinrideGothenburgOffice() *iamexamplev1.Site

EinrideGothenburgOffice returns an iamexamplev1.Site representing Einride's Gothenburg office.

func EinrideGothenburgOfficeSetIamPolicyRequest

func EinrideGothenburgOfficeSetIamPolicyRequest() *iam.SetIamPolicyRequest

EinrideGothenburgOfficeSetIamPolicyRequest returns an iam.SetIamPolicyRequest for the Einride Gothenburg Office site resource.

func EinrideSetIamPolicyRequest

func EinrideSetIamPolicyRequest() *iam.SetIamPolicyRequest

EinrideSetIamPolicyRequest returns an iam.SetIamPolicyRequest for the Einride shipper resource.

func EinrideStockholmOffice

func EinrideStockholmOffice() *iamexamplev1.Site

EinrideStockholmOffice returns an iamexamplev1.Site representing Einride's Stockholm office.

func InitializeResources

func InitializeResources(ctx context.Context, server iamexamplev1.FreightServiceServer) error

InitializeResources uses an iamexamplev1.FreightServiceClient to initialize the set of example resources.

func PredefinedRoles

func PredefinedRoles() *iamv1.Roles

PredefinedRoles returns the pre-defined roles for iamexamplev1.FreightServiceServer.

Types

This section is empty.

Jump to

Keyboard shortcuts

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