1. Packages
  2. Ionoscloud
  3. API Docs
  4. dbaas
  5. getMariaDBBackups
IonosCloud v0.2.3 published on Tuesday, May 13, 2025 by ionos-cloud

ionoscloud.dbaas.getMariaDBBackups

Explore with Pulumi AI

ionoscloud logo
IonosCloud v0.2.3 published on Tuesday, May 13, 2025 by ionos-cloud

    The DBaaS MariaDB Backups data source can be used to search for and return existing DBaaS MariaDB Backups for a specific cluster.

    Example Usage

    Get all backups for a specific cluster

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@pulumi/ionoscloud";
    
    const example = ionoscloud.dbaas.getMariaDBBackups({
        clusterId: "cluster_id",
        location: "de/txl",
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    
    example = ionoscloud.dbaas.get_maria_db_backups(cluster_id="cluster_id",
        location="de/txl")
    
    package main
    
    import (
    	"github.com/ionos-cloud/pulumi-ionoscloud/sdk/go/ionoscloud/dbaas"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dbaas.GetMariaDBBackups(ctx, &dbaas.GetMariaDBBackupsArgs{
    			ClusterId: pulumi.StringRef("cluster_id"),
    			Location:  pulumi.StringRef("de/txl"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ionoscloud = Pulumi.Ionoscloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Ionoscloud.Dbaas.GetMariaDBBackups.Invoke(new()
        {
            ClusterId = "cluster_id",
            Location = "de/txl",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ionoscloud.dbaas.DbaasFunctions;
    import com.pulumi.ionoscloud.dbaas.inputs.GetMariaDBBackupsArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = DbaasFunctions.getMariaDBBackups(GetMariaDBBackupsArgs.builder()
                .clusterId("cluster_id")
                .location("de/txl")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ionoscloud:dbaas:getMariaDBBackups
          arguments:
            clusterId: cluster_id
            location: de/txl
    

    Get a specific backup

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@pulumi/ionoscloud";
    
    const example = ionoscloud.dbaas.getMariaDBBackups({
        backupId: "backup_id",
        location: "de/txl",
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    
    example = ionoscloud.dbaas.get_maria_db_backups(backup_id="backup_id",
        location="de/txl")
    
    package main
    
    import (
    	"github.com/ionos-cloud/pulumi-ionoscloud/sdk/go/ionoscloud/dbaas"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dbaas.GetMariaDBBackups(ctx, &dbaas.GetMariaDBBackupsArgs{
    			BackupId: pulumi.StringRef("backup_id"),
    			Location: pulumi.StringRef("de/txl"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ionoscloud = Pulumi.Ionoscloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Ionoscloud.Dbaas.GetMariaDBBackups.Invoke(new()
        {
            BackupId = "backup_id",
            Location = "de/txl",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ionoscloud.dbaas.DbaasFunctions;
    import com.pulumi.ionoscloud.dbaas.inputs.GetMariaDBBackupsArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = DbaasFunctions.getMariaDBBackups(GetMariaDBBackupsArgs.builder()
                .backupId("backup_id")
                .location("de/txl")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ionoscloud:dbaas:getMariaDBBackups
          arguments:
            backupId: backup_id
            location: de/txl
    

    Using getMariaDBBackups

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getMariaDBBackups(args: GetMariaDBBackupsArgs, opts?: InvokeOptions): Promise<GetMariaDBBackupsResult>
    function getMariaDBBackupsOutput(args: GetMariaDBBackupsOutputArgs, opts?: InvokeOptions): Output<GetMariaDBBackupsResult>
    def get_maria_db_backups(backup_id: Optional[str] = None,
                             cluster_id: Optional[str] = None,
                             location: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetMariaDBBackupsResult
    def get_maria_db_backups_output(backup_id: Optional[pulumi.Input[str]] = None,
                             cluster_id: Optional[pulumi.Input[str]] = None,
                             location: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetMariaDBBackupsResult]
    func GetMariaDBBackups(ctx *Context, args *GetMariaDBBackupsArgs, opts ...InvokeOption) (*GetMariaDBBackupsResult, error)
    func GetMariaDBBackupsOutput(ctx *Context, args *GetMariaDBBackupsOutputArgs, opts ...InvokeOption) GetMariaDBBackupsResultOutput

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

    public static class GetMariaDBBackups 
    {
        public static Task<GetMariaDBBackupsResult> InvokeAsync(GetMariaDBBackupsArgs args, InvokeOptions? opts = null)
        public static Output<GetMariaDBBackupsResult> Invoke(GetMariaDBBackupsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetMariaDBBackupsResult> getMariaDBBackups(GetMariaDBBackupsArgs args, InvokeOptions options)
    public static Output<GetMariaDBBackupsResult> getMariaDBBackups(GetMariaDBBackupsArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ionoscloud:dbaas/getMariaDBBackups:getMariaDBBackups
      arguments:
        # arguments dictionary

    The following arguments are supported:

    BackupId string
    [string] The unique ID of the backup.
    ClusterId string
    [string] The unique ID of the cluster.
    Location string

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    BackupId string
    [string] The unique ID of the backup.
    ClusterId string
    [string] The unique ID of the cluster.
    Location string

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    backupId String
    [string] The unique ID of the backup.
    clusterId String
    [string] The unique ID of the cluster.
    location String

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    backupId string
    [string] The unique ID of the backup.
    clusterId string
    [string] The unique ID of the cluster.
    location string

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    backup_id str
    [string] The unique ID of the backup.
    cluster_id str
    [string] The unique ID of the cluster.
    location str

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    backupId String
    [string] The unique ID of the backup.
    clusterId String
    [string] The unique ID of the cluster.
    location String

    [string] The location of the cluster. Different service endpoints are used based on location, possible options are: "de/fra", "de/txl", "es/vit", "fr/par", "gb/lhr", "us/ewr", "us/las", "us/mci". If not set, the endpoint will be the one corresponding to "de/txl".

    ⚠️ Note: Either cluster_id or backup_id must be used, but not both at the same time.

    ⚠ WARNING: Location attribute will become required in the future.

    getMariaDBBackups Result

    The following output properties are available:

    BackupId string
    Backups List<Ionoscloud.GetMariaDBBackupsBackup>
    ClusterId string
    The unique ID of the cluster that was backed up.
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    BackupId string
    Backups []GetMariaDBBackupsBackup
    ClusterId string
    The unique ID of the cluster that was backed up.
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    backupId String
    backups List<GetMariaDBBackupsBackup>
    clusterId String
    The unique ID of the cluster that was backed up.
    id String
    The provider-assigned unique ID for this managed resource.
    location String
    backupId string
    backups GetMariaDBBackupsBackup[]
    clusterId string
    The unique ID of the cluster that was backed up.
    id string
    The provider-assigned unique ID for this managed resource.
    location string
    backup_id str
    backups Sequence[GetMariaDBBackupsBackup]
    cluster_id str
    The unique ID of the cluster that was backed up.
    id str
    The provider-assigned unique ID for this managed resource.
    location str
    backupId String
    backups List<Property Map>
    clusterId String
    The unique ID of the cluster that was backed up.
    id String
    The provider-assigned unique ID for this managed resource.
    location String

    Supporting Types

    GetMariaDBBackupsBackup

    BaseBackups List<Ionoscloud.GetMariaDBBackupsBackupBaseBackup>
    The list of backups for the specified cluster
    ClusterId string
    [string] The unique ID of the cluster.
    EarliestRecoveryTargetTime string
    The oldest available timestamp to which you can restore.
    Size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    BaseBackups []GetMariaDBBackupsBackupBaseBackup
    The list of backups for the specified cluster
    ClusterId string
    [string] The unique ID of the cluster.
    EarliestRecoveryTargetTime string
    The oldest available timestamp to which you can restore.
    Size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    baseBackups List<GetMariaDBBackupsBackupBaseBackup>
    The list of backups for the specified cluster
    clusterId String
    [string] The unique ID of the cluster.
    earliestRecoveryTargetTime String
    The oldest available timestamp to which you can restore.
    size Integer
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    baseBackups GetMariaDBBackupsBackupBaseBackup[]
    The list of backups for the specified cluster
    clusterId string
    [string] The unique ID of the cluster.
    earliestRecoveryTargetTime string
    The oldest available timestamp to which you can restore.
    size number
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    base_backups Sequence[GetMariaDBBackupsBackupBaseBackup]
    The list of backups for the specified cluster
    cluster_id str
    [string] The unique ID of the cluster.
    earliest_recovery_target_time str
    The oldest available timestamp to which you can restore.
    size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    baseBackups List<Property Map>
    The list of backups for the specified cluster
    clusterId String
    [string] The unique ID of the cluster.
    earliestRecoveryTargetTime String
    The oldest available timestamp to which you can restore.
    size Number
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored

    GetMariaDBBackupsBackupBaseBackup

    Created string
    The ISO 8601 creation timestamp
    Size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    Created string
    The ISO 8601 creation timestamp
    Size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    created String
    The ISO 8601 creation timestamp
    size Integer
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    created string
    The ISO 8601 creation timestamp
    size number
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    created str
    The ISO 8601 creation timestamp
    size int
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored
    created String
    The ISO 8601 creation timestamp
    size Number
    The size of the backup in Mebibytes (MiB). This is the size of the binary backup file that was stored

    Package Details

    Repository
    ionoscloud ionos-cloud/pulumi-ionoscloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ionoscloud Terraform Provider.
    ionoscloud logo
    IonosCloud v0.2.3 published on Tuesday, May 13, 2025 by ionos-cloud