ionoscloud.dbaas.getPSQLCluster
Explore with Pulumi AI
The DbaaS Postgres Cluster data source can be used to search for and return an existing DbaaS Postgres Cluster. If a single match is found, it will be returned. If your search results in multiple matches, an error will be returned. When this happens, please refine your search string so that it is specific enough to return only one result.
Example Usage
By ID
import * as pulumi from "@pulumi/pulumi";
import * as ionoscloud from "@pulumi/ionoscloud";
const example = ionoscloud.dbaas.getPSQLCluster({
id: "cluster_id",
});
import pulumi
import pulumi_ionoscloud as ionoscloud
example = ionoscloud.dbaas.get_psql_cluster(id="cluster_id")
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.LookupPSQLCluster(ctx, &dbaas.LookupPSQLClusterArgs{
Id: pulumi.StringRef("cluster_id"),
}, 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.GetPSQLCluster.Invoke(new()
{
Id = "cluster_id",
});
});
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.GetPSQLClusterArgs;
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.getPSQLCluster(GetPSQLClusterArgs.builder()
.id("cluster_id")
.build());
}
}
variables:
example:
fn::invoke:
function: ionoscloud:dbaas:getPSQLCluster
arguments:
id: cluster_id
By Name
import * as pulumi from "@pulumi/pulumi";
import * as ionoscloud from "@pulumi/ionoscloud";
const example = ionoscloud.dbaas.getPSQLCluster({
displayName: "PostgreSQL_cluster",
});
import pulumi
import pulumi_ionoscloud as ionoscloud
example = ionoscloud.dbaas.get_psql_cluster(display_name="PostgreSQL_cluster")
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.LookupPSQLCluster(ctx, &dbaas.LookupPSQLClusterArgs{
DisplayName: pulumi.StringRef("PostgreSQL_cluster"),
}, 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.GetPSQLCluster.Invoke(new()
{
DisplayName = "PostgreSQL_cluster",
});
});
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.GetPSQLClusterArgs;
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.getPSQLCluster(GetPSQLClusterArgs.builder()
.displayName("PostgreSQL_cluster")
.build());
}
}
variables:
example:
fn::invoke:
function: ionoscloud:dbaas:getPSQLCluster
arguments:
displayName: PostgreSQL_cluster
Using getPSQLCluster
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 getPSQLCluster(args: GetPSQLClusterArgs, opts?: InvokeOptions): Promise<GetPSQLClusterResult>
function getPSQLClusterOutput(args: GetPSQLClusterOutputArgs, opts?: InvokeOptions): Output<GetPSQLClusterResult>
def get_psql_cluster(display_name: Optional[str] = None,
id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPSQLClusterResult
def get_psql_cluster_output(display_name: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPSQLClusterResult]
func LookupPSQLCluster(ctx *Context, args *LookupPSQLClusterArgs, opts ...InvokeOption) (*LookupPSQLClusterResult, error)
func LookupPSQLClusterOutput(ctx *Context, args *LookupPSQLClusterOutputArgs, opts ...InvokeOption) LookupPSQLClusterResultOutput
> Note: This function is named LookupPSQLCluster
in the Go SDK.
public static class GetPSQLCluster
{
public static Task<GetPSQLClusterResult> InvokeAsync(GetPSQLClusterArgs args, InvokeOptions? opts = null)
public static Output<GetPSQLClusterResult> Invoke(GetPSQLClusterInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPSQLClusterResult> getPSQLCluster(GetPSQLClusterArgs args, InvokeOptions options)
public static Output<GetPSQLClusterResult> getPSQLCluster(GetPSQLClusterArgs args, InvokeOptions options)
fn::invoke:
function: ionoscloud:dbaas/getPSQLCluster:getPSQLCluster
arguments:
# arguments dictionary
The following arguments are supported:
- Display
Name string - Display Name of an existing cluster that you want to search for.
- Id string
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
- Display
Name string - Display Name of an existing cluster that you want to search for.
- Id string
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
- display
Name String - Display Name of an existing cluster that you want to search for.
- id String
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
- display
Name string - Display Name of an existing cluster that you want to search for.
- id string
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
- display_
name str - Display Name of an existing cluster that you want to search for.
- id str
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
- display
Name String - Display Name of an existing cluster that you want to search for.
- id String
ID of the cluster you want to search for.
Either
display_name
orid
must be provided. If none, or both are provided, the datasource will return an error.
getPSQLCluster Result
The following output properties are available:
- Backup
Location string - The IONOS Object Storage location where the backups will be stored.
- Connection
Poolers List<Ionoscloud.Get PSQLCluster Connection Pooler> - Details about the connection pooler.
- Connections
List<Ionoscloud.
Get PSQLCluster Connection> - Details about the network connection for your cluster.
- Cores int
- The number of CPU cores per replica.
- Display
Name string - The friendly name of your cluster.
- Dns
Name string - The DNS name pointing to your cluster.
- From
Backups List<Ionoscloud.Get PSQLCluster From Backup> - The unique ID of the backup you want to restore.
- Id string
- Instances int
- The total number of instances in the cluster (one master and n-1 standbys)
- Location string
- The physical location where the cluster will be created. This will be where all of your instances live.
- Maintenance
Windows List<Ionoscloud.Get PSQLCluster Maintenance Window> - A weekly 4 hour-long window, during which maintenance might occur
- Postgres
Version string - The PostgreSQL version of your cluster.
- Ram int
- The amount of memory per instance in megabytes.
- Storage
Size int - The amount of storage per instance in MB.
- Storage
Type string - The storage type used in your cluster.
- Synchronization
Mode string - Represents different modes of replication.
- Backup
Location string - The IONOS Object Storage location where the backups will be stored.
- Connection
Poolers []GetPSQLCluster Connection Pooler - Details about the connection pooler.
- Connections
[]Get
PSQLCluster Connection - Details about the network connection for your cluster.
- Cores int
- The number of CPU cores per replica.
- Display
Name string - The friendly name of your cluster.
- Dns
Name string - The DNS name pointing to your cluster.
- From
Backups []GetPSQLCluster From Backup - The unique ID of the backup you want to restore.
- Id string
- Instances int
- The total number of instances in the cluster (one master and n-1 standbys)
- Location string
- The physical location where the cluster will be created. This will be where all of your instances live.
- Maintenance
Windows []GetPSQLCluster Maintenance Window - A weekly 4 hour-long window, during which maintenance might occur
- Postgres
Version string - The PostgreSQL version of your cluster.
- Ram int
- The amount of memory per instance in megabytes.
- Storage
Size int - The amount of storage per instance in MB.
- Storage
Type string - The storage type used in your cluster.
- Synchronization
Mode string - Represents different modes of replication.
- backup
Location String - The IONOS Object Storage location where the backups will be stored.
- connection
Poolers List<GetPSQLCluster Connection Pooler> - Details about the connection pooler.
- connections
List<Get
PSQLCluster Connection> - Details about the network connection for your cluster.
- cores Integer
- The number of CPU cores per replica.
- display
Name String - The friendly name of your cluster.
- dns
Name String - The DNS name pointing to your cluster.
- from
Backups List<GetPSQLCluster From Backup> - The unique ID of the backup you want to restore.
- id String
- instances Integer
- The total number of instances in the cluster (one master and n-1 standbys)
- location String
- The physical location where the cluster will be created. This will be where all of your instances live.
- maintenance
Windows List<GetPSQLCluster Maintenance Window> - A weekly 4 hour-long window, during which maintenance might occur
- postgres
Version String - The PostgreSQL version of your cluster.
- ram Integer
- The amount of memory per instance in megabytes.
- storage
Size Integer - The amount of storage per instance in MB.
- storage
Type String - The storage type used in your cluster.
- synchronization
Mode String - Represents different modes of replication.
- backup
Location string - The IONOS Object Storage location where the backups will be stored.
- connection
Poolers GetPSQLCluster Connection Pooler[] - Details about the connection pooler.
- connections
Get
PSQLCluster Connection[] - Details about the network connection for your cluster.
- cores number
- The number of CPU cores per replica.
- display
Name string - The friendly name of your cluster.
- dns
Name string - The DNS name pointing to your cluster.
- from
Backups GetPSQLCluster From Backup[] - The unique ID of the backup you want to restore.
- id string
- instances number
- The total number of instances in the cluster (one master and n-1 standbys)
- location string
- The physical location where the cluster will be created. This will be where all of your instances live.
- maintenance
Windows GetPSQLCluster Maintenance Window[] - A weekly 4 hour-long window, during which maintenance might occur
- postgres
Version string - The PostgreSQL version of your cluster.
- ram number
- The amount of memory per instance in megabytes.
- storage
Size number - The amount of storage per instance in MB.
- storage
Type string - The storage type used in your cluster.
- synchronization
Mode string - Represents different modes of replication.
- backup_
location str - The IONOS Object Storage location where the backups will be stored.
- connection_
poolers Sequence[GetPSQLCluster Connection Pooler] - Details about the connection pooler.
- connections
Sequence[Get
PSQLCluster Connection] - Details about the network connection for your cluster.
- cores int
- The number of CPU cores per replica.
- display_
name str - The friendly name of your cluster.
- dns_
name str - The DNS name pointing to your cluster.
- from_
backups Sequence[GetPSQLCluster From Backup] - The unique ID of the backup you want to restore.
- id str
- instances int
- The total number of instances in the cluster (one master and n-1 standbys)
- location str
- The physical location where the cluster will be created. This will be where all of your instances live.
- maintenance_
windows Sequence[GetPSQLCluster Maintenance Window] - A weekly 4 hour-long window, during which maintenance might occur
- postgres_
version str - The PostgreSQL version of your cluster.
- ram int
- The amount of memory per instance in megabytes.
- storage_
size int - The amount of storage per instance in MB.
- storage_
type str - The storage type used in your cluster.
- synchronization_
mode str - Represents different modes of replication.
- backup
Location String - The IONOS Object Storage location where the backups will be stored.
- connection
Poolers List<Property Map> - Details about the connection pooler.
- connections List<Property Map>
- Details about the network connection for your cluster.
- cores Number
- The number of CPU cores per replica.
- display
Name String - The friendly name of your cluster.
- dns
Name String - The DNS name pointing to your cluster.
- from
Backups List<Property Map> - The unique ID of the backup you want to restore.
- id String
- instances Number
- The total number of instances in the cluster (one master and n-1 standbys)
- location String
- The physical location where the cluster will be created. This will be where all of your instances live.
- maintenance
Windows List<Property Map> - A weekly 4 hour-long window, during which maintenance might occur
- postgres
Version String - The PostgreSQL version of your cluster.
- ram Number
- The amount of memory per instance in megabytes.
- storage
Size Number - The amount of storage per instance in MB.
- storage
Type String - The storage type used in your cluster.
- synchronization
Mode String - Represents different modes of replication.
Supporting Types
GetPSQLClusterConnection
- Cidr string
- The IP and subnet for the database.
- Datacenter
Id string - The datacenter to connect your cluster to.
- Lan
Id string - The LAN to connect your cluster to.
- Cidr string
- The IP and subnet for the database.
- Datacenter
Id string - The datacenter to connect your cluster to.
- Lan
Id string - The LAN to connect your cluster to.
- cidr String
- The IP and subnet for the database.
- datacenter
Id String - The datacenter to connect your cluster to.
- lan
Id String - The LAN to connect your cluster to.
- cidr string
- The IP and subnet for the database.
- datacenter
Id string - The datacenter to connect your cluster to.
- lan
Id string - The LAN to connect your cluster to.
- cidr str
- The IP and subnet for the database.
- datacenter_
id str - The datacenter to connect your cluster to.
- lan_
id str - The LAN to connect your cluster to.
- cidr String
- The IP and subnet for the database.
- datacenter
Id String - The datacenter to connect your cluster to.
- lan
Id String - The LAN to connect your cluster to.
GetPSQLClusterConnectionPooler
GetPSQLClusterFromBackup
- Backup
Id string - The PostgreSQL version of your cluster.
- Recovery
Target stringTime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
- Backup
Id string - The PostgreSQL version of your cluster.
- Recovery
Target stringTime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
- backup
Id String - The PostgreSQL version of your cluster.
- recovery
Target StringTime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
- backup
Id string - The PostgreSQL version of your cluster.
- recovery
Target stringTime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
- backup_
id str - The PostgreSQL version of your cluster.
- recovery_
target_ strtime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
- backup
Id String - The PostgreSQL version of your cluster.
- recovery
Target StringTime - If this value is supplied as ISO 8601 timestamp, the backup will be replayed up until the given timestamp.
GetPSQLClusterMaintenanceWindow
- Day
Of stringThe Week - Time string
- Day
Of stringThe Week - Time string
- day
Of StringThe Week - time String
- day
Of stringThe Week - time string
- day_
of_ strthe_ week - time str
- day
Of StringThe Week - time String
Package Details
- Repository
- ionoscloud ionos-cloud/pulumi-ionoscloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
ionoscloud
Terraform Provider.