1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Core
  5. VolumeBackupPolicy
Oracle Cloud Infrastructure v1.31.0 published on Wednesday, Apr 10, 2024 by Pulumi

oci.Core.VolumeBackupPolicy

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.31.0 published on Wednesday, Apr 10, 2024 by Pulumi

    This resource provides the Volume Backup Policy resource in Oracle Cloud Infrastructure Core service.

    Creates a new user defined backup policy.

    For more information about Oracle defined backup policies and user defined backup policies, see Policy-Based Backups.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testVolumeBackupPolicy = new oci.core.VolumeBackupPolicy("testVolumeBackupPolicy", {
        compartmentId: _var.compartment_id,
        definedTags: {
            "Operations.CostCenter": "42",
        },
        destinationRegion: _var.volume_backup_policy_destination_region,
        displayName: _var.volume_backup_policy_display_name,
        freeformTags: {
            Department: "Finance",
        },
        schedules: [{
            backupType: _var.volume_backup_policy_schedules_backup_type,
            period: _var.volume_backup_policy_schedules_period,
            retentionSeconds: _var.volume_backup_policy_schedules_retention_seconds,
            dayOfMonth: _var.volume_backup_policy_schedules_day_of_month,
            dayOfWeek: _var.volume_backup_policy_schedules_day_of_week,
            hourOfDay: _var.volume_backup_policy_schedules_hour_of_day,
            month: _var.volume_backup_policy_schedules_month,
            offsetSeconds: _var.volume_backup_policy_schedules_offset_seconds,
            offsetType: _var.volume_backup_policy_schedules_offset_type,
            timeZone: _var.volume_backup_policy_schedules_time_zone,
        }],
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_volume_backup_policy = oci.core.VolumeBackupPolicy("testVolumeBackupPolicy",
        compartment_id=var["compartment_id"],
        defined_tags={
            "Operations.CostCenter": "42",
        },
        destination_region=var["volume_backup_policy_destination_region"],
        display_name=var["volume_backup_policy_display_name"],
        freeform_tags={
            "Department": "Finance",
        },
        schedules=[oci.core.VolumeBackupPolicyScheduleArgs(
            backup_type=var["volume_backup_policy_schedules_backup_type"],
            period=var["volume_backup_policy_schedules_period"],
            retention_seconds=var["volume_backup_policy_schedules_retention_seconds"],
            day_of_month=var["volume_backup_policy_schedules_day_of_month"],
            day_of_week=var["volume_backup_policy_schedules_day_of_week"],
            hour_of_day=var["volume_backup_policy_schedules_hour_of_day"],
            month=var["volume_backup_policy_schedules_month"],
            offset_seconds=var["volume_backup_policy_schedules_offset_seconds"],
            offset_type=var["volume_backup_policy_schedules_offset_type"],
            time_zone=var["volume_backup_policy_schedules_time_zone"],
        )])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Core"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Core.NewVolumeBackupPolicy(ctx, "testVolumeBackupPolicy", &Core.VolumeBackupPolicyArgs{
    			CompartmentId: pulumi.Any(_var.Compartment_id),
    			DefinedTags: pulumi.Map{
    				"Operations.CostCenter": pulumi.Any("42"),
    			},
    			DestinationRegion: pulumi.Any(_var.Volume_backup_policy_destination_region),
    			DisplayName:       pulumi.Any(_var.Volume_backup_policy_display_name),
    			FreeformTags: pulumi.Map{
    				"Department": pulumi.Any("Finance"),
    			},
    			Schedules: core.VolumeBackupPolicyScheduleArray{
    				&core.VolumeBackupPolicyScheduleArgs{
    					BackupType:       pulumi.Any(_var.Volume_backup_policy_schedules_backup_type),
    					Period:           pulumi.Any(_var.Volume_backup_policy_schedules_period),
    					RetentionSeconds: pulumi.Any(_var.Volume_backup_policy_schedules_retention_seconds),
    					DayOfMonth:       pulumi.Any(_var.Volume_backup_policy_schedules_day_of_month),
    					DayOfWeek:        pulumi.Any(_var.Volume_backup_policy_schedules_day_of_week),
    					HourOfDay:        pulumi.Any(_var.Volume_backup_policy_schedules_hour_of_day),
    					Month:            pulumi.Any(_var.Volume_backup_policy_schedules_month),
    					OffsetSeconds:    pulumi.Any(_var.Volume_backup_policy_schedules_offset_seconds),
    					OffsetType:       pulumi.Any(_var.Volume_backup_policy_schedules_offset_type),
    					TimeZone:         pulumi.Any(_var.Volume_backup_policy_schedules_time_zone),
    				},
    			},
    		})
    		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 testVolumeBackupPolicy = new Oci.Core.VolumeBackupPolicy("testVolumeBackupPolicy", new()
        {
            CompartmentId = @var.Compartment_id,
            DefinedTags = 
            {
                { "Operations.CostCenter", "42" },
            },
            DestinationRegion = @var.Volume_backup_policy_destination_region,
            DisplayName = @var.Volume_backup_policy_display_name,
            FreeformTags = 
            {
                { "Department", "Finance" },
            },
            Schedules = new[]
            {
                new Oci.Core.Inputs.VolumeBackupPolicyScheduleArgs
                {
                    BackupType = @var.Volume_backup_policy_schedules_backup_type,
                    Period = @var.Volume_backup_policy_schedules_period,
                    RetentionSeconds = @var.Volume_backup_policy_schedules_retention_seconds,
                    DayOfMonth = @var.Volume_backup_policy_schedules_day_of_month,
                    DayOfWeek = @var.Volume_backup_policy_schedules_day_of_week,
                    HourOfDay = @var.Volume_backup_policy_schedules_hour_of_day,
                    Month = @var.Volume_backup_policy_schedules_month,
                    OffsetSeconds = @var.Volume_backup_policy_schedules_offset_seconds,
                    OffsetType = @var.Volume_backup_policy_schedules_offset_type,
                    TimeZone = @var.Volume_backup_policy_schedules_time_zone,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Core.VolumeBackupPolicy;
    import com.pulumi.oci.Core.VolumeBackupPolicyArgs;
    import com.pulumi.oci.Core.inputs.VolumeBackupPolicyScheduleArgs;
    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 testVolumeBackupPolicy = new VolumeBackupPolicy("testVolumeBackupPolicy", VolumeBackupPolicyArgs.builder()        
                .compartmentId(var_.compartment_id())
                .definedTags(Map.of("Operations.CostCenter", "42"))
                .destinationRegion(var_.volume_backup_policy_destination_region())
                .displayName(var_.volume_backup_policy_display_name())
                .freeformTags(Map.of("Department", "Finance"))
                .schedules(VolumeBackupPolicyScheduleArgs.builder()
                    .backupType(var_.volume_backup_policy_schedules_backup_type())
                    .period(var_.volume_backup_policy_schedules_period())
                    .retentionSeconds(var_.volume_backup_policy_schedules_retention_seconds())
                    .dayOfMonth(var_.volume_backup_policy_schedules_day_of_month())
                    .dayOfWeek(var_.volume_backup_policy_schedules_day_of_week())
                    .hourOfDay(var_.volume_backup_policy_schedules_hour_of_day())
                    .month(var_.volume_backup_policy_schedules_month())
                    .offsetSeconds(var_.volume_backup_policy_schedules_offset_seconds())
                    .offsetType(var_.volume_backup_policy_schedules_offset_type())
                    .timeZone(var_.volume_backup_policy_schedules_time_zone())
                    .build())
                .build());
    
        }
    }
    
    resources:
      testVolumeBackupPolicy:
        type: oci:Core:VolumeBackupPolicy
        properties:
          #Required
          compartmentId: ${var.compartment_id}
          #Optional
          definedTags:
            Operations.CostCenter: '42'
          destinationRegion: ${var.volume_backup_policy_destination_region}
          displayName: ${var.volume_backup_policy_display_name}
          freeformTags:
            Department: Finance
          schedules:
            - backupType: ${var.volume_backup_policy_schedules_backup_type}
              period: ${var.volume_backup_policy_schedules_period}
              retentionSeconds: ${var.volume_backup_policy_schedules_retention_seconds}
              dayOfMonth: ${var.volume_backup_policy_schedules_day_of_month}
              dayOfWeek: ${var.volume_backup_policy_schedules_day_of_week}
              hourOfDay: ${var.volume_backup_policy_schedules_hour_of_day}
              month: ${var.volume_backup_policy_schedules_month}
              offsetSeconds: ${var.volume_backup_policy_schedules_offset_seconds}
              offsetType: ${var.volume_backup_policy_schedules_offset_type}
              timeZone: ${var.volume_backup_policy_schedules_time_zone}
    

    Create VolumeBackupPolicy Resource

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

    Constructor syntax

    new VolumeBackupPolicy(name: string, args: VolumeBackupPolicyArgs, opts?: CustomResourceOptions);
    @overload
    def VolumeBackupPolicy(resource_name: str,
                           args: VolumeBackupPolicyArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def VolumeBackupPolicy(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           compartment_id: Optional[str] = None,
                           defined_tags: Optional[Mapping[str, Any]] = None,
                           destination_region: Optional[str] = None,
                           display_name: Optional[str] = None,
                           freeform_tags: Optional[Mapping[str, Any]] = None,
                           schedules: Optional[Sequence[_core.VolumeBackupPolicyScheduleArgs]] = None)
    func NewVolumeBackupPolicy(ctx *Context, name string, args VolumeBackupPolicyArgs, opts ...ResourceOption) (*VolumeBackupPolicy, error)
    public VolumeBackupPolicy(string name, VolumeBackupPolicyArgs args, CustomResourceOptions? opts = null)
    public VolumeBackupPolicy(String name, VolumeBackupPolicyArgs args)
    public VolumeBackupPolicy(String name, VolumeBackupPolicyArgs args, CustomResourceOptions options)
    
    type: oci:Core:VolumeBackupPolicy
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

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

    Example

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

    var volumeBackupPolicyResource = new Oci.Core.VolumeBackupPolicy("volumeBackupPolicyResource", new()
    {
        CompartmentId = "string",
        DefinedTags = 
        {
            { "string", "any" },
        },
        DestinationRegion = "string",
        DisplayName = "string",
        FreeformTags = 
        {
            { "string", "any" },
        },
        Schedules = new[]
        {
            new Oci.Core.Inputs.VolumeBackupPolicyScheduleArgs
            {
                BackupType = "string",
                Period = "string",
                RetentionSeconds = 0,
                DayOfMonth = 0,
                DayOfWeek = "string",
                HourOfDay = 0,
                Month = "string",
                OffsetSeconds = 0,
                OffsetType = "string",
                TimeZone = "string",
            },
        },
    });
    
    example, err := Core.NewVolumeBackupPolicy(ctx, "volumeBackupPolicyResource", &Core.VolumeBackupPolicyArgs{
    	CompartmentId: pulumi.String("string"),
    	DefinedTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	DestinationRegion: pulumi.String("string"),
    	DisplayName:       pulumi.String("string"),
    	FreeformTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	Schedules: core.VolumeBackupPolicyScheduleArray{
    		&core.VolumeBackupPolicyScheduleArgs{
    			BackupType:       pulumi.String("string"),
    			Period:           pulumi.String("string"),
    			RetentionSeconds: pulumi.Int(0),
    			DayOfMonth:       pulumi.Int(0),
    			DayOfWeek:        pulumi.String("string"),
    			HourOfDay:        pulumi.Int(0),
    			Month:            pulumi.String("string"),
    			OffsetSeconds:    pulumi.Int(0),
    			OffsetType:       pulumi.String("string"),
    			TimeZone:         pulumi.String("string"),
    		},
    	},
    })
    
    var volumeBackupPolicyResource = new VolumeBackupPolicy("volumeBackupPolicyResource", VolumeBackupPolicyArgs.builder()        
        .compartmentId("string")
        .definedTags(Map.of("string", "any"))
        .destinationRegion("string")
        .displayName("string")
        .freeformTags(Map.of("string", "any"))
        .schedules(VolumeBackupPolicyScheduleArgs.builder()
            .backupType("string")
            .period("string")
            .retentionSeconds(0)
            .dayOfMonth(0)
            .dayOfWeek("string")
            .hourOfDay(0)
            .month("string")
            .offsetSeconds(0)
            .offsetType("string")
            .timeZone("string")
            .build())
        .build());
    
    volume_backup_policy_resource = oci.core.VolumeBackupPolicy("volumeBackupPolicyResource",
        compartment_id="string",
        defined_tags={
            "string": "any",
        },
        destination_region="string",
        display_name="string",
        freeform_tags={
            "string": "any",
        },
        schedules=[oci.core.VolumeBackupPolicyScheduleArgs(
            backup_type="string",
            period="string",
            retention_seconds=0,
            day_of_month=0,
            day_of_week="string",
            hour_of_day=0,
            month="string",
            offset_seconds=0,
            offset_type="string",
            time_zone="string",
        )])
    
    const volumeBackupPolicyResource = new oci.core.VolumeBackupPolicy("volumeBackupPolicyResource", {
        compartmentId: "string",
        definedTags: {
            string: "any",
        },
        destinationRegion: "string",
        displayName: "string",
        freeformTags: {
            string: "any",
        },
        schedules: [{
            backupType: "string",
            period: "string",
            retentionSeconds: 0,
            dayOfMonth: 0,
            dayOfWeek: "string",
            hourOfDay: 0,
            month: "string",
            offsetSeconds: 0,
            offsetType: "string",
            timeZone: "string",
        }],
    });
    
    type: oci:Core:VolumeBackupPolicy
    properties:
        compartmentId: string
        definedTags:
            string: any
        destinationRegion: string
        displayName: string
        freeformTags:
            string: any
        schedules:
            - backupType: string
              dayOfMonth: 0
              dayOfWeek: string
              hourOfDay: 0
              month: string
              offsetSeconds: 0
              offsetType: string
              period: string
              retentionSeconds: 0
              timeZone: string
    

    VolumeBackupPolicy Resource Properties

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

    Inputs

    The VolumeBackupPolicy resource accepts the following input properties:

    CompartmentId string
    The OCID of the compartment.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DestinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    FreeformTags Dictionary<string, object>
    (Updatable) 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"}
    Schedules List<VolumeBackupPolicySchedule>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    CompartmentId string
    The OCID of the compartment.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DestinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    FreeformTags map[string]interface{}
    (Updatable) 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"}
    Schedules []VolumeBackupPolicyScheduleArgs
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion String
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags Map<String,Object>
    (Updatable) 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"}
    schedules List<VolumeBackupPolicySchedule>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    compartmentId string
    The OCID of the compartment.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags {[key: string]: any}
    (Updatable) 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"}
    schedules VolumeBackupPolicySchedule[]
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    compartment_id str
    The OCID of the compartment.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destination_region str
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    display_name str
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeform_tags Mapping[str, Any]
    (Updatable) 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"}
    schedules Sequence[core.VolumeBackupPolicyScheduleArgs]
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion String
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags Map<Any>
    (Updatable) 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"}
    schedules List<Property Map>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    TimeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    Id string
    The provider-assigned unique ID for this managed resource.
    TimeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    id String
    The provider-assigned unique ID for this managed resource.
    timeCreated String
    The date and time the volume backup policy was created. Format defined by RFC3339.
    id string
    The provider-assigned unique ID for this managed resource.
    timeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    id str
    The provider-assigned unique ID for this managed resource.
    time_created str
    The date and time the volume backup policy was created. Format defined by RFC3339.
    id String
    The provider-assigned unique ID for this managed resource.
    timeCreated String
    The date and time the volume backup policy was created. Format defined by RFC3339.

    Look up Existing VolumeBackupPolicy Resource

    Get an existing VolumeBackupPolicy 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?: VolumeBackupPolicyState, opts?: CustomResourceOptions): VolumeBackupPolicy
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            compartment_id: Optional[str] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            destination_region: Optional[str] = None,
            display_name: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            schedules: Optional[Sequence[_core.VolumeBackupPolicyScheduleArgs]] = None,
            time_created: Optional[str] = None) -> VolumeBackupPolicy
    func GetVolumeBackupPolicy(ctx *Context, name string, id IDInput, state *VolumeBackupPolicyState, opts ...ResourceOption) (*VolumeBackupPolicy, error)
    public static VolumeBackupPolicy Get(string name, Input<string> id, VolumeBackupPolicyState? state, CustomResourceOptions? opts = null)
    public static VolumeBackupPolicy get(String name, Output<String> id, VolumeBackupPolicyState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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:
    CompartmentId string
    The OCID of the compartment.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DestinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    FreeformTags Dictionary<string, object>
    (Updatable) 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"}
    Schedules List<VolumeBackupPolicySchedule>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    TimeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    CompartmentId string
    The OCID of the compartment.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DestinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    FreeformTags map[string]interface{}
    (Updatable) 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"}
    Schedules []VolumeBackupPolicyScheduleArgs
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    TimeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion String
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags Map<String,Object>
    (Updatable) 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"}
    schedules List<VolumeBackupPolicySchedule>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    timeCreated String
    The date and time the volume backup policy was created. Format defined by RFC3339.
    compartmentId string
    The OCID of the compartment.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion string
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags {[key: string]: any}
    (Updatable) 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"}
    schedules VolumeBackupPolicySchedule[]
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    timeCreated string
    The date and time the volume backup policy was created. Format defined by RFC3339.
    compartment_id str
    The OCID of the compartment.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destination_region str
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    display_name str
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeform_tags Mapping[str, Any]
    (Updatable) 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"}
    schedules Sequence[core.VolumeBackupPolicyScheduleArgs]
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    time_created str
    The date and time the volume backup policy was created. Format defined by RFC3339.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    destinationRegion String
    (Updatable) The paired destination region for copying scheduled backups to. Example: us-ashburn-1. See Region Pairs for details about paired regions.
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    freeformTags Map<Any>
    (Updatable) 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"}
    schedules List<Property Map>
    (Updatable) The collection of schedules for the volume backup policy. See see Schedules in Policy-Based Backups for more information.
    timeCreated String
    The date and time the volume backup policy was created. Format defined by RFC3339.

    Supporting Types

    VolumeBackupPolicySchedule, VolumeBackupPolicyScheduleArgs

    BackupType string
    (Updatable) The type of volume backup to create.
    Period string
    (Updatable) The volume backup frequency.
    RetentionSeconds int
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    DayOfMonth int
    (Updatable) The day of the month to schedule the volume backup.
    DayOfWeek string
    (Updatable) The day of the week to schedule the volume backup.
    HourOfDay int
    (Updatable) The hour of the day to schedule the volume backup.
    Month string
    (Updatable) The month of the year to schedule the volume backup.
    OffsetSeconds int
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    OffsetType string

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    TimeZone string
    (Updatable) Specifies what time zone is the schedule in enum:
    BackupType string
    (Updatable) The type of volume backup to create.
    Period string
    (Updatable) The volume backup frequency.
    RetentionSeconds int
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    DayOfMonth int
    (Updatable) The day of the month to schedule the volume backup.
    DayOfWeek string
    (Updatable) The day of the week to schedule the volume backup.
    HourOfDay int
    (Updatable) The hour of the day to schedule the volume backup.
    Month string
    (Updatable) The month of the year to schedule the volume backup.
    OffsetSeconds int
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    OffsetType string

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    TimeZone string
    (Updatable) Specifies what time zone is the schedule in enum:
    backupType String
    (Updatable) The type of volume backup to create.
    period String
    (Updatable) The volume backup frequency.
    retentionSeconds Integer
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    dayOfMonth Integer
    (Updatable) The day of the month to schedule the volume backup.
    dayOfWeek String
    (Updatable) The day of the week to schedule the volume backup.
    hourOfDay Integer
    (Updatable) The hour of the day to schedule the volume backup.
    month String
    (Updatable) The month of the year to schedule the volume backup.
    offsetSeconds Integer
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    offsetType String

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    timeZone String
    (Updatable) Specifies what time zone is the schedule in enum:
    backupType string
    (Updatable) The type of volume backup to create.
    period string
    (Updatable) The volume backup frequency.
    retentionSeconds number
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    dayOfMonth number
    (Updatable) The day of the month to schedule the volume backup.
    dayOfWeek string
    (Updatable) The day of the week to schedule the volume backup.
    hourOfDay number
    (Updatable) The hour of the day to schedule the volume backup.
    month string
    (Updatable) The month of the year to schedule the volume backup.
    offsetSeconds number
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    offsetType string

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    timeZone string
    (Updatable) Specifies what time zone is the schedule in enum:
    backup_type str
    (Updatable) The type of volume backup to create.
    period str
    (Updatable) The volume backup frequency.
    retention_seconds int
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    day_of_month int
    (Updatable) The day of the month to schedule the volume backup.
    day_of_week str
    (Updatable) The day of the week to schedule the volume backup.
    hour_of_day int
    (Updatable) The hour of the day to schedule the volume backup.
    month str
    (Updatable) The month of the year to schedule the volume backup.
    offset_seconds int
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    offset_type str

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    time_zone str
    (Updatable) Specifies what time zone is the schedule in enum:
    backupType String
    (Updatable) The type of volume backup to create.
    period String
    (Updatable) The volume backup frequency.
    retentionSeconds Number
    (Updatable) How long, in seconds, to keep the volume backups created by this schedule.
    dayOfMonth Number
    (Updatable) The day of the month to schedule the volume backup.
    dayOfWeek String
    (Updatable) The day of the week to schedule the volume backup.
    hourOfDay Number
    (Updatable) The hour of the day to schedule the volume backup.
    month String
    (Updatable) The month of the year to schedule the volume backup.
    offsetSeconds Number
    (Updatable) The number of seconds that the volume backup start time should be shifted from the default interval boundaries specified by the period. The volume backup start time is the frequency start time plus the offset.
    offsetType String

    (Updatable) Indicates how the offset is defined. If value is STRUCTURED, then hourOfDay, dayOfWeek, dayOfMonth, and month fields are used and offsetSeconds will be ignored in requests and users should ignore its value from the responses.

    hourOfDay is applicable for periods ONE_DAY, ONE_WEEK, ONE_MONTH and ONE_YEAR.

    dayOfWeek is applicable for period ONE_WEEK.

    dayOfMonth is applicable for periods ONE_MONTH and ONE_YEAR.

    'month' is applicable for period 'ONE_YEAR'.

    They will be ignored in the requests for inapplicable periods.

    If value is NUMERIC_SECONDS, then offsetSeconds will be used for both requests and responses and the structured fields will be ignored in the requests and users should ignore their values from the responses.

    For clients using older versions of Apis and not sending offsetType in their requests, the behaviour is just like NUMERIC_SECONDS.

    timeZone String
    (Updatable) Specifies what time zone is the schedule in enum:

    Import

    VolumeBackupPolicies can be imported using the id, e.g.

    $ pulumi import oci:Core/volumeBackupPolicy:VolumeBackupPolicy test_volume_backup_policy "id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    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.31.0 published on Wednesday, Apr 10, 2024 by Pulumi