Linode

Pulumi Official
Package maintained by Pulumi
v3.9.0 published on Friday, Jun 17, 2022 by Pulumi

getDatabases

Provides information about Linode Managed Databases that match a set of filters.

Attributes

Each engine will be stored in the databases attribute and will export the following attributes:

  • allow_list - A list of IP addresses that can access the Managed Database.

  • cluster_size - The number of Linode Instance nodes deployed to the Managed Database.

  • created - When this Managed Database was created.

  • encrypted - Whether the Managed Databases is encrypted.

  • engine - The Managed Database engine.

  • host_primary - The primary host for the Managed Database.

  • host_secondary - The secondary/private network host for the Managed Database.

  • id - The ID of the Managed Database.

  • label - A unique, user-defined string referring to the Managed Database.

  • region - The region to use for the Managed Database.

  • replication_type - The replication method used for the Managed Database.

  • ssl_connection - Whether to require SSL credentials to establish a connection to the Managed Database.

  • status - The operating status of the Managed Database.

  • type - The Linode Instance type used for the nodes of the Managed Database instance.

  • updated - When this Managed Database was last updated.

  • version - The Managed Database engine version.

Example Usage

using Pulumi;
using Linode = Pulumi.Linode;

class MyStack : Stack
{
    public MyStack()
    {
        var all = Output.Create(Linode.GetDatabases.InvokeAsync());
    }

}
package main

import (
	"github.com/pulumi/pulumi-linode/sdk/v3/go/linode"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := linode.GetDatabases(ctx, nil, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var all = Output.of(LinodeFunctions.getDatabases());

        }
}
import pulumi
import pulumi_linode as linode

all = linode.get_databases()
import * as pulumi from "@pulumi/pulumi";
import * as linode from "@pulumi/linode";

const all = pulumi.output(linode.getDatabases());
variables:
  all:
    Fn::Invoke:
      Function: linode:getDatabases
      Arguments: {}

Using getDatabases

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 getDatabases(args: GetDatabasesArgs, opts?: InvokeOptions): Promise<GetDatabasesResult>
function getDatabasesOutput(args: GetDatabasesOutputArgs, opts?: InvokeOptions): Output<GetDatabasesResult>
def get_databases(filters: Optional[Sequence[GetDatabasesFilter]] = None,
                  latest: Optional[bool] = None,
                  order: Optional[str] = None,
                  order_by: Optional[str] = None,
                  opts: Optional[InvokeOptions] = None) -> GetDatabasesResult
def get_databases_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetDatabasesFilterArgs]]]] = None,
                  latest: Optional[pulumi.Input[bool]] = None,
                  order: Optional[pulumi.Input[str]] = None,
                  order_by: Optional[pulumi.Input[str]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetDatabasesResult]
func GetDatabases(ctx *Context, args *GetDatabasesArgs, opts ...InvokeOption) (*GetDatabasesResult, error)
func GetDatabasesOutput(ctx *Context, args *GetDatabasesOutputArgs, opts ...InvokeOption) GetDatabasesResultOutput

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

public static class GetDatabases 
{
    public static Task<GetDatabasesResult> InvokeAsync(GetDatabasesArgs args, InvokeOptions? opts = null)
    public static Output<GetDatabasesResult> Invoke(GetDatabasesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDatabasesResult> getDatabases(GetDatabasesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: linode:index/getDatabases:getDatabases
  Arguments:
    # Arguments dictionary

The following arguments are supported:

Filters List<GetDatabasesFilter>
Latest bool

If true, only the latest create database will be returned.

Order string

The order in which results should be returned. (asc, desc; default asc)

OrderBy string

The attribute to order the results by. (version)

Filters []GetDatabasesFilter
Latest bool

If true, only the latest create database will be returned.

Order string

The order in which results should be returned. (asc, desc; default asc)

OrderBy string

The attribute to order the results by. (version)

filters List<GetDatabasesFilter>
latest Boolean

If true, only the latest create database will be returned.

order String

The order in which results should be returned. (asc, desc; default asc)

orderBy String

The attribute to order the results by. (version)

filters GetDatabasesFilter[]
latest boolean

If true, only the latest create database will be returned.

order string

The order in which results should be returned. (asc, desc; default asc)

orderBy string

The attribute to order the results by. (version)

filters Sequence[GetDatabasesFilter]
latest bool

If true, only the latest create database will be returned.

order str

The order in which results should be returned. (asc, desc; default asc)

order_by str

The attribute to order the results by. (version)

filters List<Property Map>
latest Boolean

If true, only the latest create database will be returned.

order String

The order in which results should be returned. (asc, desc; default asc)

orderBy String

The attribute to order the results by. (version)

getDatabases Result

The following output properties are available:

Databases List<GetDatabasesDatabase>
Id string

The provider-assigned unique ID for this managed resource.

Filters List<GetDatabasesFilter>
Latest bool
Order string
OrderBy string
Databases []GetDatabasesDatabase
Id string

The provider-assigned unique ID for this managed resource.

Filters []GetDatabasesFilter
Latest bool
Order string
OrderBy string
databases List<GetDatabasesDatabase>
id String

The provider-assigned unique ID for this managed resource.

filters List<GetDatabasesFilter>
latest Boolean
order String
orderBy String
databases GetDatabasesDatabase[]
id string

The provider-assigned unique ID for this managed resource.

filters GetDatabasesFilter[]
latest boolean
order string
orderBy string
databases Sequence[GetDatabasesDatabase]
id str

The provider-assigned unique ID for this managed resource.

filters Sequence[GetDatabasesFilter]
latest bool
order str
order_by str
databases List<Property Map>
id String

The provider-assigned unique ID for this managed resource.

filters List<Property Map>
latest Boolean
order String
orderBy String

Supporting Types

GetDatabasesDatabase

AllowLists List<string>
ClusterSize int
Created string
Encrypted bool
Engine string
HostPrimary string
HostSecondary string
Id int
InstanceUri string
Label string
Region string
ReplicationType string
SslConnection bool
Status string
Type string
Updated string
Version string
AllowLists []string
ClusterSize int
Created string
Encrypted bool
Engine string
HostPrimary string
HostSecondary string
Id int
InstanceUri string
Label string
Region string
ReplicationType string
SslConnection bool
Status string
Type string
Updated string
Version string
allowLists List<String>
clusterSize Integer
created String
encrypted Boolean
engine String
hostPrimary String
hostSecondary String
id Integer
instanceUri String
label String
region String
replicationType String
sslConnection Boolean
status String
type String
updated String
version String
allowLists string[]
clusterSize number
created string
encrypted boolean
engine string
hostPrimary string
hostSecondary string
id number
instanceUri string
label string
region string
replicationType string
sslConnection boolean
status string
type string
updated string
version string
allowLists List<String>
clusterSize Number
created String
encrypted Boolean
engine String
hostPrimary String
hostSecondary String
id Number
instanceUri String
label String
region String
replicationType String
sslConnection Boolean
status String
type String
updated String
version String

GetDatabasesFilter

Name string

The name of the field to filter by.

Values List<string>

A list of values for the filter to allow. These values should all be in string form.

MatchBy string

The method to match the field by. (exact, regex, substring; default exact)

Name string

The name of the field to filter by.

Values []string

A list of values for the filter to allow. These values should all be in string form.

MatchBy string

The method to match the field by. (exact, regex, substring; default exact)

name String

The name of the field to filter by.

values List<String>

A list of values for the filter to allow. These values should all be in string form.

matchBy String

The method to match the field by. (exact, regex, substring; default exact)

name string

The name of the field to filter by.

values string[]

A list of values for the filter to allow. These values should all be in string form.

matchBy string

The method to match the field by. (exact, regex, substring; default exact)

name str

The name of the field to filter by.

values Sequence[str]

A list of values for the filter to allow. These values should all be in string form.

match_by str

The method to match the field by. (exact, regex, substring; default exact)

name String

The name of the field to filter by.

values List<String>

A list of values for the filter to allow. These values should all be in string form.

matchBy String

The method to match the field by. (exact, regex, substring; default exact)

Package Details

Repository
https://github.com/pulumi/pulumi-linode
License
Apache-2.0
Notes

This Pulumi package is based on the linode Terraform Provider.