Struct aws_sdk_iam::client::fluent_builders::CreateServiceLinkedRole
source · [−]pub struct CreateServiceLinkedRole { /* private fields */ }
Expand description
Fluent builder constructing a request to CreateServiceLinkedRole
.
Creates an IAM role that is linked to a specific Amazon Web Services service. The service controls the attached policies and when the role can be deleted. This helps ensure that the service is not broken by an unexpectedly changed or deleted role, which could put your Amazon Web Services resources into an unknown state. Allowing the service to control the role helps improve service stability and proper cleanup when a service and its role are no longer needed. For more information, see Using service-linked roles in the IAM User Guide.
To attach a policy to this service-linked role, you must make the request using the Amazon Web Services service that depends on this role.
Implementations
sourceimpl CreateServiceLinkedRole
impl CreateServiceLinkedRole
sourcepub async fn send(
self
) -> Result<CreateServiceLinkedRoleOutput, SdkError<CreateServiceLinkedRoleError>>
pub async fn send(
self
) -> Result<CreateServiceLinkedRoleOutput, SdkError<CreateServiceLinkedRoleError>>
Sends the request and returns the response.
If an error occurs, an SdkError
will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
sourcepub fn aws_service_name(self, input: impl Into<String>) -> Self
pub fn aws_service_name(self, input: impl Into<String>) -> Self
The service principal for the Amazon Web Services service to which this role is attached. You use a string similar to a URL but without the http:// in front. For example: elasticbeanstalk.amazonaws.com
.
Service principals are unique and case-sensitive. To find the exact service principal for your service-linked role, see Amazon Web Services services that work with IAM in the IAM User Guide. Look for the services that have Yes in the Service-Linked Role column. Choose the Yes link to view the service-linked role documentation for that service.
sourcepub fn set_aws_service_name(self, input: Option<String>) -> Self
pub fn set_aws_service_name(self, input: Option<String>) -> Self
The service principal for the Amazon Web Services service to which this role is attached. You use a string similar to a URL but without the http:// in front. For example: elasticbeanstalk.amazonaws.com
.
Service principals are unique and case-sensitive. To find the exact service principal for your service-linked role, see Amazon Web Services services that work with IAM in the IAM User Guide. Look for the services that have Yes in the Service-Linked Role column. Choose the Yes link to view the service-linked role documentation for that service.
sourcepub fn description(self, input: impl Into<String>) -> Self
pub fn description(self, input: impl Into<String>) -> Self
The description of the role.
sourcepub fn set_description(self, input: Option<String>) -> Self
pub fn set_description(self, input: Option<String>) -> Self
The description of the role.
sourcepub fn custom_suffix(self, input: impl Into<String>) -> Self
pub fn custom_suffix(self, input: impl Into<String>) -> Self
A string that you provide, which is combined with the service-provided prefix to form the complete role name. If you make multiple requests for the same service, then you must supply a different CustomSuffix
for each request. Otherwise the request fails with a duplicate role name error. For example, you could add -1
or -debug
to the suffix.
Some services do not support the CustomSuffix
parameter. If you provide an optional suffix and the operation fails, try the operation again without the suffix.
sourcepub fn set_custom_suffix(self, input: Option<String>) -> Self
pub fn set_custom_suffix(self, input: Option<String>) -> Self
A string that you provide, which is combined with the service-provided prefix to form the complete role name. If you make multiple requests for the same service, then you must supply a different CustomSuffix
for each request. Otherwise the request fails with a duplicate role name error. For example, you could add -1
or -debug
to the suffix.
Some services do not support the CustomSuffix
parameter. If you provide an optional suffix and the operation fails, try the operation again without the suffix.
Trait Implementations
sourceimpl Clone for CreateServiceLinkedRole
impl Clone for CreateServiceLinkedRole
sourcefn clone(&self) -> CreateServiceLinkedRole
fn clone(&self) -> CreateServiceLinkedRole
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl !RefUnwindSafe for CreateServiceLinkedRole
impl Send for CreateServiceLinkedRole
impl Sync for CreateServiceLinkedRole
impl Unpin for CreateServiceLinkedRole
impl !UnwindSafe for CreateServiceLinkedRole
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more