Class AutonomousDatabaseSecretsManagerIntegration


  • public class AutonomousDatabaseSecretsManagerIntegration
    extends com.pulumi.resources.CustomResource
    Manages the Oracle Database@AWS Autonomous Database Serverless integration with AWS Secrets Manager. The resource provisions an Oracle-managed service role that can assume a customer-managed role to read an administrator-password secret. > **Note:** This integration is shared by all databases in the AWS account and Region. Creating this resource manages the existing integration if it is already enabled. Destroying this resource disables the integration for the entire account and Region, which can disrupt databases outside this Terraform configuration that use AWS Secrets Manager credentials. Manage the integration in only one Terraform configuration and coordinate changes with all database owners that depend on it. For accounts with a resource anchor, creating or destroying this resource preserves an existing OCI identity domain. If no identity domain exists, the service creates one when enabling or disabling the integration. This resource does not delete the identity domain. Create the customer-managed IAM role separately. Its trust policy must allow the exported `roleArn` to assume it, and its permissions must grant access to the selected secret. See the [AWS Secrets Manager documentation](https://docs.aws.amazon.com/secretsmanager/latest/userguide/auth-and-access.html) for IAM permission guidance. ## Example Usage ### Basic Usage
     
     package generated_program;
     
     import com.pulumi.Context;
     import com.pulumi.Pulumi;
     import com.pulumi.core.Output;
     import com.pulumi.aws.odb.AutonomousDatabaseSecretsManagerIntegration;
     import java.util.ArrayList;
     import java.util.Arrays;
     import java.util.Map;
     import java.io.File;
     import java.nio.file.Files;
     import java.nio.file.Paths;
     
     public class App {
         public static void main(String[] args) {
             Pulumi.run(App::stack);
         }
     
         public static void stack(Context ctx) {
             var example = new AutonomousDatabaseSecretsManagerIntegration("example");
     
             ctx.export("adbsSecretsManagerServiceRoleArn", example.roleArn());
         }
     }
     
     
    ## Import ### Identity Schema #### Required #### Optional * `accountId` (String) AWS Account where this resource is managed. * `region` (String) Region where this resource is managed. Using `pulumi import`, import the integration using its Region. For example: ```sh $ pulumi import aws:odb/autonomousDatabaseSecretsManagerIntegration:AutonomousDatabaseSecretsManagerIntegration example us-east-1 ```
    • Constructor Detail

      • AutonomousDatabaseSecretsManagerIntegration

        public AutonomousDatabaseSecretsManagerIntegration​(java.lang.String name)
        Parameters:
        name - The _unique_ name of the resulting resource.
      • AutonomousDatabaseSecretsManagerIntegration

        public AutonomousDatabaseSecretsManagerIntegration​(java.lang.String name,
                                                           @Nullable
                                                           AutonomousDatabaseSecretsManagerIntegrationArgs args)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
      • AutonomousDatabaseSecretsManagerIntegration

        public AutonomousDatabaseSecretsManagerIntegration​(java.lang.String name,
                                                           @Nullable
                                                           AutonomousDatabaseSecretsManagerIntegrationArgs args,
                                                           @Nullable
                                                           com.pulumi.resources.CustomResourceOptions options)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
        options - A bag of options that control this resource's behavior.
    • Method Detail

      • region

        public com.pulumi.core.Output<java.lang.String> region()
        Returns:
        Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
      • roleArn

        public com.pulumi.core.Output<java.lang.String> roleArn()
        Returns:
        ARN of the Oracle-managed service role that assumes the customer-managed IAM role.
      • status

        public com.pulumi.core.Output<java.lang.String> status()
        Returns:
        Current lifecycle status of the service role.
      • statusReason

        public com.pulumi.core.Output<java.lang.String> statusReason()
        Returns:
        Additional lifecycle-status information, if available.
      • get

        public static AutonomousDatabaseSecretsManagerIntegration get​(java.lang.String name,
                                                                      com.pulumi.core.Output<java.lang.String> id,
                                                                      @Nullable
                                                                      AutonomousDatabaseSecretsManagerIntegrationState state,
                                                                      @Nullable
                                                                      com.pulumi.resources.CustomResourceOptions options)
        Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
        Parameters:
        name - The _unique_ name of the resulting resource.
        id - The _unique_ provider ID of the resource to lookup.
        state -
        options - Optional settings to control the behavior of the CustomResource.