Class: AWSCDK::EKS::CfnAccessEntry::AccessPolicyProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
eks/cfn_access_entry.rb

Overview

An access policy includes permissions that allow Amazon EKS to authorize an IAM principal to work with Kubernetes objects on your cluster.

The policies are managed by Amazon EKS, but they're not IAM policies. You can't view the permissions in the policies using the API. The permissions for many of the policies are similar to the Kubernetes cluster-admin , admin , edit , and view cluster roles. For more information about these cluster roles, see User-facing roles in the Kubernetes documentation. To view the contents of the policies, see Access policy permissions in the Amazon EKS User Guide .

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(access_scope:, policy_arn:) ⇒ AccessPolicyProperty

Returns a new instance of AccessPolicyProperty.

Parameters:



602
603
604
605
606
607
# File 'eks/cfn_access_entry.rb', line 602

def initialize(access_scope:, policy_arn:)
  @access_scope = access_scope.is_a?(Hash) ? ::AWSCDK::EKS::CfnAccessEntry::AccessScopeProperty.new(**access_scope.transform_keys(&:to_sym)) : access_scope
  Jsii::Type.check_type(@access_scope, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19la3MuQ2ZuQWNjZXNzRW50cnkuQWNjZXNzU2NvcGVQcm9wZXJ0eSJ9XX19")), "accessScope")
  @policy_arn = policy_arn
  Jsii::Type.check_type(@policy_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "policyArn")
end

Instance Attribute Details

#access_scopeAWSCDK::IResolvable, AWSCDK::EKS::CfnAccessEntry::AccessScopeProperty (readonly)

The scope of an AccessPolicy that's associated to an AccessEntry .



613
614
615
# File 'eks/cfn_access_entry.rb', line 613

def access_scope
  @access_scope
end

#policy_arnString (readonly)

The ARN of the access policy.



618
619
620
# File 'eks/cfn_access_entry.rb', line 618

def policy_arn
  @policy_arn
end

Class Method Details

.jsii_propertiesObject



620
621
622
623
624
625
# File 'eks/cfn_access_entry.rb', line 620

def self.jsii_properties
  {
    :access_scope => "accessScope",
    :policy_arn => "policyArn",
  }
end

Instance Method Details

#to_jsiiObject



627
628
629
630
631
632
633
634
# File 'eks/cfn_access_entry.rb', line 627

def to_jsii
  result = {}
  result.merge!({
    "accessScope" => @access_scope,
    "policyArn" => @policy_arn,
  })
  result.compact
end