1. Packages
  2. Ibm Provider
  3. API Docs
  4. PiImageExport
ibm 1.77.1 published on Monday, Apr 14, 2025 by ibm-cloud

ibm.PiImageExport

Explore with Pulumi AI

Export an image to IBM Cloud Object Storage for Power Systems Virtual Server instance. For more information, about IBM power virtual server cloud, see getting started with IBM Power Systems Virtual Servers.

Example Usage

The following example enables you to export an image:

import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";

const testaccImageExport = new ibm.PiImageExport("testaccImageExport", {
    piCloudInstanceId: "<value of the cloud_instance_id>",
    piImageAccessKey: "dummy-access-key",
    piImageBucketName: "images-public-bucket",
    piImageBucketRegion: "us-south",
    piImageId: "test_image",
    piImageSecretKey: "dummy-secret-key",
});
Copy
import pulumi
import pulumi_ibm as ibm

testacc_image_export = ibm.PiImageExport("testaccImageExport",
    pi_cloud_instance_id="<value of the cloud_instance_id>",
    pi_image_access_key="dummy-access-key",
    pi_image_bucket_name="images-public-bucket",
    pi_image_bucket_region="us-south",
    pi_image_id="test_image",
    pi_image_secret_key="dummy-secret-key")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ibm.NewPiImageExport(ctx, "testaccImageExport", &ibm.PiImageExportArgs{
			PiCloudInstanceId:   pulumi.String("<value of the cloud_instance_id>"),
			PiImageAccessKey:    pulumi.String("dummy-access-key"),
			PiImageBucketName:   pulumi.String("images-public-bucket"),
			PiImageBucketRegion: pulumi.String("us-south"),
			PiImageId:           pulumi.String("test_image"),
			PiImageSecretKey:    pulumi.String("dummy-secret-key"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;

return await Deployment.RunAsync(() => 
{
    var testaccImageExport = new Ibm.PiImageExport("testaccImageExport", new()
    {
        PiCloudInstanceId = "<value of the cloud_instance_id>",
        PiImageAccessKey = "dummy-access-key",
        PiImageBucketName = "images-public-bucket",
        PiImageBucketRegion = "us-south",
        PiImageId = "test_image",
        PiImageSecretKey = "dummy-secret-key",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.PiImageExport;
import com.pulumi.ibm.PiImageExportArgs;
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) {
        var testaccImageExport = new PiImageExport("testaccImageExport", PiImageExportArgs.builder()
            .piCloudInstanceId("<value of the cloud_instance_id>")
            .piImageAccessKey("dummy-access-key")
            .piImageBucketName("images-public-bucket")
            .piImageBucketRegion("us-south")
            .piImageId("test_image")
            .piImageSecretKey("dummy-secret-key")
            .build());

    }
}
Copy
resources:
  testaccImageExport:
    type: ibm:PiImageExport
    properties:
      piCloudInstanceId: <value of the cloud_instance_id>
      piImageAccessKey: dummy-access-key
      piImageBucketName: images-public-bucket
      piImageBucketRegion: us-south
      piImageId: test_image
      piImageSecretKey: dummy-secret-key
Copy

Notes

  • Ensure the exported file is cleaned up manually from the Cloud Object Storage when no longer needed. Power Systems Virtual Server does not support deleting the exported image. Updating any attribute will result in creating a new Export job.
  • Please find supported Regions for endpoints.
  • If a Power cloud instance is provisioned at lon04, The provider level attributes should be as follows:
    • region - lon
    • zone - lon04

Example usage:

import * as pulumi from "@pulumi/pulumi";
Copy
import pulumi
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;

return await Deployment.RunAsync(() => 
{
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
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) {
    }
}
Copy
{}
Copy

Create PiImageExport Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new PiImageExport(name: string, args: PiImageExportArgs, opts?: CustomResourceOptions);
@overload
def PiImageExport(resource_name: str,
                  args: PiImageExportArgs,
                  opts: Optional[ResourceOptions] = None)

@overload
def PiImageExport(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  pi_cloud_instance_id: Optional[str] = None,
                  pi_image_access_key: Optional[str] = None,
                  pi_image_bucket_name: Optional[str] = None,
                  pi_image_bucket_region: Optional[str] = None,
                  pi_image_id: Optional[str] = None,
                  pi_image_secret_key: Optional[str] = None,
                  pi_image_export_id: Optional[str] = None,
                  timeouts: Optional[PiImageExportTimeoutsArgs] = None)
func NewPiImageExport(ctx *Context, name string, args PiImageExportArgs, opts ...ResourceOption) (*PiImageExport, error)
public PiImageExport(string name, PiImageExportArgs args, CustomResourceOptions? opts = null)
public PiImageExport(String name, PiImageExportArgs args)
public PiImageExport(String name, PiImageExportArgs args, CustomResourceOptions options)
type: ibm:PiImageExport
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. PiImageExportArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. PiImageExportArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. PiImageExportArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. PiImageExportArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. PiImageExportArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var piImageExportResource = new Ibm.PiImageExport("piImageExportResource", new()
{
    PiCloudInstanceId = "string",
    PiImageAccessKey = "string",
    PiImageBucketName = "string",
    PiImageBucketRegion = "string",
    PiImageId = "string",
    PiImageSecretKey = "string",
    PiImageExportId = "string",
    Timeouts = new Ibm.Inputs.PiImageExportTimeoutsArgs
    {
        Create = "string",
    },
});
Copy
example, err := ibm.NewPiImageExport(ctx, "piImageExportResource", &ibm.PiImageExportArgs{
PiCloudInstanceId: pulumi.String("string"),
PiImageAccessKey: pulumi.String("string"),
PiImageBucketName: pulumi.String("string"),
PiImageBucketRegion: pulumi.String("string"),
PiImageId: pulumi.String("string"),
PiImageSecretKey: pulumi.String("string"),
PiImageExportId: pulumi.String("string"),
Timeouts: &.PiImageExportTimeoutsArgs{
Create: pulumi.String("string"),
},
})
Copy
var piImageExportResource = new PiImageExport("piImageExportResource", PiImageExportArgs.builder()
    .piCloudInstanceId("string")
    .piImageAccessKey("string")
    .piImageBucketName("string")
    .piImageBucketRegion("string")
    .piImageId("string")
    .piImageSecretKey("string")
    .piImageExportId("string")
    .timeouts(PiImageExportTimeoutsArgs.builder()
        .create("string")
        .build())
    .build());
Copy
pi_image_export_resource = ibm.PiImageExport("piImageExportResource",
    pi_cloud_instance_id="string",
    pi_image_access_key="string",
    pi_image_bucket_name="string",
    pi_image_bucket_region="string",
    pi_image_id="string",
    pi_image_secret_key="string",
    pi_image_export_id="string",
    timeouts={
        "create": "string",
    })
Copy
const piImageExportResource = new ibm.PiImageExport("piImageExportResource", {
    piCloudInstanceId: "string",
    piImageAccessKey: "string",
    piImageBucketName: "string",
    piImageBucketRegion: "string",
    piImageId: "string",
    piImageSecretKey: "string",
    piImageExportId: "string",
    timeouts: {
        create: "string",
    },
});
Copy
type: ibm:PiImageExport
properties:
    piCloudInstanceId: string
    piImageAccessKey: string
    piImageBucketName: string
    piImageBucketRegion: string
    piImageExportId: string
    piImageId: string
    piImageSecretKey: string
    timeouts:
        create: string
Copy

PiImageExport Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The PiImageExport resource accepts the following input properties:

PiCloudInstanceId This property is required. string
The GUID of the service instance associated with an account.
PiImageAccessKey This property is required. string
The Cloud Object Storage access key; required for buckets with private access.
PiImageBucketName This property is required. string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
PiImageBucketRegion This property is required. string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
PiImageId This property is required. string
The Image ID of existing source image; required for image export.
PiImageSecretKey This property is required. string
The Cloud Object Storage secret key; required for buckets with private access.
PiImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
Timeouts PiImageExportTimeouts
PiCloudInstanceId This property is required. string
The GUID of the service instance associated with an account.
PiImageAccessKey This property is required. string
The Cloud Object Storage access key; required for buckets with private access.
PiImageBucketName This property is required. string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
PiImageBucketRegion This property is required. string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
PiImageId This property is required. string
The Image ID of existing source image; required for image export.
PiImageSecretKey This property is required. string
The Cloud Object Storage secret key; required for buckets with private access.
PiImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
Timeouts PiImageExportTimeoutsArgs
piCloudInstanceId This property is required. String
The GUID of the service instance associated with an account.
piImageAccessKey This property is required. String
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName This property is required. String
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion This property is required. String
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageId This property is required. String
The Image ID of existing source image; required for image export.
piImageSecretKey This property is required. String
The Cloud Object Storage secret key; required for buckets with private access.
piImageExportId String
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
timeouts PiImageExportTimeouts
piCloudInstanceId This property is required. string
The GUID of the service instance associated with an account.
piImageAccessKey This property is required. string
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName This property is required. string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion This property is required. string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageId This property is required. string
The Image ID of existing source image; required for image export.
piImageSecretKey This property is required. string
The Cloud Object Storage secret key; required for buckets with private access.
piImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
timeouts PiImageExportTimeouts
pi_cloud_instance_id This property is required. str
The GUID of the service instance associated with an account.
pi_image_access_key This property is required. str
The Cloud Object Storage access key; required for buckets with private access.
pi_image_bucket_name This property is required. str
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
pi_image_bucket_region This property is required. str
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
pi_image_id This property is required. str
The Image ID of existing source image; required for image export.
pi_image_secret_key This property is required. str
The Cloud Object Storage secret key; required for buckets with private access.
pi_image_export_id str
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
timeouts PiImageExportTimeoutsArgs
piCloudInstanceId This property is required. String
The GUID of the service instance associated with an account.
piImageAccessKey This property is required. String
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName This property is required. String
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion This property is required. String
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageId This property is required. String
The Image ID of existing source image; required for image export.
piImageSecretKey This property is required. String
The Cloud Object Storage secret key; required for buckets with private access.
piImageExportId String
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
timeouts Property Map

Outputs

All input properties are implicitly available as output properties. Additionally, the PiImageExport resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing PiImageExport Resource

Get an existing PiImageExport resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: PiImageExportState, opts?: CustomResourceOptions): PiImageExport
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        pi_cloud_instance_id: Optional[str] = None,
        pi_image_access_key: Optional[str] = None,
        pi_image_bucket_name: Optional[str] = None,
        pi_image_bucket_region: Optional[str] = None,
        pi_image_export_id: Optional[str] = None,
        pi_image_id: Optional[str] = None,
        pi_image_secret_key: Optional[str] = None,
        timeouts: Optional[PiImageExportTimeoutsArgs] = None) -> PiImageExport
func GetPiImageExport(ctx *Context, name string, id IDInput, state *PiImageExportState, opts ...ResourceOption) (*PiImageExport, error)
public static PiImageExport Get(string name, Input<string> id, PiImageExportState? state, CustomResourceOptions? opts = null)
public static PiImageExport get(String name, Output<String> id, PiImageExportState state, CustomResourceOptions options)
resources:  _:    type: ibm:PiImageExport    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
PiCloudInstanceId string
The GUID of the service instance associated with an account.
PiImageAccessKey string
The Cloud Object Storage access key; required for buckets with private access.
PiImageBucketName string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
PiImageBucketRegion string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
PiImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
PiImageId string
The Image ID of existing source image; required for image export.
PiImageSecretKey string
The Cloud Object Storage secret key; required for buckets with private access.
Timeouts PiImageExportTimeouts
PiCloudInstanceId string
The GUID of the service instance associated with an account.
PiImageAccessKey string
The Cloud Object Storage access key; required for buckets with private access.
PiImageBucketName string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
PiImageBucketRegion string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
PiImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
PiImageId string
The Image ID of existing source image; required for image export.
PiImageSecretKey string
The Cloud Object Storage secret key; required for buckets with private access.
Timeouts PiImageExportTimeoutsArgs
piCloudInstanceId String
The GUID of the service instance associated with an account.
piImageAccessKey String
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName String
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion String
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageExportId String
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
piImageId String
The Image ID of existing source image; required for image export.
piImageSecretKey String
The Cloud Object Storage secret key; required for buckets with private access.
timeouts PiImageExportTimeouts
piCloudInstanceId string
The GUID of the service instance associated with an account.
piImageAccessKey string
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName string
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion string
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageExportId string
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
piImageId string
The Image ID of existing source image; required for image export.
piImageSecretKey string
The Cloud Object Storage secret key; required for buckets with private access.
timeouts PiImageExportTimeouts
pi_cloud_instance_id str
The GUID of the service instance associated with an account.
pi_image_access_key str
The Cloud Object Storage access key; required for buckets with private access.
pi_image_bucket_name str
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
pi_image_bucket_region str
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
pi_image_export_id str
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
pi_image_id str
The Image ID of existing source image; required for image export.
pi_image_secret_key str
The Cloud Object Storage secret key; required for buckets with private access.
timeouts PiImageExportTimeoutsArgs
piCloudInstanceId String
The GUID of the service instance associated with an account.
piImageAccessKey String
The Cloud Object Storage access key; required for buckets with private access.
piImageBucketName String
The Cloud Object Storage bucket name; bucket-name[/optional/folder]
piImageBucketRegion String
The Cloud Object Storage region. Supported COS regions are:au-syd, br-sao, ca-tor, che01, eu-de, eu-es, eu-gb, jp-osa, jp-tok, us-east, us-south.
piImageExportId String
(String) The unique identifier of an image export resource. The ID is composed of <image_id>/<bucket_name>/<bucket_region>.
piImageId String
The Image ID of existing source image; required for image export.
piImageSecretKey String
The Cloud Object Storage secret key; required for buckets with private access.
timeouts Property Map

Supporting Types

PiImageExportTimeouts
, PiImageExportTimeoutsArgs

Create string
Create string
create String
create string
create str
create String

Package Details

Repository
ibm ibm-cloud/terraform-provider-ibm
License
Notes
This Pulumi package is based on the ibm Terraform Provider.