Oracle Cloud Infrastructure

Pulumi Official
Package maintained by Pulumi
v0.1.1 published on Tuesday, May 3, 2022 by Pulumi

getContainerScanTargets

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

Retrieves a list of ContainerScanTargetSummary objects in a compartment. A container scan target specifies a group of one or more Docker image repositories in Oracle Cloud Infrastructure Registry (OCIR) that you want routinely scanned for security vulnerabilities.

Example Usage

using Pulumi;
using Oci = Pulumi.Oci;

class MyStack : Stack
{
    public MyStack()
    {
        var testContainerScanTargets = Output.Create(Oci.VulnerabilityScanning.GetContainerScanTargets.InvokeAsync(new Oci.VulnerabilityScanning.GetContainerScanTargetsArgs
        {
            CompartmentId = @var.Compartment_id,
            DisplayName = @var.Container_scan_target_display_name,
            State = @var.Container_scan_target_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.GetContainerScanTargets(ctx, &vulnerabilityscanning.GetContainerScanTargetsArgs{
			CompartmentId: _var.Compartment_id,
			DisplayName:   pulumi.StringRef(_var.Container_scan_target_display_name),
			State:         pulumi.StringRef(_var.Container_scan_target_state),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_oci as oci

test_container_scan_targets = oci.VulnerabilityScanning.get_container_scan_targets(compartment_id=var["compartment_id"],
    display_name=var["container_scan_target_display_name"],
    state=var["container_scan_target_state"])
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testContainerScanTargets = oci.VulnerabilityScanning.getContainerScanTargets({
    compartmentId: _var.compartment_id,
    displayName: _var.container_scan_target_display_name,
    state: _var.container_scan_target_state,
});

Coming soon!

Using getContainerScanTargets

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 getContainerScanTargets(args: GetContainerScanTargetsArgs, opts?: InvokeOptions): Promise<GetContainerScanTargetsResult>
function getContainerScanTargetsOutput(args: GetContainerScanTargetsOutputArgs, opts?: InvokeOptions): Output<GetContainerScanTargetsResult>
def get_container_scan_targets(compartment_id: Optional[str] = None,
                               display_name: Optional[str] = None,
                               filters: Optional[Sequence[_vulnerabilityscanning.GetContainerScanTargetsFilter]] = None,
                               state: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetContainerScanTargetsResult
def get_container_scan_targets_output(compartment_id: Optional[pulumi.Input[str]] = None,
                               display_name: Optional[pulumi.Input[str]] = None,
                               filters: Optional[pulumi.Input[Sequence[pulumi.Input[_vulnerabilityscanning.GetContainerScanTargetsFilterArgs]]]] = None,
                               state: Optional[pulumi.Input[str]] = None,
                               opts: Optional[InvokeOptions] = None) -> Output[GetContainerScanTargetsResult]
func GetContainerScanTargets(ctx *Context, args *GetContainerScanTargetsArgs, opts ...InvokeOption) (*GetContainerScanTargetsResult, error)
func GetContainerScanTargetsOutput(ctx *Context, args *GetContainerScanTargetsOutputArgs, opts ...InvokeOption) GetContainerScanTargetsResultOutput

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

public static class GetContainerScanTargets 
{
    public static Task<GetContainerScanTargetsResult> InvokeAsync(GetContainerScanTargetsArgs args, InvokeOptions? opts = null)
    public static Output<GetContainerScanTargetsResult> Invoke(GetContainerScanTargetsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetContainerScanTargetsResult> getContainerScanTargets(GetContainerScanTargetsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: oci:VulnerabilityScanning/getContainerScanTargets:getContainerScanTargets
  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<GetContainerScanTargetsFilter>
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 []GetContainerScanTargetsFilter
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<GetContainerScanTargetsFilter>
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 GetContainerScanTargetsFilter[]
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 GetContainerScanTargetsFilter]
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.

getContainerScanTargets Result

The following output properties are available:

CompartmentId string

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

ContainerScanTargetSummaryCollections List<GetContainerScanTargetsContainerScanTargetSummaryCollection>

The list of container_scan_target_summary_collection.

Id string

The provider-assigned unique ID for this managed resource.

DisplayName string

User friendly name of container scan target

Filters List<GetContainerScanTargetsFilter>
State string

The current state of the config.

CompartmentId string

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

ContainerScanTargetSummaryCollections []GetContainerScanTargetsContainerScanTargetSummaryCollection

The list of container_scan_target_summary_collection.

Id string

The provider-assigned unique ID for this managed resource.

DisplayName string

User friendly name of container scan target

Filters []GetContainerScanTargetsFilter
State string

The current state of the config.

compartmentId String

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

containerScanTargetSummaryCollections List<GetContainerScanTargetsContainerScanTargetSummaryCollection>

The list of container_scan_target_summary_collection.

id String

The provider-assigned unique ID for this managed resource.

displayName String

User friendly name of container scan target

filters List<GetContainerScanTargetsFilter>
state String

The current state of the config.

compartmentId string

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

containerScanTargetSummaryCollections GetContainerScanTargetsContainerScanTargetSummaryCollection[]

The list of container_scan_target_summary_collection.

id string

The provider-assigned unique ID for this managed resource.

displayName string

User friendly name of container scan target

filters GetContainerScanTargetsFilter[]
state string

The current state of the config.

compartment_id str

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

container_scan_target_summary_collections GetContainerScanTargetsContainerScanTargetSummaryCollection]

The list of container_scan_target_summary_collection.

id str

The provider-assigned unique ID for this managed resource.

display_name str

User friendly name of container scan target

filters GetContainerScanTargetsFilter]
state str

The current state of the config.

compartmentId String

The OCID of the compartment to perform the scans in. All listed repositories must be in the compartment.

containerScanTargetSummaryCollections List<Property Map>

The list of container_scan_target_summary_collection.

id String

The provider-assigned unique ID for this managed resource.

displayName String

User friendly name of container scan target

filters List<Property Map>
state String

The current state of the config.

Supporting Types

GetContainerScanTargetsContainerScanTargetSummaryCollection

GetContainerScanTargetsContainerScanTargetSummaryCollectionItem

CompartmentId string

The ID of the compartment in which to list resources.

ContainerScanRecipeId string

ID of the container scan recipe this target applies.

DefinedTags Dictionary<string, object>

Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}

Description string

Target description.

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 target. Immutable and generated on creation.

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"}

TargetRegistries List<GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry>

Registry information for a container scan target

TimeCreated string

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

TimeUpdated string

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

CompartmentId string

The ID of the compartment in which to list resources.

ContainerScanRecipeId string

ID of the container scan recipe this target applies.

DefinedTags map[string]interface{}

Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}

Description string

Target description.

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 target. Immutable and generated on creation.

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"}

TargetRegistries []GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry

Registry information for a container scan target

TimeCreated string

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

TimeUpdated string

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

compartmentId String

The ID of the compartment in which to list resources.

containerScanRecipeId String

ID of the container scan recipe this target applies.

definedTags Map<String,Object>

Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}

description String

Target description.

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 target. Immutable and generated on creation.

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"}

targetRegistries List<GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry>

Registry information for a container scan target

timeCreated String

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

timeUpdated String

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

compartmentId string

The ID of the compartment in which to list resources.

containerScanRecipeId string

ID of the container scan recipe this target applies.

definedTags {[key: string]: any}

Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}

description string

Target description.

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 target. Immutable and generated on creation.

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"}

targetRegistries GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry[]

Registry information for a container scan target

timeCreated string

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

timeUpdated string

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

compartment_id str

The ID of the compartment in which to list resources.

container_scan_recipe_id str

ID of the container scan recipe this target applies.

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"}

description str

Target description.

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 target. Immutable and generated on creation.

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"}

target_registries GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry]

Registry information for a container scan target

time_created str

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

time_updated str

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

compartmentId String

The ID of the compartment in which to list resources.

containerScanRecipeId String

ID of the container scan recipe this target applies.

definedTags Map<Any>

Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}

description String

Target description.

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 target. Immutable and generated on creation.

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"}

targetRegistries List<Property Map>

Registry information for a container scan target

timeCreated String

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

timeUpdated String

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

GetContainerScanTargetsContainerScanTargetSummaryCollectionItemTargetRegistry

CompartmentId string

The ID of the compartment in which to list resources.

Repositories List<string>

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

Type string

The scan level

Url string

URL of the registry.

CompartmentId string

The ID of the compartment in which to list resources.

Repositories []string

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

Type string

The scan level

Url string

URL of the registry.

compartmentId String

The ID of the compartment in which to list resources.

repositories List<String>

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

type String

The scan level

url String

URL of the registry.

compartmentId string

The ID of the compartment in which to list resources.

repositories string[]

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

type string

The scan level

url string

URL of the registry.

compartment_id str

The ID of the compartment in which to list resources.

repositories Sequence[str]

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

type str

The scan level

url str

URL of the registry.

compartmentId String

The ID of the compartment in which to list resources.

repositories List<String>

List of repositories to scan images in. If left empty, the target defaults to scanning all repos in the compartmentId

type String

The scan level

url String

URL of the registry.

GetContainerScanTargetsFilter

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
https://github.com/pulumi/pulumi-oci
License
Apache-2.0
Notes

This Pulumi package is based on the oci Terraform Provider.