Oracle Cloud Infrastructure v2.31.0 published on Thursday, Apr 17, 2025 by Pulumi
oci.FleetAppsManagement.getCompliancePolicyRule
Explore with Pulumi AI
This data source provides details about a specific Compliance Policy Rule resource in Oracle Cloud Infrastructure Fleet Apps Management service.
Gets information about a CompliancePolicyRule.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testCompliancePolicyRule = oci.FleetAppsManagement.getCompliancePolicyRule({
    compliancePolicyRuleId: testCompliancePolicyRuleOciFleetAppsManagementCompliancePolicyRule.id,
});
import pulumi
import pulumi_oci as oci
test_compliance_policy_rule = oci.FleetAppsManagement.get_compliance_policy_rule(compliance_policy_rule_id=test_compliance_policy_rule_oci_fleet_apps_management_compliance_policy_rule["id"])
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/fleetappsmanagement"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := fleetappsmanagement.GetCompliancePolicyRule(ctx, &fleetappsmanagement.GetCompliancePolicyRuleArgs{
			CompliancePolicyRuleId: testCompliancePolicyRuleOciFleetAppsManagementCompliancePolicyRule.Id,
		}, 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 testCompliancePolicyRule = Oci.FleetAppsManagement.GetCompliancePolicyRule.Invoke(new()
    {
        CompliancePolicyRuleId = testCompliancePolicyRuleOciFleetAppsManagementCompliancePolicyRule.Id,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.FleetAppsManagement.FleetAppsManagementFunctions;
import com.pulumi.oci.FleetAppsManagement.inputs.GetCompliancePolicyRuleArgs;
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 testCompliancePolicyRule = FleetAppsManagementFunctions.getCompliancePolicyRule(GetCompliancePolicyRuleArgs.builder()
            .compliancePolicyRuleId(testCompliancePolicyRuleOciFleetAppsManagementCompliancePolicyRule.id())
            .build());
    }
}
variables:
  testCompliancePolicyRule:
    fn::invoke:
      function: oci:FleetAppsManagement:getCompliancePolicyRule
      arguments:
        compliancePolicyRuleId: ${testCompliancePolicyRuleOciFleetAppsManagementCompliancePolicyRule.id}
Using getCompliancePolicyRule
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 getCompliancePolicyRule(args: GetCompliancePolicyRuleArgs, opts?: InvokeOptions): Promise<GetCompliancePolicyRuleResult>
function getCompliancePolicyRuleOutput(args: GetCompliancePolicyRuleOutputArgs, opts?: InvokeOptions): Output<GetCompliancePolicyRuleResult>def get_compliance_policy_rule(compliance_policy_rule_id: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetCompliancePolicyRuleResult
def get_compliance_policy_rule_output(compliance_policy_rule_id: Optional[pulumi.Input[str]] = None,
                               opts: Optional[InvokeOptions] = None) -> Output[GetCompliancePolicyRuleResult]func GetCompliancePolicyRule(ctx *Context, args *GetCompliancePolicyRuleArgs, opts ...InvokeOption) (*GetCompliancePolicyRuleResult, error)
func GetCompliancePolicyRuleOutput(ctx *Context, args *GetCompliancePolicyRuleOutputArgs, opts ...InvokeOption) GetCompliancePolicyRuleResultOutput> Note: This function is named GetCompliancePolicyRule in the Go SDK.
public static class GetCompliancePolicyRule 
{
    public static Task<GetCompliancePolicyRuleResult> InvokeAsync(GetCompliancePolicyRuleArgs args, InvokeOptions? opts = null)
    public static Output<GetCompliancePolicyRuleResult> Invoke(GetCompliancePolicyRuleInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetCompliancePolicyRuleResult> getCompliancePolicyRule(GetCompliancePolicyRuleArgs args, InvokeOptions options)
public static Output<GetCompliancePolicyRuleResult> getCompliancePolicyRule(GetCompliancePolicyRuleArgs args, InvokeOptions options)
fn::invoke:
  function: oci:FleetAppsManagement/getCompliancePolicyRule:getCompliancePolicyRule
  arguments:
    # arguments dictionaryThe following arguments are supported:
- CompliancePolicy stringRule Id 
- unique CompliancePolicyRule identifier.
- CompliancePolicy stringRule Id 
- unique CompliancePolicyRule identifier.
- compliancePolicy StringRule Id 
- unique CompliancePolicyRule identifier.
- compliancePolicy stringRule Id 
- unique CompliancePolicyRule identifier.
- compliance_policy_ strrule_ id 
- unique CompliancePolicyRule identifier.
- compliancePolicy StringRule Id 
- unique CompliancePolicyRule identifier.
getCompliancePolicyRule Result
The following output properties are available:
- CompartmentId string
- The OCID of the compartment the CompliancePolicyRule belongs to.
- CompliancePolicy stringId 
- Unique OCID of the CompliancePolicy.
- CompliancePolicy stringRule Id 
- 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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- 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"}
- GracePeriod string
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- Id string
- Unique OCID of the CompliancePolicyRule.
- LifecycleDetails string
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- PatchSelections List<GetCompliance Policy Rule Patch Selection> 
- Patch Selection Details
- PatchTypes List<string>
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- ProductVersions List<GetCompliance Policy Rule Product Version> 
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- Severities List<string>
- Severity to which this CompliancePolicyRule applies.
- State string
- The current state of the CompliancePolicyRule.
- Dictionary<string, string>
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- TimeCreated string
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- TimeUpdated string
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- CompartmentId string
- The OCID of the compartment the CompliancePolicyRule belongs to.
- CompliancePolicy stringId 
- Unique OCID of the CompliancePolicy.
- CompliancePolicy stringRule Id 
- 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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- 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"}
- GracePeriod string
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- Id string
- Unique OCID of the CompliancePolicyRule.
- LifecycleDetails string
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- PatchSelections []GetCompliance Policy Rule Patch Selection 
- Patch Selection Details
- PatchTypes []string
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- ProductVersions []GetCompliance Policy Rule Product Version 
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- Severities []string
- Severity to which this CompliancePolicyRule applies.
- State string
- The current state of the CompliancePolicyRule.
- map[string]string
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- TimeCreated string
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- TimeUpdated string
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- compartmentId String
- The OCID of the compartment the CompliancePolicyRule belongs to.
- compliancePolicy StringId 
- Unique OCID of the CompliancePolicy.
- compliancePolicy StringRule Id 
- 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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- 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"}
- gracePeriod String
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- id String
- Unique OCID of the CompliancePolicyRule.
- lifecycleDetails String
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- patchSelections List<GetCompliance Policy Rule Patch Selection> 
- Patch Selection Details
- patchTypes List<String>
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- productVersions List<GetCompliance Policy Rule Product Version> 
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- severities List<String>
- Severity to which this CompliancePolicyRule applies.
- state String
- The current state of the CompliancePolicyRule.
- Map<String,String>
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- timeCreated String
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- timeUpdated String
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- compartmentId string
- The OCID of the compartment the CompliancePolicyRule belongs to.
- compliancePolicy stringId 
- Unique OCID of the CompliancePolicy.
- compliancePolicy stringRule Id 
- {[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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- {[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"}
- gracePeriod string
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- id string
- Unique OCID of the CompliancePolicyRule.
- lifecycleDetails string
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- patchSelections GetCompliance Policy Rule Patch Selection[] 
- Patch Selection Details
- patchTypes string[]
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- productVersions GetCompliance Policy Rule Product Version[] 
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- severities string[]
- Severity to which this CompliancePolicyRule applies.
- state string
- The current state of the CompliancePolicyRule.
- {[key: string]: string}
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- timeCreated string
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- timeUpdated string
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- compartment_id str
- The OCID of the compartment the CompliancePolicyRule belongs to.
- compliance_policy_ strid 
- Unique OCID of the CompliancePolicy.
- compliance_policy_ strrule_ id 
- 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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- 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"}
- grace_period str
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- id str
- Unique OCID of the CompliancePolicyRule.
- lifecycle_details str
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- patch_selections Sequence[fleetappsmanagement.Get Compliance Policy Rule Patch Selection] 
- Patch Selection Details
- patch_types Sequence[str]
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- product_versions Sequence[fleetappsmanagement.Get Compliance Policy Rule Product Version] 
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- severities Sequence[str]
- Severity to which this CompliancePolicyRule applies.
- state str
- The current state of the CompliancePolicyRule.
- Mapping[str, str]
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- time_created str
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- time_updated str
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- compartmentId String
- The OCID of the compartment the CompliancePolicyRule belongs to.
- compliancePolicy StringId 
- Unique OCID of the CompliancePolicy.
- compliancePolicy StringRule Id 
- 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 user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
- 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"}
- gracePeriod String
- Grace period in days,weeks,months or years the exemption is applicable for the rule. This enables a grace period when Fleet Application Management doesn't report the product as noncompliant when patch is not applied.
- id String
- Unique OCID of the CompliancePolicyRule.
- lifecycleDetails String
- A message that describes the current state of the CompliancePolicyRule in more detail. For example, can be used to provide actionable information for a resource in the Failed state.
- patchSelections List<Property Map>
- Patch Selection Details
- patchTypes List<String>
- PlatformConfiguration OCID for the patch type to which this CompliancePolicyRule applies.
- productVersions List<Property Map>
- A specific product version or a specific version and succeeding. Example: 12.1 or 12.1 and above for Oracle WebLogic Application server. The policy applies to the next version only, and not to other versions such as, 12.1.x.
- severities List<String>
- Severity to which this CompliancePolicyRule applies.
- state String
- The current state of the CompliancePolicyRule.
- Map<String>
- System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
- timeCreated String
- The date and time the CompliancePolicyRule was created, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
- timeUpdated String
- The date and time the CompliancePolicyRule was updated, in the format defined by RFC 3339. Example: 2016-08-25T21:10:29.600Z
Supporting Types
GetCompliancePolicyRulePatchSelection     
- DaysSince intRelease 
- Days passed since patch release.
- PatchLevel string
- Patch Name.
- PatchName string
- Patch Name.
- SelectionType string
- Selection type for the Patch.
- DaysSince intRelease 
- Days passed since patch release.
- PatchLevel string
- Patch Name.
- PatchName string
- Patch Name.
- SelectionType string
- Selection type for the Patch.
- daysSince IntegerRelease 
- Days passed since patch release.
- patchLevel String
- Patch Name.
- patchName String
- Patch Name.
- selectionType String
- Selection type for the Patch.
- daysSince numberRelease 
- Days passed since patch release.
- patchLevel string
- Patch Name.
- patchName string
- Patch Name.
- selectionType string
- Selection type for the Patch.
- days_since_ intrelease 
- Days passed since patch release.
- patch_level str
- Patch Name.
- patch_name str
- Patch Name.
- selection_type str
- Selection type for the Patch.
- daysSince NumberRelease 
- Days passed since patch release.
- patchLevel String
- Patch Name.
- patchName String
- Patch Name.
- selectionType String
- Selection type for the Patch.
GetCompliancePolicyRuleProductVersion     
- IsApplicable boolFor All Higher Versions 
- Is rule applicable to all higher versions also
- Version string
- Product version the rule is applicable.
- IsApplicable boolFor All Higher Versions 
- Is rule applicable to all higher versions also
- Version string
- Product version the rule is applicable.
- isApplicable BooleanFor All Higher Versions 
- Is rule applicable to all higher versions also
- version String
- Product version the rule is applicable.
- isApplicable booleanFor All Higher Versions 
- Is rule applicable to all higher versions also
- version string
- Product version the rule is applicable.
- is_applicable_ boolfor_ all_ higher_ versions 
- Is rule applicable to all higher versions also
- version str
- Product version the rule is applicable.
- isApplicable BooleanFor All Higher Versions 
- Is rule applicable to all higher versions also
- version String
- Product version the rule is applicable.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.