bootstrap

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2021 License: Apache-2.0 Imports: 12 Imported by: 1

Documentation

Index

Constants

View Source
const (
	AWSIAMGroupBootstrapper                      = "AWSIAMGroupBootstrapper"
	AWSIAMInstanceProfileControllers             = "AWSIAMInstanceProfileControllers"
	AWSIAMInstanceProfileControlPlane            = "AWSIAMInstanceProfileControlPlane"
	AWSIAMInstanceProfileNodes                   = "AWSIAMInstanceProfileNodes"
	AWSIAMRoleControllers                        = "AWSIAMRoleControllers"
	AWSIAMRoleControlPlane                       = "AWSIAMRoleControlPlane"
	AWSIAMRoleNodes                              = "AWSIAMRoleNodes"
	AWSIAMRoleEKSControlPlane                    = "AWSIAMRoleEKSControlPlane"
	AWSIAMRoleEKSNodegroup                       = "AWSIAMRoleEKSNodegroup"
	AWSIAMRoleEKSFargate                         = "AWSIAMRoleEKSFargate"
	AWSIAMUserBootstrapper                       = "AWSIAMUserBootstrapper"
	ControllersPolicy                 PolicyName = "AWSIAMManagedPolicyControllers"
	ControlPlanePolicy                PolicyName = "AWSIAMManagedPolicyCloudProviderControlPlane"
	NodePolicy                        PolicyName = "AWSIAMManagedPolicyCloudProviderNodes"
	CSIPolicy                         PolicyName = "AWSEBSCSIPolicyController"
)

Constants that define resources for a Template.

Variables

ManagedIAMPolicyNames slice of managed IAM policies.

Functions

func AWSArnAssumeRolePolicy added in v0.6.5

func AWSArnAssumeRolePolicy(identityID string) *v1alpha4.PolicyDocument

AWSArnAssumeRolePolicy will assume Policies using PolicyArns.

func AWSServiceAssumeRolePolicy added in v0.6.5

func AWSServiceAssumeRolePolicy(identityID string) *v1alpha4.PolicyDocument

AWSServiceAssumeRolePolicy will assume an AWS Service policy.

func AssumeRolePolicy added in v0.6.5

func AssumeRolePolicy(identityType v1alpha4.PrincipalType, principalIDs []string) *v1alpha4.PolicyDocument

AssumeRolePolicy will create a role session and pass session policies programmatically.

Types

type PolicyName

type PolicyName string

PolicyName defines the name of a managed IAM policy.

func (PolicyName) IsValid

func (p PolicyName) IsValid() bool

IsValid will check if a given policy name is valid. That is, it will check if the given policy name is one of the ManagedIAMPolicyNames.

type Template

type Template struct {
	Spec *bootstrapv1.AWSIAMConfigurationSpec
}

Template is an AWS CloudFormation template to bootstrap IAM policies, users and roles for use by Cluster API Provider AWS.

func NewTemplate

func NewTemplate() Template

NewTemplate will generate a new Template.

func (Template) ControllersPolicy added in v0.6.5

func (t Template) ControllersPolicy() *infrav1.PolicyDocument

ControllersPolicy will create a policy from a Template for AWS Controllers.

func (Template) GenerateManagedIAMPolicyDocuments

func (t Template) GenerateManagedIAMPolicyDocuments(policyDocDir string) error

GenerateManagedIAMPolicyDocuments generates JSON representation of policy documents for all ManagedIAMPolicy.

func (Template) GetPolicyDocFromPolicyName

func (t Template) GetPolicyDocFromPolicyName(policyName PolicyName) *v1alpha4.PolicyDocument

GetPolicyDocFromPolicyName returns a Template's policy document.

func (Template) NewManagedName

func (t Template) NewManagedName(name string) string

NewManagedName creates an IAM acceptable name prefixed with this Cluster API implementation's prefix.

func (Template) RenderCloudFormation

func (t Template) RenderCloudFormation() *cloudformation.Template

RenderCloudFormation will render and return a cloudformation Template.

Jump to

Keyboard shortcuts

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