1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Adm
  5. getRemediationRuns
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

oci.Adm.getRemediationRuns

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

    This data source provides the list of Remediation Runs in Oracle Cloud Infrastructure Adm service.

    Returns a list of remediation runs contained by a compartment. The query parameter compartmentId is required unless the query parameter id is specified.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testRemediationRuns = oci.Adm.getRemediationRuns({
        compartmentId: compartmentId,
        displayName: remediationRunDisplayName,
        id: remediationRunId,
        remediationRecipeId: testRemediationRecipe.id,
        state: remediationRunState,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_remediation_runs = oci.Adm.get_remediation_runs(compartment_id=compartment_id,
        display_name=remediation_run_display_name,
        id=remediation_run_id,
        remediation_recipe_id=test_remediation_recipe["id"],
        state=remediation_run_state)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Adm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Adm.GetRemediationRuns(ctx, &adm.GetRemediationRunsArgs{
    			CompartmentId:       pulumi.StringRef(compartmentId),
    			DisplayName:         pulumi.StringRef(remediationRunDisplayName),
    			Id:                  pulumi.StringRef(remediationRunId),
    			RemediationRecipeId: pulumi.StringRef(testRemediationRecipe.Id),
    			State:               pulumi.StringRef(remediationRunState),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testRemediationRuns = Oci.Adm.GetRemediationRuns.Invoke(new()
        {
            CompartmentId = compartmentId,
            DisplayName = remediationRunDisplayName,
            Id = remediationRunId,
            RemediationRecipeId = testRemediationRecipe.Id,
            State = remediationRunState,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Adm.AdmFunctions;
    import com.pulumi.oci.Adm.inputs.GetRemediationRunsArgs;
    import java.util.List;
    import java.util.ArrayList;
    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) {
            final var testRemediationRuns = AdmFunctions.getRemediationRuns(GetRemediationRunsArgs.builder()
                .compartmentId(compartmentId)
                .displayName(remediationRunDisplayName)
                .id(remediationRunId)
                .remediationRecipeId(testRemediationRecipe.id())
                .state(remediationRunState)
                .build());
    
        }
    }
    
    variables:
      testRemediationRuns:
        fn::invoke:
          Function: oci:Adm:getRemediationRuns
          Arguments:
            compartmentId: ${compartmentId}
            displayName: ${remediationRunDisplayName}
            id: ${remediationRunId}
            remediationRecipeId: ${testRemediationRecipe.id}
            state: ${remediationRunState}
    

    Using getRemediationRuns

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getRemediationRuns(args: GetRemediationRunsArgs, opts?: InvokeOptions): Promise<GetRemediationRunsResult>
    function getRemediationRunsOutput(args: GetRemediationRunsOutputArgs, opts?: InvokeOptions): Output<GetRemediationRunsResult>
    def get_remediation_runs(compartment_id: Optional[str] = None,
                             display_name: Optional[str] = None,
                             filters: Optional[Sequence[_adm.GetRemediationRunsFilter]] = None,
                             id: Optional[str] = None,
                             remediation_recipe_id: Optional[str] = None,
                             state: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetRemediationRunsResult
    def get_remediation_runs_output(compartment_id: Optional[pulumi.Input[str]] = None,
                             display_name: Optional[pulumi.Input[str]] = None,
                             filters: Optional[pulumi.Input[Sequence[pulumi.Input[_adm.GetRemediationRunsFilterArgs]]]] = None,
                             id: Optional[pulumi.Input[str]] = None,
                             remediation_recipe_id: Optional[pulumi.Input[str]] = None,
                             state: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetRemediationRunsResult]
    func GetRemediationRuns(ctx *Context, args *GetRemediationRunsArgs, opts ...InvokeOption) (*GetRemediationRunsResult, error)
    func GetRemediationRunsOutput(ctx *Context, args *GetRemediationRunsOutputArgs, opts ...InvokeOption) GetRemediationRunsResultOutput

    > Note: This function is named GetRemediationRuns in the Go SDK.

    public static class GetRemediationRuns 
    {
        public static Task<GetRemediationRunsResult> InvokeAsync(GetRemediationRunsArgs args, InvokeOptions? opts = null)
        public static Output<GetRemediationRunsResult> Invoke(GetRemediationRunsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetRemediationRunsResult> getRemediationRuns(GetRemediationRunsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Adm/getRemediationRuns:getRemediationRuns
      arguments:
        # arguments dictionary

    The following arguments are supported:

    CompartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    DisplayName string
    A filter to return only resources that match the entire display name given.
    Filters List<GetRemediationRunsFilter>
    Id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    RemediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    State string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    CompartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    DisplayName string
    A filter to return only resources that match the entire display name given.
    Filters []GetRemediationRunsFilter
    Id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    RemediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    State string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    compartmentId String
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    displayName String
    A filter to return only resources that match the entire display name given.
    filters List<GetRemediationRunsFilter>
    id String
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId String
    A filter to return only resources that match the specified Remediation Recipe identifier.
    state String
    A filter to return only Remediation Runs that match the specified lifecycleState.
    compartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    displayName string
    A filter to return only resources that match the entire display name given.
    filters GetRemediationRunsFilter[]
    id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    state string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    compartment_id str
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    display_name str
    A filter to return only resources that match the entire display name given.
    filters Sequence[adm.GetRemediationRunsFilter]
    id str
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediation_recipe_id str
    A filter to return only resources that match the specified Remediation Recipe identifier.
    state str
    A filter to return only Remediation Runs that match the specified lifecycleState.
    compartmentId String
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    displayName String
    A filter to return only resources that match the entire display name given.
    filters List<Property Map>
    id String
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId String
    A filter to return only resources that match the specified Remediation Recipe identifier.
    state String
    A filter to return only Remediation Runs that match the specified lifecycleState.

    getRemediationRuns Result

    The following output properties are available:

    RemediationRunCollections List<GetRemediationRunsRemediationRunCollection>
    The list of remediation_run_collection.
    CompartmentId string
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    DisplayName string
    The name of the remediation run.
    Filters List<GetRemediationRunsFilter>
    Id string
    The Oracle Cloud Identifier (OCID) of the remediation run.
    RemediationRecipeId string
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    State string
    The current lifecycle state of the remediation run.
    RemediationRunCollections []GetRemediationRunsRemediationRunCollection
    The list of remediation_run_collection.
    CompartmentId string
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    DisplayName string
    The name of the remediation run.
    Filters []GetRemediationRunsFilter
    Id string
    The Oracle Cloud Identifier (OCID) of the remediation run.
    RemediationRecipeId string
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    State string
    The current lifecycle state of the remediation run.
    remediationRunCollections List<GetRemediationRunsRemediationRunCollection>
    The list of remediation_run_collection.
    compartmentId String
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    displayName String
    The name of the remediation run.
    filters List<GetRemediationRunsFilter>
    id String
    The Oracle Cloud Identifier (OCID) of the remediation run.
    remediationRecipeId String
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    state String
    The current lifecycle state of the remediation run.
    remediationRunCollections GetRemediationRunsRemediationRunCollection[]
    The list of remediation_run_collection.
    compartmentId string
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    displayName string
    The name of the remediation run.
    filters GetRemediationRunsFilter[]
    id string
    The Oracle Cloud Identifier (OCID) of the remediation run.
    remediationRecipeId string
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    state string
    The current lifecycle state of the remediation run.
    remediation_run_collections Sequence[adm.GetRemediationRunsRemediationRunCollection]
    The list of remediation_run_collection.
    compartment_id str
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    display_name str
    The name of the remediation run.
    filters Sequence[adm.GetRemediationRunsFilter]
    id str
    The Oracle Cloud Identifier (OCID) of the remediation run.
    remediation_recipe_id str
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    state str
    The current lifecycle state of the remediation run.
    remediationRunCollections List<Property Map>
    The list of remediation_run_collection.
    compartmentId String
    The compartment Oracle Cloud Identifier (OCID) of the remediation run.
    displayName String
    The name of the remediation run.
    filters List<Property Map>
    id String
    The Oracle Cloud Identifier (OCID) of the remediation run.
    remediationRecipeId String
    The Oracle Cloud Identifier (OCID) of the Remediation Recipe.
    state String
    The current lifecycle state of the remediation run.

    Supporting Types

    GetRemediationRunsFilter

    Name string
    Values List<string>
    Regex bool
    Name string
    Values []string
    Regex bool
    name String
    values List<String>
    regex Boolean
    name string
    values string[]
    regex boolean
    name str
    values Sequence[str]
    regex bool
    name String
    values List<String>
    regex Boolean

    GetRemediationRunsRemediationRunCollection

    GetRemediationRunsRemediationRunCollectionItem

    CompartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    CurrentStageType string
    The type of the current stage of the remediation run.
    DefinedTags Dictionary<string, string>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    DisplayName string
    A filter to return only resources that match the entire display name given.
    FreeformTags Dictionary<string, string>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    Id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    RemediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    RemediationRunSource string
    The source that triggered the Remediation Recipe.
    Stages List<GetRemediationRunsRemediationRunCollectionItemStage>
    The list of remediation run stage summaries.
    State string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    SystemTags Dictionary<string, string>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    TimeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    TimeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    TimeUpdated string
    The date and time the remediation run was last updated (formatted according to RFC3339).
    CompartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    CurrentStageType string
    The type of the current stage of the remediation run.
    DefinedTags map[string]string
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    DisplayName string
    A filter to return only resources that match the entire display name given.
    FreeformTags map[string]string
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    Id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    RemediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    RemediationRunSource string
    The source that triggered the Remediation Recipe.
    Stages []GetRemediationRunsRemediationRunCollectionItemStage
    The list of remediation run stage summaries.
    State string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    SystemTags map[string]string
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    TimeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    TimeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    TimeUpdated string
    The date and time the remediation run was last updated (formatted according to RFC3339).
    compartmentId String
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    currentStageType String
    The type of the current stage of the remediation run.
    definedTags Map<String,String>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName String
    A filter to return only resources that match the entire display name given.
    freeformTags Map<String,String>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    id String
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId String
    A filter to return only resources that match the specified Remediation Recipe identifier.
    remediationRunSource String
    The source that triggered the Remediation Recipe.
    stages List<GetRemediationRunsRemediationRunCollectionItemStage>
    The list of remediation run stage summaries.
    state String
    A filter to return only Remediation Runs that match the specified lifecycleState.
    systemTags Map<String,String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished String
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted String
    The date and time of the start of the remediation run (formatted according to RFC3339).
    timeUpdated String
    The date and time the remediation run was last updated (formatted according to RFC3339).
    compartmentId string
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    currentStageType string
    The type of the current stage of the remediation run.
    definedTags {[key: string]: string}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName string
    A filter to return only resources that match the entire display name given.
    freeformTags {[key: string]: string}
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    id string
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId string
    A filter to return only resources that match the specified Remediation Recipe identifier.
    remediationRunSource string
    The source that triggered the Remediation Recipe.
    stages GetRemediationRunsRemediationRunCollectionItemStage[]
    The list of remediation run stage summaries.
    state string
    A filter to return only Remediation Runs that match the specified lifecycleState.
    systemTags {[key: string]: string}
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    timeUpdated string
    The date and time the remediation run was last updated (formatted according to RFC3339).
    compartment_id str
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    current_stage_type str
    The type of the current stage of the remediation run.
    defined_tags Mapping[str, str]
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    display_name str
    A filter to return only resources that match the entire display name given.
    freeform_tags Mapping[str, str]
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    id str
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediation_recipe_id str
    A filter to return only resources that match the specified Remediation Recipe identifier.
    remediation_run_source str
    The source that triggered the Remediation Recipe.
    stages Sequence[adm.GetRemediationRunsRemediationRunCollectionItemStage]
    The list of remediation run stage summaries.
    state str
    A filter to return only Remediation Runs that match the specified lifecycleState.
    system_tags Mapping[str, str]
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    time_created str
    The creation date and time of the remediation run (formatted according to RFC3339).
    time_finished str
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    time_started str
    The date and time of the start of the remediation run (formatted according to RFC3339).
    time_updated str
    The date and time the remediation run was last updated (formatted according to RFC3339).
    compartmentId String
    A filter to return only resources that belong to the specified compartment identifier. Required only if the id query param is not specified.
    currentStageType String
    The type of the current stage of the remediation run.
    definedTags Map<String>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName String
    A filter to return only resources that match the entire display name given.
    freeformTags Map<String>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    id String
    A filter to return only resources that match the specified identifier. Required only if the compartmentId query parameter is not specified.
    remediationRecipeId String
    A filter to return only resources that match the specified Remediation Recipe identifier.
    remediationRunSource String
    The source that triggered the Remediation Recipe.
    stages List<Property Map>
    The list of remediation run stage summaries.
    state String
    A filter to return only Remediation Runs that match the specified lifecycleState.
    systemTags Map<String>
    Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished String
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted String
    The date and time of the start of the remediation run (formatted according to RFC3339).
    timeUpdated String
    The date and time the remediation run was last updated (formatted according to RFC3339).

    GetRemediationRunsRemediationRunCollectionItemStage

    Summary string
    Information about the current step within the given stage.
    TimeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    TimeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    TimeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    Type string
    The type of stage.
    Summary string
    Information about the current step within the given stage.
    TimeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    TimeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    TimeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    Type string
    The type of stage.
    summary String
    Information about the current step within the given stage.
    timeCreated String
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished String
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted String
    The date and time of the start of the remediation run (formatted according to RFC3339).
    type String
    The type of stage.
    summary string
    Information about the current step within the given stage.
    timeCreated string
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished string
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted string
    The date and time of the start of the remediation run (formatted according to RFC3339).
    type string
    The type of stage.
    summary str
    Information about the current step within the given stage.
    time_created str
    The creation date and time of the remediation run (formatted according to RFC3339).
    time_finished str
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    time_started str
    The date and time of the start of the remediation run (formatted according to RFC3339).
    type str
    The type of stage.
    summary String
    Information about the current step within the given stage.
    timeCreated String
    The creation date and time of the remediation run (formatted according to RFC3339).
    timeFinished String
    The date and time of the finish of the remediation run (formatted according to RFC3339).
    timeStarted String
    The date and time of the start of the remediation run (formatted according to RFC3339).
    type String
    The type of stage.

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi