pub struct AwsEc2IamInstanceProfile {
pub region: String,
pub existing_instance_profile_key_or_name: Option<String>,
pub policy_arns: Vec<String>,
/* private fields */
}Expand description
Represents a IAM role, IAM policy attachments, and instance profile for one or multiple EC2 instances.
Fields§
§region: String§existing_instance_profile_key_or_name: Option<String>§policy_arns: Vec<String>Implementations§
Source§impl AwsEc2IamInstanceProfile
impl AwsEc2IamInstanceProfile
Sourcepub fn new(
region: impl Into<String>,
existing_instance_profile_name: Option<String>,
) -> Self
pub fn new( region: impl Into<String>, existing_instance_profile_name: Option<String>, ) -> Self
Creates a new instance. If existing_instance_profile_name is Some, that will be used as the instance
profile name which must already exist in the AWS account.
Sourcepub fn add_policy_arn(self, policy_arn: impl Into<String>) -> Self
pub fn add_policy_arn(self, policy_arn: impl Into<String>) -> Self
Permits the given ARN.
Sourcepub fn add_cloudwatch_agent_server_policy_arn(self) -> Self
pub fn add_cloudwatch_agent_server_policy_arn(self) -> Self
Enables running and emitting telemetry via the CloudWatch agent.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AwsEc2IamInstanceProfile
impl RefUnwindSafe for AwsEc2IamInstanceProfile
impl Send for AwsEc2IamInstanceProfile
impl Sync for AwsEc2IamInstanceProfile
impl Unpin for AwsEc2IamInstanceProfile
impl UnwindSafe for AwsEc2IamInstanceProfile
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> ToSinkBuild for T
impl<T> ToSinkBuild for T
§fn iter_to_sink_build(self) -> SendIterBuild<Self>
fn iter_to_sink_build(self) -> SendIterBuild<Self>
§fn stream_to_sink_build(self) -> SendStreamBuild<Self>where
Self: Sized + Stream,
fn stream_to_sink_build(self) -> SendStreamBuild<Self>where
Self: Sized + Stream,
Starts a [
SinkBuild] adaptor chain to send all items from self as a [Stream].