1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Artifacts
  5. getContainerImage
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi

oci.Artifacts.getContainerImage

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi

    This data source provides details about a specific Container Image resource in Oracle Cloud Infrastructure Artifacts service.

    Get container image metadata.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testContainerImage = oci.Artifacts.getContainerImage({
        imageId: containerImageId,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_container_image = oci.Artifacts.get_container_image(image_id=container_image_id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Artifacts"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Artifacts.GetContainerImage(ctx, &artifacts.GetContainerImageArgs{
    			ImageId: containerImageId,
    		}, 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 testContainerImage = Oci.Artifacts.GetContainerImage.Invoke(new()
        {
            ImageId = containerImageId,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Artifacts.ArtifactsFunctions;
    import com.pulumi.oci.Artifacts.inputs.GetContainerImageArgs;
    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 testContainerImage = ArtifactsFunctions.getContainerImage(GetContainerImageArgs.builder()
                .imageId(containerImageId)
                .build());
    
        }
    }
    
    variables:
      testContainerImage:
        fn::invoke:
          Function: oci:Artifacts:getContainerImage
          Arguments:
            imageId: ${containerImageId}
    

    Using getContainerImage

    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 getContainerImage(args: GetContainerImageArgs, opts?: InvokeOptions): Promise<GetContainerImageResult>
    function getContainerImageOutput(args: GetContainerImageOutputArgs, opts?: InvokeOptions): Output<GetContainerImageResult>
    def get_container_image(image_id: Optional[str] = None,
                            opts: Optional[InvokeOptions] = None) -> GetContainerImageResult
    def get_container_image_output(image_id: Optional[pulumi.Input[str]] = None,
                            opts: Optional[InvokeOptions] = None) -> Output[GetContainerImageResult]
    func GetContainerImage(ctx *Context, args *GetContainerImageArgs, opts ...InvokeOption) (*GetContainerImageResult, error)
    func GetContainerImageOutput(ctx *Context, args *GetContainerImageOutputArgs, opts ...InvokeOption) GetContainerImageResultOutput

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

    public static class GetContainerImage 
    {
        public static Task<GetContainerImageResult> InvokeAsync(GetContainerImageArgs args, InvokeOptions? opts = null)
        public static Output<GetContainerImageResult> Invoke(GetContainerImageInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetContainerImageResult> getContainerImage(GetContainerImageArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Artifacts/getContainerImage:getContainerImage
      arguments:
        # arguments dictionary

    The following arguments are supported:

    ImageId string
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID
    ImageId string
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID
    imageId String
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID
    imageId string
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID
    image_id str
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID
    imageId String
    The OCID of the container image. Example: ocid1.containerimage.oc1..exampleuniqueID

    getContainerImage Result

    The following output properties are available:

    CompartmentId string
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    CreatedBy string
    The OCID of the user or principal that pushed the version.
    DefinedTags Dictionary<string, object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    Digest string
    The sha256 digest of the image layer.
    DisplayName string
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    FreeformTags Dictionary<string, object>
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Id string
    The provider-assigned unique ID for this managed resource.
    ImageId string
    Layers List<GetContainerImageLayer>
    Layers of which the image is composed, ordered by the layer digest.
    LayersSizeInBytes string
    The total size of the container image layers in bytes.
    ManifestSizeInBytes int
    The size of the container image manifest in bytes.
    PullCount string
    Total number of pulls.
    RepositoryId string
    The OCID of the container repository.
    RepositoryName string
    The container repository name.
    State string
    The current state of the container image.
    SystemTags Dictionary<string, object>
    The system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The creation time of the version.
    TimeLastPulled string
    An RFC 3339 timestamp indicating when the image was last pulled.
    Version string
    The version name.
    Versions List<GetContainerImageVersion>
    The versions associated with this image.
    CompartmentId string
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    CreatedBy string
    The OCID of the user or principal that pushed the version.
    DefinedTags map[string]interface{}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    Digest string
    The sha256 digest of the image layer.
    DisplayName string
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    FreeformTags map[string]interface{}
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Id string
    The provider-assigned unique ID for this managed resource.
    ImageId string
    Layers []GetContainerImageLayer
    Layers of which the image is composed, ordered by the layer digest.
    LayersSizeInBytes string
    The total size of the container image layers in bytes.
    ManifestSizeInBytes int
    The size of the container image manifest in bytes.
    PullCount string
    Total number of pulls.
    RepositoryId string
    The OCID of the container repository.
    RepositoryName string
    The container repository name.
    State string
    The current state of the container image.
    SystemTags map[string]interface{}
    The system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The creation time of the version.
    TimeLastPulled string
    An RFC 3339 timestamp indicating when the image was last pulled.
    Version string
    The version name.
    Versions []GetContainerImageVersion
    The versions associated with this image.
    compartmentId String
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    createdBy String
    The OCID of the user or principal that pushed the version.
    definedTags Map<String,Object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    digest String
    The sha256 digest of the image layer.
    displayName String
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    freeformTags Map<String,Object>
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    id String
    The provider-assigned unique ID for this managed resource.
    imageId String
    layers List<GetContainerImageLayer>
    Layers of which the image is composed, ordered by the layer digest.
    layersSizeInBytes String
    The total size of the container image layers in bytes.
    manifestSizeInBytes Integer
    The size of the container image manifest in bytes.
    pullCount String
    Total number of pulls.
    repositoryId String
    The OCID of the container repository.
    repositoryName String
    The container repository name.
    state String
    The current state of the container image.
    systemTags Map<String,Object>
    The system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The creation time of the version.
    timeLastPulled String
    An RFC 3339 timestamp indicating when the image was last pulled.
    version String
    The version name.
    versions List<GetContainerImageVersion>
    The versions associated with this image.
    compartmentId string
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    createdBy string
    The OCID of the user or principal that pushed the version.
    definedTags {[key: string]: any}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    digest string
    The sha256 digest of the image layer.
    displayName string
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    freeformTags {[key: string]: any}
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    id string
    The provider-assigned unique ID for this managed resource.
    imageId string
    layers GetContainerImageLayer[]
    Layers of which the image is composed, ordered by the layer digest.
    layersSizeInBytes string
    The total size of the container image layers in bytes.
    manifestSizeInBytes number
    The size of the container image manifest in bytes.
    pullCount string
    Total number of pulls.
    repositoryId string
    The OCID of the container repository.
    repositoryName string
    The container repository name.
    state string
    The current state of the container image.
    systemTags {[key: string]: any}
    The system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated string
    The creation time of the version.
    timeLastPulled string
    An RFC 3339 timestamp indicating when the image was last pulled.
    version string
    The version name.
    versions GetContainerImageVersion[]
    The versions associated with this image.
    compartment_id str
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    created_by str
    The OCID of the user or principal that pushed the version.
    defined_tags Mapping[str, Any]
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    digest str
    The sha256 digest of the image layer.
    display_name str
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    freeform_tags Mapping[str, Any]
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    id str
    The provider-assigned unique ID for this managed resource.
    image_id str
    layers Sequence[artifacts.GetContainerImageLayer]
    Layers of which the image is composed, ordered by the layer digest.
    layers_size_in_bytes str
    The total size of the container image layers in bytes.
    manifest_size_in_bytes int
    The size of the container image manifest in bytes.
    pull_count str
    Total number of pulls.
    repository_id str
    The OCID of the container repository.
    repository_name str
    The container repository name.
    state str
    The current state of the container image.
    system_tags Mapping[str, Any]
    The 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 creation time of the version.
    time_last_pulled str
    An RFC 3339 timestamp indicating when the image was last pulled.
    version str
    The version name.
    versions Sequence[artifacts.GetContainerImageVersion]
    The versions associated with this image.
    compartmentId String
    The compartment OCID to which the container image belongs. Inferred from the container repository.
    createdBy String
    The OCID of the user or principal that pushed the version.
    definedTags Map<Any>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    digest String
    The sha256 digest of the image layer.
    displayName String
    The repository name and the most recent version associated with the image. If there are no versions associated with the image, then last known version and digest are used instead. If the last known version is unavailable, then 'unknown' is used instead of the version. Example: ubuntu:latest or ubuntu:latest@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2
    freeformTags Map<Any>
    Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    id String
    The provider-assigned unique ID for this managed resource.
    imageId String
    layers List<Property Map>
    Layers of which the image is composed, ordered by the layer digest.
    layersSizeInBytes String
    The total size of the container image layers in bytes.
    manifestSizeInBytes Number
    The size of the container image manifest in bytes.
    pullCount String
    Total number of pulls.
    repositoryId String
    The OCID of the container repository.
    repositoryName String
    The container repository name.
    state String
    The current state of the container image.
    systemTags Map<Any>
    The system tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The creation time of the version.
    timeLastPulled String
    An RFC 3339 timestamp indicating when the image was last pulled.
    version String
    The version name.
    versions List<Property Map>
    The versions associated with this image.

    Supporting Types

    GetContainerImageLayer

    Digest string
    The sha256 digest of the image layer.
    SizeInBytes string
    The size of the layer in bytes.
    TimeCreated string
    The creation time of the version.
    Digest string
    The sha256 digest of the image layer.
    SizeInBytes string
    The size of the layer in bytes.
    TimeCreated string
    The creation time of the version.
    digest String
    The sha256 digest of the image layer.
    sizeInBytes String
    The size of the layer in bytes.
    timeCreated String
    The creation time of the version.
    digest string
    The sha256 digest of the image layer.
    sizeInBytes string
    The size of the layer in bytes.
    timeCreated string
    The creation time of the version.
    digest str
    The sha256 digest of the image layer.
    size_in_bytes str
    The size of the layer in bytes.
    time_created str
    The creation time of the version.
    digest String
    The sha256 digest of the image layer.
    sizeInBytes String
    The size of the layer in bytes.
    timeCreated String
    The creation time of the version.

    GetContainerImageVersion

    CreatedBy string
    The OCID of the user or principal that pushed the version.
    TimeCreated string
    The creation time of the version.
    Version string
    The version name.
    CreatedBy string
    The OCID of the user or principal that pushed the version.
    TimeCreated string
    The creation time of the version.
    Version string
    The version name.
    createdBy String
    The OCID of the user or principal that pushed the version.
    timeCreated String
    The creation time of the version.
    version String
    The version name.
    createdBy string
    The OCID of the user or principal that pushed the version.
    timeCreated string
    The creation time of the version.
    version string
    The version name.
    created_by str
    The OCID of the user or principal that pushed the version.
    time_created str
    The creation time of the version.
    version str
    The version name.
    createdBy String
    The OCID of the user or principal that pushed the version.
    timeCreated String
    The creation time of the version.
    version String
    The version name.

    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 v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi