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

ionoscloud.dbaas.getMariaDBCluster

Explore with Pulumi AI

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

    The DBaaS MariaDB Cluster data source can be used to search for and return an existing DBaaS MariaDB Cluster.

    Example Usage

    By ID

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@pulumi/ionoscloud";
    
    const example = ionoscloud.dbaas.getMariaDBCluster({
        id: "cluster_id",
        location: "de/txl",
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    
    example = ionoscloud.dbaas.get_maria_db_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.LookupMariaDBCluster(ctx, &dbaas.LookupMariaDBClusterArgs{
    			Id:       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.GetMariaDBCluster.Invoke(new()
        {
            Id = "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.GetMariaDBClusterArgs;
    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.getMariaDBCluster(GetMariaDBClusterArgs.builder()
                .id("cluster_id")
                .location("de/txl")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ionoscloud:dbaas:getMariaDBCluster
          arguments:
            id: cluster_id
            location: de/txl
    

    By Name

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@pulumi/ionoscloud";
    
    const example = ionoscloud.dbaas.getMariaDBCluster({
        displayName: "MariaDB_cluster",
        location: "de/txl",
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    
    example = ionoscloud.dbaas.get_maria_db_cluster(display_name="MariaDB_cluster",
        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.LookupMariaDBCluster(ctx, &dbaas.LookupMariaDBClusterArgs{
    			DisplayName: pulumi.StringRef("MariaDB_cluster"),
    			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.GetMariaDBCluster.Invoke(new()
        {
            DisplayName = "MariaDB_cluster",
            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.GetMariaDBClusterArgs;
    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.getMariaDBCluster(GetMariaDBClusterArgs.builder()
                .displayName("MariaDB_cluster")
                .location("de/txl")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ionoscloud:dbaas:getMariaDBCluster
          arguments:
            displayName: MariaDB_cluster
            location: de/txl
    

    Using getMariaDBCluster

    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 getMariaDBCluster(args: GetMariaDBClusterArgs, opts?: InvokeOptions): Promise<GetMariaDBClusterResult>
    function getMariaDBClusterOutput(args: GetMariaDBClusterOutputArgs, opts?: InvokeOptions): Output<GetMariaDBClusterResult>
    def get_maria_db_cluster(display_name: Optional[str] = None,
                             id: Optional[str] = None,
                             location: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetMariaDBClusterResult
    def get_maria_db_cluster_output(display_name: Optional[pulumi.Input[str]] = None,
                             id: Optional[pulumi.Input[str]] = None,
                             location: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetMariaDBClusterResult]
    func LookupMariaDBCluster(ctx *Context, args *LookupMariaDBClusterArgs, opts ...InvokeOption) (*LookupMariaDBClusterResult, error)
    func LookupMariaDBClusterOutput(ctx *Context, args *LookupMariaDBClusterOutputArgs, opts ...InvokeOption) LookupMariaDBClusterResultOutput

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

    public static class GetMariaDBCluster 
    {
        public static Task<GetMariaDBClusterResult> InvokeAsync(GetMariaDBClusterArgs args, InvokeOptions? opts = null)
        public static Output<GetMariaDBClusterResult> Invoke(GetMariaDBClusterInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetMariaDBClusterResult> getMariaDBCluster(GetMariaDBClusterArgs args, InvokeOptions options)
    public static Output<GetMariaDBClusterResult> getMariaDBCluster(GetMariaDBClusterArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ionoscloud:dbaas/getMariaDBCluster:getMariaDBCluster
      arguments:
        # arguments dictionary

    The following arguments are supported:

    DisplayName string
    [string] Display Name of an existing cluster that you want to search for.
    Id string
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    DisplayName string
    [string] Display Name of an existing cluster that you want to search for.
    Id string
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    displayName String
    [string] Display Name of an existing cluster that you want to search for.
    id String
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    displayName string
    [string] Display Name of an existing cluster that you want to search for.
    id string
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    display_name str
    [string] Display Name of an existing cluster that you want to search for.
    id str
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    displayName String
    [string] Display Name of an existing cluster that you want to search for.
    id String
    [string] ID of the cluster you want to search for.
    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".

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

    Either display_name or id must be provided. If none or both are provided, the datasource will return an error.

    getMariaDBCluster Result

    The following output properties are available:

    Connections List<Ionoscloud.GetMariaDBClusterConnection>
    The network connection for your cluster. Only one connection is allowed.
    Cores int
    [int] The number of CPU cores per instance.
    DisplayName string
    [string] The friendly name of your cluster.
    DnsName string
    [string] The DNS name pointing to your cluster.
    Id string
    Instances int
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    MaintenanceWindows List<Ionoscloud.GetMariaDBClusterMaintenanceWindow>
    A weekly 4 hour-long window, during which maintenance might occur.
    MariadbVersion string
    [string] The MariaDB version of your cluster.
    Ram int
    [int] The amount of memory per instance in gigabytes (GB).
    StorageSize int
    [int] The amount of storage per instance in gigabytes (GB).
    Location string
    Connections []GetMariaDBClusterConnection
    The network connection for your cluster. Only one connection is allowed.
    Cores int
    [int] The number of CPU cores per instance.
    DisplayName string
    [string] The friendly name of your cluster.
    DnsName string
    [string] The DNS name pointing to your cluster.
    Id string
    Instances int
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    MaintenanceWindows []GetMariaDBClusterMaintenanceWindow
    A weekly 4 hour-long window, during which maintenance might occur.
    MariadbVersion string
    [string] The MariaDB version of your cluster.
    Ram int
    [int] The amount of memory per instance in gigabytes (GB).
    StorageSize int
    [int] The amount of storage per instance in gigabytes (GB).
    Location string
    connections List<GetMariaDBClusterConnection>
    The network connection for your cluster. Only one connection is allowed.
    cores Integer
    [int] The number of CPU cores per instance.
    displayName String
    [string] The friendly name of your cluster.
    dnsName String
    [string] The DNS name pointing to your cluster.
    id String
    instances Integer
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    maintenanceWindows List<GetMariaDBClusterMaintenanceWindow>
    A weekly 4 hour-long window, during which maintenance might occur.
    mariadbVersion String
    [string] The MariaDB version of your cluster.
    ram Integer
    [int] The amount of memory per instance in gigabytes (GB).
    storageSize Integer
    [int] The amount of storage per instance in gigabytes (GB).
    location String
    connections GetMariaDBClusterConnection[]
    The network connection for your cluster. Only one connection is allowed.
    cores number
    [int] The number of CPU cores per instance.
    displayName string
    [string] The friendly name of your cluster.
    dnsName string
    [string] The DNS name pointing to your cluster.
    id string
    instances number
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    maintenanceWindows GetMariaDBClusterMaintenanceWindow[]
    A weekly 4 hour-long window, during which maintenance might occur.
    mariadbVersion string
    [string] The MariaDB version of your cluster.
    ram number
    [int] The amount of memory per instance in gigabytes (GB).
    storageSize number
    [int] The amount of storage per instance in gigabytes (GB).
    location string
    connections Sequence[GetMariaDBClusterConnection]
    The network connection for your cluster. Only one connection is allowed.
    cores int
    [int] The number of CPU cores per instance.
    display_name str
    [string] The friendly name of your cluster.
    dns_name str
    [string] The DNS name pointing to your cluster.
    id str
    instances int
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    maintenance_windows Sequence[GetMariaDBClusterMaintenanceWindow]
    A weekly 4 hour-long window, during which maintenance might occur.
    mariadb_version str
    [string] The MariaDB version of your cluster.
    ram int
    [int] The amount of memory per instance in gigabytes (GB).
    storage_size int
    [int] The amount of storage per instance in gigabytes (GB).
    location str
    connections List<Property Map>
    The network connection for your cluster. Only one connection is allowed.
    cores Number
    [int] The number of CPU cores per instance.
    displayName String
    [string] The friendly name of your cluster.
    dnsName String
    [string] The DNS name pointing to your cluster.
    id String
    instances Number
    [int] The total number of instances in the cluster (one primary and n-1 secondary).
    maintenanceWindows List<Property Map>
    A weekly 4 hour-long window, during which maintenance might occur.
    mariadbVersion String
    [string] The MariaDB version of your cluster.
    ram Number
    [int] The amount of memory per instance in gigabytes (GB).
    storageSize Number
    [int] The amount of storage per instance in gigabytes (GB).
    location String

    Supporting Types

    GetMariaDBClusterConnection

    Cidr string
    [string] The IP and subnet for your cluster.
    DatacenterId string
    [string] The datacenter to connect your cluster to.
    LanId string
    [string] The LAN to connect your cluster to.
    Cidr string
    [string] The IP and subnet for your cluster.
    DatacenterId string
    [string] The datacenter to connect your cluster to.
    LanId string
    [string] The LAN to connect your cluster to.
    cidr String
    [string] The IP and subnet for your cluster.
    datacenterId String
    [string] The datacenter to connect your cluster to.
    lanId String
    [string] The LAN to connect your cluster to.
    cidr string
    [string] The IP and subnet for your cluster.
    datacenterId string
    [string] The datacenter to connect your cluster to.
    lanId string
    [string] The LAN to connect your cluster to.
    cidr str
    [string] The IP and subnet for your cluster.
    datacenter_id str
    [string] The datacenter to connect your cluster to.
    lan_id str
    [string] The LAN to connect your cluster to.
    cidr String
    [string] The IP and subnet for your cluster.
    datacenterId String
    [string] The datacenter to connect your cluster to.
    lanId String
    [string] The LAN to connect your cluster to.

    GetMariaDBClusterMaintenanceWindow

    DayOfTheWeek string
    [string] The name of the week day.
    Time string
    [string] Start of the maintenance window in UTC time.
    DayOfTheWeek string
    [string] The name of the week day.
    Time string
    [string] Start of the maintenance window in UTC time.
    dayOfTheWeek String
    [string] The name of the week day.
    time String
    [string] Start of the maintenance window in UTC time.
    dayOfTheWeek string
    [string] The name of the week day.
    time string
    [string] Start of the maintenance window in UTC time.
    day_of_the_week str
    [string] The name of the week day.
    time str
    [string] Start of the maintenance window in UTC time.
    dayOfTheWeek String
    [string] The name of the week day.
    time String
    [string] Start of the maintenance window in UTC time.

    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