oci logo
Oracle Cloud Infrastructure v0.13.0, Mar 28 23

oci.VulnerabilityScanning.getContainerScanRecipes

This data source provides the list of Container Scan Recipes in Oracle Cloud Infrastructure Vulnerability Scanning service.

Retrieves a list of ContainerScanRecipeSummary objects in a compartment. A recipe determines the types of security issues that you want scanned.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testContainerScanRecipes = Oci.VulnerabilityScanning.GetContainerScanRecipes.Invoke(new()
    {
        CompartmentId = @var.Compartment_id,
        DisplayName = @var.Container_scan_recipe_display_name,
        State = @var.Container_scan_recipe_state,
    });

});
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/go/oci/VulnerabilityScanning"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := VulnerabilityScanning.GetContainerScanRecipes(ctx, &vulnerabilityscanning.GetContainerScanRecipesArgs{
			CompartmentId: _var.Compartment_id,
			DisplayName:   pulumi.StringRef(_var.Container_scan_recipe_display_name),
			State:         pulumi.StringRef(_var.Container_scan_recipe_state),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.VulnerabilityScanning.VulnerabilityScanningFunctions;
import com.pulumi.oci.VulnerabilityScanning.inputs.GetContainerScanRecipesArgs;
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 testContainerScanRecipes = VulnerabilityScanningFunctions.getContainerScanRecipes(GetContainerScanRecipesArgs.builder()
            .compartmentId(var_.compartment_id())
            .displayName(var_.container_scan_recipe_display_name())
            .state(var_.container_scan_recipe_state())
            .build());

    }
}
import pulumi
import pulumi_oci as oci

test_container_scan_recipes = oci.VulnerabilityScanning.get_container_scan_recipes(compartment_id=var["compartment_id"],
    display_name=var["container_scan_recipe_display_name"],
    state=var["container_scan_recipe_state"])
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testContainerScanRecipes = oci.VulnerabilityScanning.getContainerScanRecipes({
    compartmentId: _var.compartment_id,
    displayName: _var.container_scan_recipe_display_name,
    state: _var.container_scan_recipe_state,
});
variables:
  testContainerScanRecipes:
    fn::invoke:
      Function: oci:VulnerabilityScanning:getContainerScanRecipes
      Arguments:
        compartmentId: ${var.compartment_id}
        displayName: ${var.container_scan_recipe_display_name}
        state: ${var.container_scan_recipe_state}

Using getContainerScanRecipes

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 getContainerScanRecipes(args: GetContainerScanRecipesArgs, opts?: InvokeOptions): Promise<GetContainerScanRecipesResult>
function getContainerScanRecipesOutput(args: GetContainerScanRecipesOutputArgs, opts?: InvokeOptions): Output<GetContainerScanRecipesResult>
def get_container_scan_recipes(compartment_id: Optional[str] = None,
                               display_name: Optional[str] = None,
                               filters: Optional[Sequence[_vulnerabilityscanning.GetContainerScanRecipesFilter]] = None,
                               state: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetContainerScanRecipesResult
def get_container_scan_recipes_output(compartment_id: Optional[pulumi.Input[str]] = None,
                               display_name: Optional[pulumi.Input[str]] = None,
                               filters: Optional[pulumi.Input[Sequence[pulumi.Input[_vulnerabilityscanning.GetContainerScanRecipesFilterArgs]]]] = None,
                               state: Optional[pulumi.Input[str]] = None,
                               opts: Optional[InvokeOptions] = None) -> Output[GetContainerScanRecipesResult]
func GetContainerScanRecipes(ctx *Context, args *GetContainerScanRecipesArgs, opts ...InvokeOption) (*GetContainerScanRecipesResult, error)
func GetContainerScanRecipesOutput(ctx *Context, args *GetContainerScanRecipesOutputArgs, opts ...InvokeOption) GetContainerScanRecipesResultOutput

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

public static class GetContainerScanRecipes 
{
    public static Task<GetContainerScanRecipesResult> InvokeAsync(GetContainerScanRecipesArgs args, InvokeOptions? opts = null)
    public static Output<GetContainerScanRecipesResult> Invoke(GetContainerScanRecipesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetContainerScanRecipesResult> getContainerScanRecipes(GetContainerScanRecipesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: oci:VulnerabilityScanning/getContainerScanRecipes:getContainerScanRecipes
  arguments:
    # arguments dictionary

The following arguments are supported:

CompartmentId string

The ID of the compartment in which to list resources.

DisplayName string

A filter to return only resources that match the entire display name given.

Filters List<GetContainerScanRecipesFilter>
State string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

CompartmentId string

The ID of the compartment in which to list resources.

DisplayName string

A filter to return only resources that match the entire display name given.

Filters []GetContainerScanRecipesFilter
State string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

compartmentId String

The ID of the compartment in which to list resources.

displayName String

A filter to return only resources that match the entire display name given.

filters List<GetContainerScanRecipesFilter>
state String

A filter to return only resources whose lifecycleState matches the given lifecycleState.

compartmentId string

The ID of the compartment in which to list resources.

displayName string

A filter to return only resources that match the entire display name given.

filters GetContainerScanRecipesFilter[]
state string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

compartment_id str

The ID of the compartment in which to list resources.

display_name str

A filter to return only resources that match the entire display name given.

filters GetContainerScanRecipesFilter]
state str

A filter to return only resources whose lifecycleState matches the given lifecycleState.

compartmentId String

The ID of the compartment in which to list resources.

displayName String

A filter to return only resources that match the entire display name given.

filters List<Property Map>
state String

A filter to return only resources whose lifecycleState matches the given lifecycleState.

getContainerScanRecipes Result

The following output properties are available:

CompartmentId string

The OCID of the container scan recipe's compartment

ContainerScanRecipeSummaryCollections List<GetContainerScanRecipesContainerScanRecipeSummaryCollection>

The list of container_scan_recipe_summary_collection.

Id string

The provider-assigned unique ID for this managed resource.

DisplayName string

User friendly name of container scan recipe

Filters List<GetContainerScanRecipesFilter>
State string

The current state of the config.

CompartmentId string

The OCID of the container scan recipe's compartment

ContainerScanRecipeSummaryCollections []GetContainerScanRecipesContainerScanRecipeSummaryCollection

The list of container_scan_recipe_summary_collection.

Id string

The provider-assigned unique ID for this managed resource.

DisplayName string

User friendly name of container scan recipe

Filters []GetContainerScanRecipesFilter
State string

The current state of the config.

compartmentId String

The OCID of the container scan recipe's compartment

containerScanRecipeSummaryCollections List<GetContainerScanRecipesContainerScanRecipeSummaryCollection>

The list of container_scan_recipe_summary_collection.

id String

The provider-assigned unique ID for this managed resource.

displayName String

User friendly name of container scan recipe

filters List<GetContainerScanRecipesFilter>
state String

The current state of the config.

compartmentId string

The OCID of the container scan recipe's compartment

containerScanRecipeSummaryCollections GetContainerScanRecipesContainerScanRecipeSummaryCollection[]

The list of container_scan_recipe_summary_collection.

id string

The provider-assigned unique ID for this managed resource.

displayName string

User friendly name of container scan recipe

filters GetContainerScanRecipesFilter[]
state string

The current state of the config.

compartment_id str

The OCID of the container scan recipe's compartment

container_scan_recipe_summary_collections GetContainerScanRecipesContainerScanRecipeSummaryCollection]

The list of container_scan_recipe_summary_collection.

id str

The provider-assigned unique ID for this managed resource.

display_name str

User friendly name of container scan recipe

filters GetContainerScanRecipesFilter]
state str

The current state of the config.

compartmentId String

The OCID of the container scan recipe's compartment

containerScanRecipeSummaryCollections List<Property Map>

The list of container_scan_recipe_summary_collection.

id String

The provider-assigned unique ID for this managed resource.

displayName String

User friendly name of container scan recipe

filters List<Property Map>
state String

The current state of the config.

Supporting Types

GetContainerScanRecipesContainerScanRecipeSummaryCollection

GetContainerScanRecipesContainerScanRecipeSummaryCollectionItem

CompartmentId string

The ID of the compartment in which to list resources.

DefinedTags Dictionary<string, object>

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, object>

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

The OCID of container scan recipe. Immutable and generated on creation.

ImageCount int

This field is set equal to the number of images we want to scan in the first go when the recipe is created

ScanSettings List<GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting>

A collection of container scan settings

State string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

SystemTags Dictionary<string, object>

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

TimeCreated string

Date and time the recipe was created, format as described in RFC 3339

TimeUpdated string

Date and time the recipe was last updated, format as described in RFC 3339

CompartmentId string

The ID of the compartment in which to list resources.

DefinedTags map[string]interface{}

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]interface{}

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

The OCID of container scan recipe. Immutable and generated on creation.

ImageCount int

This field is set equal to the number of images we want to scan in the first go when the recipe is created

ScanSettings []GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting

A collection of container scan settings

State string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

SystemTags map[string]interface{}

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

TimeCreated string

Date and time the recipe was created, format as described in RFC 3339

TimeUpdated string

Date and time the recipe was last updated, format as described in RFC 3339

compartmentId String

The ID of the compartment in which to list resources.

definedTags Map<String,Object>

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,Object>

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

The OCID of container scan recipe. Immutable and generated on creation.

imageCount Integer

This field is set equal to the number of images we want to scan in the first go when the recipe is created

scanSettings List<GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting>

A collection of container scan settings

state String

A filter to return only resources whose lifecycleState matches the given lifecycleState.

systemTags Map<String,Object>

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

timeCreated String

Date and time the recipe was created, format as described in RFC 3339

timeUpdated String

Date and time the recipe was last updated, format as described in RFC 3339

compartmentId string

The ID of the compartment in which to list resources.

definedTags {[key: string]: any}

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]: any}

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

The OCID of container scan recipe. Immutable and generated on creation.

imageCount number

This field is set equal to the number of images we want to scan in the first go when the recipe is created

scanSettings GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting[]

A collection of container scan settings

state string

A filter to return only resources whose lifecycleState matches the given lifecycleState.

systemTags {[key: string]: any}

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

timeCreated string

Date and time the recipe was created, format as described in RFC 3339

timeUpdated string

Date and time the recipe was last updated, format as described in RFC 3339

compartment_id str

The ID of the compartment in which to list resources.

defined_tags Mapping[str, Any]

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, Any]

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

The OCID of container scan recipe. Immutable and generated on creation.

image_count int

This field is set equal to the number of images we want to scan in the first go when the recipe is created

scan_settings GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting]

A collection of container scan settings

state str

A filter to return only resources whose lifecycleState matches the given lifecycleState.

system_tags Mapping[str, Any]

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

time_created str

Date and time the recipe was created, format as described in RFC 3339

time_updated str

Date and time the recipe was last updated, format as described in RFC 3339

compartmentId String

The ID of the compartment in which to list resources.

definedTags Map<Any>

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<Any>

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

The OCID of container scan recipe. Immutable and generated on creation.

imageCount Number

This field is set equal to the number of images we want to scan in the first go when the recipe is created

scanSettings List<Property Map>

A collection of container scan settings

state String

A filter to return only resources whose lifecycleState matches the given lifecycleState.

systemTags Map<Any>

Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}

timeCreated String

Date and time the recipe was created, format as described in RFC 3339

timeUpdated String

Date and time the recipe was last updated, format as described in RFC 3339

GetContainerScanRecipesContainerScanRecipeSummaryCollectionItemScanSetting

ScanLevel string

The scan level

ScanLevel string

The scan level

scanLevel String

The scan level

scanLevel string

The scan level

scan_level str

The scan level

scanLevel String

The scan level

GetContainerScanRecipesFilter

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

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes

This Pulumi package is based on the oci Terraform Provider.