1. Packages
  2. OVH
  3. API Docs
  4. CloudProject
  5. WorkflowBackup
OVHCloud v1.1.0 published on Thursday, Nov 21, 2024 by OVHcloud

ovh.CloudProject.WorkflowBackup

Explore with Pulumi AI

ovh logo
OVHCloud v1.1.0 published on Thursday, Nov 21, 2024 by OVHcloud

    Manage a worflow that schedules backups of public cloud instance. Note that upon deletion, the workflow is deleted but any backups that have been created by this workflow are not.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@ovhcloud/pulumi-ovh";
    
    const myBackup = new ovh.cloudproject.WorkflowBackup("myBackup", {
        cron: "50 4 * * *",
        instanceId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx",
        maxExecutionCount: 0,
        regionName: "GRA11",
        rotation: 7,
        serviceName: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
    });
    
    import pulumi
    import pulumi_ovh as ovh
    
    my_backup = ovh.cloud_project.WorkflowBackup("myBackup",
        cron="50 4 * * *",
        instance_id="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx",
        max_execution_count=0,
        region_name="GRA11",
        rotation=7,
        service_name="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")
    
    package main
    
    import (
    	"github.com/ovh/pulumi-ovh/sdk/go/ovh/CloudProject"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := CloudProject.NewWorkflowBackup(ctx, "myBackup", &CloudProject.WorkflowBackupArgs{
    			Cron:              pulumi.String("50 4 * * *"),
    			InstanceId:        pulumi.String("xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx"),
    			MaxExecutionCount: pulumi.Int(0),
    			RegionName:        pulumi.String("GRA11"),
    			Rotation:          pulumi.Int(7),
    			ServiceName:       pulumi.String("xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var myBackup = new Ovh.CloudProject.WorkflowBackup("myBackup", new()
        {
            Cron = "50 4 * * *",
            InstanceId = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx",
            MaxExecutionCount = 0,
            RegionName = "GRA11",
            Rotation = 7,
            ServiceName = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ovh.CloudProject.WorkflowBackup;
    import com.pulumi.ovh.CloudProject.WorkflowBackupArgs;
    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 myBackup = new WorkflowBackup("myBackup", WorkflowBackupArgs.builder()
                .cron("50 4 * * *")
                .instanceId("xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx")
                .maxExecutionCount("0")
                .regionName("GRA11")
                .rotation("7")
                .serviceName("xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")
                .build());
    
        }
    }
    
    resources:
      myBackup:
        type: ovh:CloudProject:WorkflowBackup
        properties:
          cron: 50 4 * * *
          instanceId: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx
          maxExecutionCount: '0'
          regionName: GRA11
          rotation: '7'
          serviceName: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    

    Create WorkflowBackup Resource

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

    Constructor syntax

    new WorkflowBackup(name: string, args: WorkflowBackupArgs, opts?: CustomResourceOptions);
    @overload
    def WorkflowBackup(resource_name: str,
                       args: WorkflowBackupArgs,
                       opts: Optional[ResourceOptions] = None)
    
    @overload
    def WorkflowBackup(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       cron: Optional[str] = None,
                       instance_id: Optional[str] = None,
                       region_name: Optional[str] = None,
                       rotation: Optional[int] = None,
                       service_name: Optional[str] = None,
                       backup_name: Optional[str] = None,
                       max_execution_count: Optional[int] = None,
                       name: Optional[str] = None)
    func NewWorkflowBackup(ctx *Context, name string, args WorkflowBackupArgs, opts ...ResourceOption) (*WorkflowBackup, error)
    public WorkflowBackup(string name, WorkflowBackupArgs args, CustomResourceOptions? opts = null)
    public WorkflowBackup(String name, WorkflowBackupArgs args)
    public WorkflowBackup(String name, WorkflowBackupArgs args, CustomResourceOptions options)
    
    type: ovh:CloudProject:WorkflowBackup
    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 WorkflowBackupArgs
    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 WorkflowBackupArgs
    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 WorkflowBackupArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WorkflowBackupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WorkflowBackupArgs
    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 workflowBackupResource = new Ovh.CloudProject.WorkflowBackup("workflowBackupResource", new()
    {
        Cron = "string",
        InstanceId = "string",
        RegionName = "string",
        Rotation = 0,
        ServiceName = "string",
        BackupName = "string",
        MaxExecutionCount = 0,
        Name = "string",
    });
    
    example, err := CloudProject.NewWorkflowBackup(ctx, "workflowBackupResource", &CloudProject.WorkflowBackupArgs{
    	Cron:              pulumi.String("string"),
    	InstanceId:        pulumi.String("string"),
    	RegionName:        pulumi.String("string"),
    	Rotation:          pulumi.Int(0),
    	ServiceName:       pulumi.String("string"),
    	BackupName:        pulumi.String("string"),
    	MaxExecutionCount: pulumi.Int(0),
    	Name:              pulumi.String("string"),
    })
    
    var workflowBackupResource = new WorkflowBackup("workflowBackupResource", WorkflowBackupArgs.builder()
        .cron("string")
        .instanceId("string")
        .regionName("string")
        .rotation(0)
        .serviceName("string")
        .backupName("string")
        .maxExecutionCount(0)
        .name("string")
        .build());
    
    workflow_backup_resource = ovh.cloud_project.WorkflowBackup("workflowBackupResource",
        cron="string",
        instance_id="string",
        region_name="string",
        rotation=0,
        service_name="string",
        backup_name="string",
        max_execution_count=0,
        name="string")
    
    const workflowBackupResource = new ovh.cloudproject.WorkflowBackup("workflowBackupResource", {
        cron: "string",
        instanceId: "string",
        regionName: "string",
        rotation: 0,
        serviceName: "string",
        backupName: "string",
        maxExecutionCount: 0,
        name: "string",
    });
    
    type: ovh:CloudProject:WorkflowBackup
    properties:
        backupName: string
        cron: string
        instanceId: string
        maxExecutionCount: 0
        name: string
        regionName: string
        rotation: 0
        serviceName: string
    

    WorkflowBackup 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 WorkflowBackup resource accepts the following input properties:

    Cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    InstanceId string
    RegionName string
    The name of the openstack region.
    Rotation int
    The number of backup that are retained.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    BackupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    MaxExecutionCount int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    Name string
    The worflow name that is used in the UI
    Cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    InstanceId string
    RegionName string
    The name of the openstack region.
    Rotation int
    The number of backup that are retained.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    BackupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    MaxExecutionCount int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    Name string
    The worflow name that is used in the UI
    cron String
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId String
    regionName String
    The name of the openstack region.
    rotation Integer
    The number of backup that are retained.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName String
    The name of the backup files that are created. If empty, the name attribute is used.
    maxExecutionCount Integer
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name String
    The worflow name that is used in the UI
    cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId string
    regionName string
    The name of the openstack region.
    rotation number
    The number of backup that are retained.
    serviceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    maxExecutionCount number
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name string
    The worflow name that is used in the UI
    cron str
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instance_id str
    region_name str
    The name of the openstack region.
    rotation int
    The number of backup that are retained.
    service_name str
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backup_name str
    The name of the backup files that are created. If empty, the name attribute is used.
    max_execution_count int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name str
    The worflow name that is used in the UI
    cron String
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId String
    regionName String
    The name of the openstack region.
    rotation Number
    The number of backup that are retained.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName String
    The name of the backup files that are created. If empty, the name attribute is used.
    maxExecutionCount Number
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name String
    The worflow name that is used in the UI

    Outputs

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

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

    Look up Existing WorkflowBackup Resource

    Get an existing WorkflowBackup 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?: WorkflowBackupState, opts?: CustomResourceOptions): WorkflowBackup
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            backup_name: Optional[str] = None,
            created_at: Optional[str] = None,
            cron: Optional[str] = None,
            instance_id: Optional[str] = None,
            max_execution_count: Optional[int] = None,
            name: Optional[str] = None,
            region_name: Optional[str] = None,
            rotation: Optional[int] = None,
            service_name: Optional[str] = None) -> WorkflowBackup
    func GetWorkflowBackup(ctx *Context, name string, id IDInput, state *WorkflowBackupState, opts ...ResourceOption) (*WorkflowBackup, error)
    public static WorkflowBackup Get(string name, Input<string> id, WorkflowBackupState? state, CustomResourceOptions? opts = null)
    public static WorkflowBackup get(String name, Output<String> id, WorkflowBackupState 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:
    BackupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    CreatedAt string
    Cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    InstanceId string
    MaxExecutionCount int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    Name string
    The worflow name that is used in the UI
    RegionName string
    The name of the openstack region.
    Rotation int
    The number of backup that are retained.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    BackupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    CreatedAt string
    Cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    InstanceId string
    MaxExecutionCount int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    Name string
    The worflow name that is used in the UI
    RegionName string
    The name of the openstack region.
    Rotation int
    The number of backup that are retained.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName String
    The name of the backup files that are created. If empty, the name attribute is used.
    createdAt String
    cron String
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId String
    maxExecutionCount Integer
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name String
    The worflow name that is used in the UI
    regionName String
    The name of the openstack region.
    rotation Integer
    The number of backup that are retained.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName string
    The name of the backup files that are created. If empty, the name attribute is used.
    createdAt string
    cron string
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId string
    maxExecutionCount number
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name string
    The worflow name that is used in the UI
    regionName string
    The name of the openstack region.
    rotation number
    The number of backup that are retained.
    serviceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backup_name str
    The name of the backup files that are created. If empty, the name attribute is used.
    created_at str
    cron str
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instance_id str
    max_execution_count int
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name str
    The worflow name that is used in the UI
    region_name str
    The name of the openstack region.
    rotation int
    The number of backup that are retained.
    service_name str
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    backupName String
    The name of the backup files that are created. If empty, the name attribute is used.
    createdAt String
    cron String
    The cron periodicity at which the backup workflow is scheduled

    • instanceId the id of the instance to back up
    instanceId String
    maxExecutionCount Number
    The number of times the worflow is run. Default value is 0 which means that the workflow will be scheduled continously until its deletion
    name String
    The worflow name that is used in the UI
    regionName String
    The name of the openstack region.
    rotation Number
    The number of backup that are retained.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

    Package Details

    Repository
    ovh ovh/pulumi-ovh
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ovh Terraform Provider.
    ovh logo
    OVHCloud v1.1.0 published on Thursday, Nov 21, 2024 by OVHcloud