1. Packages
  2. Scaleway
  3. API Docs
  4. mongodb
  5. Instance
Scaleway v1.25.0 published on Saturday, Mar 22, 2025 by pulumiverse

scaleway.mongodb.Instance

Explore with Pulumi AI

Creates and manages Scaleway MongoDB® instance. For more information refer to the product documentation.

Example Usage

Basic

import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumiverse/scaleway";

const main = new scaleway.mongodb.Instance("main", {
    name: "test-mongodb-basic1",
    version: "7.0.12",
    nodeType: "MGDB-PLAY2-NANO",
    nodeNumber: 1,
    userName: "my_initial_user",
    password: "thiZ_is_v&ry_s3cret",
    volumeSizeInGb: 5,
});
Copy
import pulumi
import pulumiverse_scaleway as scaleway

main = scaleway.mongodb.Instance("main",
    name="test-mongodb-basic1",
    version="7.0.12",
    node_type="MGDB-PLAY2-NANO",
    node_number=1,
    user_name="my_initial_user",
    password="thiZ_is_v&ry_s3cret",
    volume_size_in_gb=5)
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway/mongodb"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodb.NewInstance(ctx, "main", &mongodb.InstanceArgs{
			Name:           pulumi.String("test-mongodb-basic1"),
			Version:        pulumi.String("7.0.12"),
			NodeType:       pulumi.String("MGDB-PLAY2-NANO"),
			NodeNumber:     pulumi.Int(1),
			UserName:       pulumi.String("my_initial_user"),
			Password:       pulumi.String("thiZ_is_v&ry_s3cret"),
			VolumeSizeInGb: pulumi.Int(5),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumiverse.Scaleway;

return await Deployment.RunAsync(() => 
{
    var main = new Scaleway.Mongodb.Instance("main", new()
    {
        Name = "test-mongodb-basic1",
        Version = "7.0.12",
        NodeType = "MGDB-PLAY2-NANO",
        NodeNumber = 1,
        UserName = "my_initial_user",
        Password = "thiZ_is_v&ry_s3cret",
        VolumeSizeInGb = 5,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.mongodb.Instance;
import com.pulumi.scaleway.mongodb.InstanceArgs;
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 main = new Instance("main", InstanceArgs.builder()
            .name("test-mongodb-basic1")
            .version("7.0.12")
            .nodeType("MGDB-PLAY2-NANO")
            .nodeNumber(1)
            .userName("my_initial_user")
            .password("thiZ_is_v&ry_s3cret")
            .volumeSizeInGb(5)
            .build());

    }
}
Copy
resources:
  main:
    type: scaleway:mongodb:Instance
    properties:
      name: test-mongodb-basic1
      version: 7.0.12
      nodeType: MGDB-PLAY2-NANO
      nodeNumber: 1
      userName: my_initial_user
      password: thiZ_is_v&ry_s3cret
      volumeSizeInGb: 5
Copy

Private Network

import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumiverse/scaleway";

const pn01 = new scaleway.network.PrivateNetwork("pn01", {
    name: "my_private_network",
    region: "fr-par",
});
const main = new scaleway.mongodb.Instance("main", {
    name: "test-mongodb-basic1",
    version: "7.0.12",
    nodeType: "MGDB-PLAY2-NANO",
    nodeNumber: 1,
    userName: "my_initial_user",
    password: "thiZ_is_v&ry_s3cret",
    volumeSizeInGb: 5,
    privateNetwork: {
        pnId: pn02.id,
    },
});
Copy
import pulumi
import pulumiverse_scaleway as scaleway

pn01 = scaleway.network.PrivateNetwork("pn01",
    name="my_private_network",
    region="fr-par")
main = scaleway.mongodb.Instance("main",
    name="test-mongodb-basic1",
    version="7.0.12",
    node_type="MGDB-PLAY2-NANO",
    node_number=1,
    user_name="my_initial_user",
    password="thiZ_is_v&ry_s3cret",
    volume_size_in_gb=5,
    private_network={
        "pn_id": pn02["id"],
    })
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway/mongodb"
	"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway/network"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := network.NewPrivateNetwork(ctx, "pn01", &network.PrivateNetworkArgs{
			Name:   pulumi.String("my_private_network"),
			Region: pulumi.String("fr-par"),
		})
		if err != nil {
			return err
		}
		_, err = mongodb.NewInstance(ctx, "main", &mongodb.InstanceArgs{
			Name:           pulumi.String("test-mongodb-basic1"),
			Version:        pulumi.String("7.0.12"),
			NodeType:       pulumi.String("MGDB-PLAY2-NANO"),
			NodeNumber:     pulumi.Int(1),
			UserName:       pulumi.String("my_initial_user"),
			Password:       pulumi.String("thiZ_is_v&ry_s3cret"),
			VolumeSizeInGb: pulumi.Int(5),
			PrivateNetwork: &mongodb.InstancePrivateNetworkArgs{
				PnId: pulumi.Any(pn02.Id),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumiverse.Scaleway;

return await Deployment.RunAsync(() => 
{
    var pn01 = new Scaleway.Network.PrivateNetwork("pn01", new()
    {
        Name = "my_private_network",
        Region = "fr-par",
    });

    var main = new Scaleway.Mongodb.Instance("main", new()
    {
        Name = "test-mongodb-basic1",
        Version = "7.0.12",
        NodeType = "MGDB-PLAY2-NANO",
        NodeNumber = 1,
        UserName = "my_initial_user",
        Password = "thiZ_is_v&ry_s3cret",
        VolumeSizeInGb = 5,
        PrivateNetwork = new Scaleway.Mongodb.Inputs.InstancePrivateNetworkArgs
        {
            PnId = pn02.Id,
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.network.PrivateNetwork;
import com.pulumi.scaleway.network.PrivateNetworkArgs;
import com.pulumi.scaleway.mongodb.Instance;
import com.pulumi.scaleway.mongodb.InstanceArgs;
import com.pulumi.scaleway.mongodb.inputs.InstancePrivateNetworkArgs;
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 pn01 = new PrivateNetwork("pn01", PrivateNetworkArgs.builder()
            .name("my_private_network")
            .region("fr-par")
            .build());

        var main = new Instance("main", InstanceArgs.builder()
            .name("test-mongodb-basic1")
            .version("7.0.12")
            .nodeType("MGDB-PLAY2-NANO")
            .nodeNumber(1)
            .userName("my_initial_user")
            .password("thiZ_is_v&ry_s3cret")
            .volumeSizeInGb(5)
            .privateNetwork(InstancePrivateNetworkArgs.builder()
                .pnId(pn02.id())
                .build())
            .build());

    }
}
Copy
resources:
  pn01:
    type: scaleway:network:PrivateNetwork
    properties:
      name: my_private_network
      region: fr-par
  main:
    type: scaleway:mongodb:Instance
    properties:
      name: test-mongodb-basic1
      version: 7.0.12
      nodeType: MGDB-PLAY2-NANO
      nodeNumber: 1
      userName: my_initial_user
      password: thiZ_is_v&ry_s3cret
      volumeSizeInGb: 5
      privateNetwork:
        pnId: ${pn02.id}
Copy

Restore From Snapshot

import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumiverse/scaleway";

const restoredInstance = new scaleway.mongodb.Instance("restored_instance", {
    snapshotId: pn.idscalewayMongodbSnapshot.mainSnapshot.id,
    name: "restored-mongodb-from-snapshot",
    nodeType: "MGDB-PLAY2-NANO",
    nodeNumber: 1,
});
Copy
import pulumi
import pulumiverse_scaleway as scaleway

restored_instance = scaleway.mongodb.Instance("restored_instance",
    snapshot_id=pn["idscalewayMongodbSnapshot"]["mainSnapshot"]["id"],
    name="restored-mongodb-from-snapshot",
    node_type="MGDB-PLAY2-NANO",
    node_number=1)
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway/mongodb"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodb.NewInstance(ctx, "restored_instance", &mongodb.InstanceArgs{
			SnapshotId: pulumi.Any(pn.IdscalewayMongodbSnapshot.MainSnapshot.Id),
			Name:       pulumi.String("restored-mongodb-from-snapshot"),
			NodeType:   pulumi.String("MGDB-PLAY2-NANO"),
			NodeNumber: pulumi.Int(1),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumiverse.Scaleway;

return await Deployment.RunAsync(() => 
{
    var restoredInstance = new Scaleway.Mongodb.Instance("restored_instance", new()
    {
        SnapshotId = pn.IdscalewayMongodbSnapshot.MainSnapshot.Id,
        Name = "restored-mongodb-from-snapshot",
        NodeType = "MGDB-PLAY2-NANO",
        NodeNumber = 1,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.mongodb.Instance;
import com.pulumi.scaleway.mongodb.InstanceArgs;
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 restoredInstance = new Instance("restoredInstance", InstanceArgs.builder()
            .snapshotId(pn.idscalewayMongodbSnapshot().mainSnapshot().id())
            .name("restored-mongodb-from-snapshot")
            .nodeType("MGDB-PLAY2-NANO")
            .nodeNumber(1)
            .build());

    }
}
Copy
resources:
  restoredInstance:
    type: scaleway:mongodb:Instance
    name: restored_instance
    properties:
      snapshotId: ${pn.idscalewayMongodbSnapshot.mainSnapshot.id}
      name: restored-mongodb-from-snapshot
      nodeType: MGDB-PLAY2-NANO
      nodeNumber: 1
Copy

Create Instance Resource

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

Constructor syntax

new Instance(name: string, args: InstanceArgs, opts?: CustomResourceOptions);
@overload
def Instance(resource_name: str,
             args: InstanceArgs,
             opts: Optional[ResourceOptions] = None)

@overload
def Instance(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             node_type: Optional[str] = None,
             node_number: Optional[int] = None,
             public_network: Optional[InstancePublicNetworkArgs] = None,
             password: Optional[str] = None,
             private_network: Optional[InstancePrivateNetworkArgs] = None,
             project_id: Optional[str] = None,
             name: Optional[str] = None,
             region: Optional[str] = None,
             settings: Optional[Mapping[str, str]] = None,
             snapshot_id: Optional[str] = None,
             tags: Optional[Sequence[str]] = None,
             user_name: Optional[str] = None,
             version: Optional[str] = None,
             volume_size_in_gb: Optional[int] = None,
             volume_type: Optional[str] = None)
func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)
public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
public Instance(String name, InstanceArgs args)
public Instance(String name, InstanceArgs args, CustomResourceOptions options)
type: scaleway:mongodb:Instance
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. InstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. InstanceArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. InstanceArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. InstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. InstanceArgs
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 scalewayInstanceResource = new Scaleway.Mongodb.Instance("scalewayInstanceResource", new()
{
    NodeType = "string",
    NodeNumber = 0,
    PublicNetwork = new Scaleway.Mongodb.Inputs.InstancePublicNetworkArgs
    {
        DnsRecord = "string",
        Id = "string",
        Port = 0,
    },
    Password = "string",
    PrivateNetwork = new Scaleway.Mongodb.Inputs.InstancePrivateNetworkArgs
    {
        PnId = "string",
        DnsRecords = new[]
        {
            "string",
        },
        Id = "string",
        Ips = new[]
        {
            "string",
        },
        Port = 0,
    },
    ProjectId = "string",
    Name = "string",
    Region = "string",
    Settings = 
    {
        { "string", "string" },
    },
    SnapshotId = "string",
    Tags = new[]
    {
        "string",
    },
    UserName = "string",
    Version = "string",
    VolumeSizeInGb = 0,
    VolumeType = "string",
});
Copy
example, err := mongodb.NewInstance(ctx, "scalewayInstanceResource", &mongodb.InstanceArgs{
	NodeType:   pulumi.String("string"),
	NodeNumber: pulumi.Int(0),
	PublicNetwork: &mongodb.InstancePublicNetworkArgs{
		DnsRecord: pulumi.String("string"),
		Id:        pulumi.String("string"),
		Port:      pulumi.Int(0),
	},
	Password: pulumi.String("string"),
	PrivateNetwork: &mongodb.InstancePrivateNetworkArgs{
		PnId: pulumi.String("string"),
		DnsRecords: pulumi.StringArray{
			pulumi.String("string"),
		},
		Id: pulumi.String("string"),
		Ips: pulumi.StringArray{
			pulumi.String("string"),
		},
		Port: pulumi.Int(0),
	},
	ProjectId: pulumi.String("string"),
	Name:      pulumi.String("string"),
	Region:    pulumi.String("string"),
	Settings: pulumi.StringMap{
		"string": pulumi.String("string"),
	},
	SnapshotId: pulumi.String("string"),
	Tags: pulumi.StringArray{
		pulumi.String("string"),
	},
	UserName:       pulumi.String("string"),
	Version:        pulumi.String("string"),
	VolumeSizeInGb: pulumi.Int(0),
	VolumeType:     pulumi.String("string"),
})
Copy
var scalewayInstanceResource = new Instance("scalewayInstanceResource", InstanceArgs.builder()
    .nodeType("string")
    .nodeNumber(0)
    .publicNetwork(InstancePublicNetworkArgs.builder()
        .dnsRecord("string")
        .id("string")
        .port(0)
        .build())
    .password("string")
    .privateNetwork(InstancePrivateNetworkArgs.builder()
        .pnId("string")
        .dnsRecords("string")
        .id("string")
        .ips("string")
        .port(0)
        .build())
    .projectId("string")
    .name("string")
    .region("string")
    .settings(Map.of("string", "string"))
    .snapshotId("string")
    .tags("string")
    .userName("string")
    .version("string")
    .volumeSizeInGb(0)
    .volumeType("string")
    .build());
Copy
scaleway_instance_resource = scaleway.mongodb.Instance("scalewayInstanceResource",
    node_type="string",
    node_number=0,
    public_network={
        "dns_record": "string",
        "id": "string",
        "port": 0,
    },
    password="string",
    private_network={
        "pn_id": "string",
        "dns_records": ["string"],
        "id": "string",
        "ips": ["string"],
        "port": 0,
    },
    project_id="string",
    name="string",
    region="string",
    settings={
        "string": "string",
    },
    snapshot_id="string",
    tags=["string"],
    user_name="string",
    version="string",
    volume_size_in_gb=0,
    volume_type="string")
Copy
const scalewayInstanceResource = new scaleway.mongodb.Instance("scalewayInstanceResource", {
    nodeType: "string",
    nodeNumber: 0,
    publicNetwork: {
        dnsRecord: "string",
        id: "string",
        port: 0,
    },
    password: "string",
    privateNetwork: {
        pnId: "string",
        dnsRecords: ["string"],
        id: "string",
        ips: ["string"],
        port: 0,
    },
    projectId: "string",
    name: "string",
    region: "string",
    settings: {
        string: "string",
    },
    snapshotId: "string",
    tags: ["string"],
    userName: "string",
    version: "string",
    volumeSizeInGb: 0,
    volumeType: "string",
});
Copy
type: scaleway:mongodb:Instance
properties:
    name: string
    nodeNumber: 0
    nodeType: string
    password: string
    privateNetwork:
        dnsRecords:
            - string
        id: string
        ips:
            - string
        pnId: string
        port: 0
    projectId: string
    publicNetwork:
        dnsRecord: string
        id: string
        port: 0
    region: string
    settings:
        string: string
    snapshotId: string
    tags:
        - string
    userName: string
    version: string
    volumeSizeInGb: 0
    volumeType: string
Copy

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

NodeNumber This property is required. int
Number of nodes in the instance
NodeType This property is required. string
The type of MongoDB® intance to create.
Name string
Name of the MongoDB® instance.
Password string
Password of the user.
PrivateNetwork Pulumiverse.Scaleway.Mongodb.Inputs.InstancePrivateNetwork
Private Network endpoints of the Database Instance.
ProjectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
PublicNetwork Pulumiverse.Scaleway.Mongodb.Inputs.InstancePublicNetwork
Public network specs details.
Region Changes to this property will trigger replacement. string
The region you want to attach the resource to
Settings Dictionary<string, string>
Map of settings to define for the instance.
SnapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
Tags List<string>
List of tags attached to the MongoDB® instance.
UserName string
Name of the user created when the intance is created.
Version string
MongoDB® version of the instance.
VolumeSizeInGb int
Volume size in GB.
VolumeType string
Volume type of the instance.
NodeNumber This property is required. int
Number of nodes in the instance
NodeType This property is required. string
The type of MongoDB® intance to create.
Name string
Name of the MongoDB® instance.
Password string
Password of the user.
PrivateNetwork InstancePrivateNetworkArgs
Private Network endpoints of the Database Instance.
ProjectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
PublicNetwork InstancePublicNetworkArgs
Public network specs details.
Region Changes to this property will trigger replacement. string
The region you want to attach the resource to
Settings map[string]string
Map of settings to define for the instance.
SnapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
Tags []string
List of tags attached to the MongoDB® instance.
UserName string
Name of the user created when the intance is created.
Version string
MongoDB® version of the instance.
VolumeSizeInGb int
Volume size in GB.
VolumeType string
Volume type of the instance.
nodeNumber This property is required. Integer
Number of nodes in the instance
nodeType This property is required. String
The type of MongoDB® intance to create.
name String
Name of the MongoDB® instance.
password String
Password of the user.
privateNetwork InstancePrivateNetwork
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. String
The project_id you want to attach the resource to
publicNetwork InstancePublicNetwork
Public network specs details.
region Changes to this property will trigger replacement. String
The region you want to attach the resource to
settings Map<String,String>
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. String
Snapshot ID to restore the MongoDB® instance from.
tags List<String>
List of tags attached to the MongoDB® instance.
userName String
Name of the user created when the intance is created.
version String
MongoDB® version of the instance.
volumeSizeInGb Integer
Volume size in GB.
volumeType String
Volume type of the instance.
nodeNumber This property is required. number
Number of nodes in the instance
nodeType This property is required. string
The type of MongoDB® intance to create.
name string
Name of the MongoDB® instance.
password string
Password of the user.
privateNetwork InstancePrivateNetwork
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
publicNetwork InstancePublicNetwork
Public network specs details.
region Changes to this property will trigger replacement. string
The region you want to attach the resource to
settings {[key: string]: string}
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
tags string[]
List of tags attached to the MongoDB® instance.
userName string
Name of the user created when the intance is created.
version string
MongoDB® version of the instance.
volumeSizeInGb number
Volume size in GB.
volumeType string
Volume type of the instance.
node_number This property is required. int
Number of nodes in the instance
node_type This property is required. str
The type of MongoDB® intance to create.
name str
Name of the MongoDB® instance.
password str
Password of the user.
private_network InstancePrivateNetworkArgs
Private Network endpoints of the Database Instance.
project_id Changes to this property will trigger replacement. str
The project_id you want to attach the resource to
public_network InstancePublicNetworkArgs
Public network specs details.
region Changes to this property will trigger replacement. str
The region you want to attach the resource to
settings Mapping[str, str]
Map of settings to define for the instance.
snapshot_id Changes to this property will trigger replacement. str
Snapshot ID to restore the MongoDB® instance from.
tags Sequence[str]
List of tags attached to the MongoDB® instance.
user_name str
Name of the user created when the intance is created.
version str
MongoDB® version of the instance.
volume_size_in_gb int
Volume size in GB.
volume_type str
Volume type of the instance.
nodeNumber This property is required. Number
Number of nodes in the instance
nodeType This property is required. String
The type of MongoDB® intance to create.
name String
Name of the MongoDB® instance.
password String
Password of the user.
privateNetwork Property Map
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. String
The project_id you want to attach the resource to
publicNetwork Property Map
Public network specs details.
region Changes to this property will trigger replacement. String
The region you want to attach the resource to
settings Map<String>
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. String
Snapshot ID to restore the MongoDB® instance from.
tags List<String>
List of tags attached to the MongoDB® instance.
userName String
Name of the user created when the intance is created.
version String
MongoDB® version of the instance.
volumeSizeInGb Number
Volume size in GB.
volumeType String
Volume type of the instance.

Outputs

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

CreatedAt string
The date and time of the creation of the MongoDB® instance.
Id string
The provider-assigned unique ID for this managed resource.
UpdatedAt string
The date and time of the last update of the MongoDB® instance.
CreatedAt string
The date and time of the creation of the MongoDB® instance.
Id string
The provider-assigned unique ID for this managed resource.
UpdatedAt string
The date and time of the last update of the MongoDB® instance.
createdAt String
The date and time of the creation of the MongoDB® instance.
id String
The provider-assigned unique ID for this managed resource.
updatedAt String
The date and time of the last update of the MongoDB® instance.
createdAt string
The date and time of the creation of the MongoDB® instance.
id string
The provider-assigned unique ID for this managed resource.
updatedAt string
The date and time of the last update of the MongoDB® instance.
created_at str
The date and time of the creation of the MongoDB® instance.
id str
The provider-assigned unique ID for this managed resource.
updated_at str
The date and time of the last update of the MongoDB® instance.
createdAt String
The date and time of the creation of the MongoDB® instance.
id String
The provider-assigned unique ID for this managed resource.
updatedAt String
The date and time of the last update of the MongoDB® instance.

Look up Existing Instance Resource

Get an existing Instance 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?: InstanceState, opts?: CustomResourceOptions): Instance
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        created_at: Optional[str] = None,
        name: Optional[str] = None,
        node_number: Optional[int] = None,
        node_type: Optional[str] = None,
        password: Optional[str] = None,
        private_network: Optional[InstancePrivateNetworkArgs] = None,
        project_id: Optional[str] = None,
        public_network: Optional[InstancePublicNetworkArgs] = None,
        region: Optional[str] = None,
        settings: Optional[Mapping[str, str]] = None,
        snapshot_id: Optional[str] = None,
        tags: Optional[Sequence[str]] = None,
        updated_at: Optional[str] = None,
        user_name: Optional[str] = None,
        version: Optional[str] = None,
        volume_size_in_gb: Optional[int] = None,
        volume_type: Optional[str] = None) -> Instance
func GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)
public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)
public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)
resources:  _:    type: scaleway:mongodb:Instance    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
CreatedAt string
The date and time of the creation of the MongoDB® instance.
Name string
Name of the MongoDB® instance.
NodeNumber int
Number of nodes in the instance
NodeType string
The type of MongoDB® intance to create.
Password string
Password of the user.
PrivateNetwork Pulumiverse.Scaleway.Mongodb.Inputs.InstancePrivateNetwork
Private Network endpoints of the Database Instance.
ProjectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
PublicNetwork Pulumiverse.Scaleway.Mongodb.Inputs.InstancePublicNetwork
Public network specs details.
Region Changes to this property will trigger replacement. string
The region you want to attach the resource to
Settings Dictionary<string, string>
Map of settings to define for the instance.
SnapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
Tags List<string>
List of tags attached to the MongoDB® instance.
UpdatedAt string
The date and time of the last update of the MongoDB® instance.
UserName string
Name of the user created when the intance is created.
Version string
MongoDB® version of the instance.
VolumeSizeInGb int
Volume size in GB.
VolumeType string
Volume type of the instance.
CreatedAt string
The date and time of the creation of the MongoDB® instance.
Name string
Name of the MongoDB® instance.
NodeNumber int
Number of nodes in the instance
NodeType string
The type of MongoDB® intance to create.
Password string
Password of the user.
PrivateNetwork InstancePrivateNetworkArgs
Private Network endpoints of the Database Instance.
ProjectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
PublicNetwork InstancePublicNetworkArgs
Public network specs details.
Region Changes to this property will trigger replacement. string
The region you want to attach the resource to
Settings map[string]string
Map of settings to define for the instance.
SnapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
Tags []string
List of tags attached to the MongoDB® instance.
UpdatedAt string
The date and time of the last update of the MongoDB® instance.
UserName string
Name of the user created when the intance is created.
Version string
MongoDB® version of the instance.
VolumeSizeInGb int
Volume size in GB.
VolumeType string
Volume type of the instance.
createdAt String
The date and time of the creation of the MongoDB® instance.
name String
Name of the MongoDB® instance.
nodeNumber Integer
Number of nodes in the instance
nodeType String
The type of MongoDB® intance to create.
password String
Password of the user.
privateNetwork InstancePrivateNetwork
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. String
The project_id you want to attach the resource to
publicNetwork InstancePublicNetwork
Public network specs details.
region Changes to this property will trigger replacement. String
The region you want to attach the resource to
settings Map<String,String>
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. String
Snapshot ID to restore the MongoDB® instance from.
tags List<String>
List of tags attached to the MongoDB® instance.
updatedAt String
The date and time of the last update of the MongoDB® instance.
userName String
Name of the user created when the intance is created.
version String
MongoDB® version of the instance.
volumeSizeInGb Integer
Volume size in GB.
volumeType String
Volume type of the instance.
createdAt string
The date and time of the creation of the MongoDB® instance.
name string
Name of the MongoDB® instance.
nodeNumber number
Number of nodes in the instance
nodeType string
The type of MongoDB® intance to create.
password string
Password of the user.
privateNetwork InstancePrivateNetwork
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. string
The project_id you want to attach the resource to
publicNetwork InstancePublicNetwork
Public network specs details.
region Changes to this property will trigger replacement. string
The region you want to attach the resource to
settings {[key: string]: string}
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. string
Snapshot ID to restore the MongoDB® instance from.
tags string[]
List of tags attached to the MongoDB® instance.
updatedAt string
The date and time of the last update of the MongoDB® instance.
userName string
Name of the user created when the intance is created.
version string
MongoDB® version of the instance.
volumeSizeInGb number
Volume size in GB.
volumeType string
Volume type of the instance.
created_at str
The date and time of the creation of the MongoDB® instance.
name str
Name of the MongoDB® instance.
node_number int
Number of nodes in the instance
node_type str
The type of MongoDB® intance to create.
password str
Password of the user.
private_network InstancePrivateNetworkArgs
Private Network endpoints of the Database Instance.
project_id Changes to this property will trigger replacement. str
The project_id you want to attach the resource to
public_network InstancePublicNetworkArgs
Public network specs details.
region Changes to this property will trigger replacement. str
The region you want to attach the resource to
settings Mapping[str, str]
Map of settings to define for the instance.
snapshot_id Changes to this property will trigger replacement. str
Snapshot ID to restore the MongoDB® instance from.
tags Sequence[str]
List of tags attached to the MongoDB® instance.
updated_at str
The date and time of the last update of the MongoDB® instance.
user_name str
Name of the user created when the intance is created.
version str
MongoDB® version of the instance.
volume_size_in_gb int
Volume size in GB.
volume_type str
Volume type of the instance.
createdAt String
The date and time of the creation of the MongoDB® instance.
name String
Name of the MongoDB® instance.
nodeNumber Number
Number of nodes in the instance
nodeType String
The type of MongoDB® intance to create.
password String
Password of the user.
privateNetwork Property Map
Private Network endpoints of the Database Instance.
projectId Changes to this property will trigger replacement. String
The project_id you want to attach the resource to
publicNetwork Property Map
Public network specs details.
region Changes to this property will trigger replacement. String
The region you want to attach the resource to
settings Map<String>
Map of settings to define for the instance.
snapshotId Changes to this property will trigger replacement. String
Snapshot ID to restore the MongoDB® instance from.
tags List<String>
List of tags attached to the MongoDB® instance.
updatedAt String
The date and time of the last update of the MongoDB® instance.
userName String
Name of the user created when the intance is created.
version String
MongoDB® version of the instance.
volumeSizeInGb Number
Volume size in GB.
volumeType String
Volume type of the instance.

Supporting Types

InstancePrivateNetwork
, InstancePrivateNetworkArgs

PnId This property is required. string
The ID of the Private Network.
DnsRecords List<string>
List of DNS records for your endpoint.
Id string
The ID of the endpoint.
Ips List<string>
List of IP addresses for your endpoint.
Port int
TCP port of the endpoint.
PnId This property is required. string
The ID of the Private Network.
DnsRecords []string
List of DNS records for your endpoint.
Id string
The ID of the endpoint.
Ips []string
List of IP addresses for your endpoint.
Port int
TCP port of the endpoint.
pnId This property is required. String
The ID of the Private Network.
dnsRecords List<String>
List of DNS records for your endpoint.
id String
The ID of the endpoint.
ips List<String>
List of IP addresses for your endpoint.
port Integer
TCP port of the endpoint.
pnId This property is required. string
The ID of the Private Network.
dnsRecords string[]
List of DNS records for your endpoint.
id string
The ID of the endpoint.
ips string[]
List of IP addresses for your endpoint.
port number
TCP port of the endpoint.
pn_id This property is required. str
The ID of the Private Network.
dns_records Sequence[str]
List of DNS records for your endpoint.
id str
The ID of the endpoint.
ips Sequence[str]
List of IP addresses for your endpoint.
port int
TCP port of the endpoint.
pnId This property is required. String
The ID of the Private Network.
dnsRecords List<String>
List of DNS records for your endpoint.
id String
The ID of the endpoint.
ips List<String>
List of IP addresses for your endpoint.
port Number
TCP port of the endpoint.

InstancePublicNetwork
, InstancePublicNetworkArgs

DnsRecord string
The DNS record of your endpoint
Id string
The ID of the endpoint.
Port int
TCP port of the endpoint.
DnsRecord string
The DNS record of your endpoint
Id string
The ID of the endpoint.
Port int
TCP port of the endpoint.
dnsRecord String
The DNS record of your endpoint
id String
The ID of the endpoint.
port Integer
TCP port of the endpoint.
dnsRecord string
The DNS record of your endpoint
id string
The ID of the endpoint.
port number
TCP port of the endpoint.
dns_record str
The DNS record of your endpoint
id str
The ID of the endpoint.
port int
TCP port of the endpoint.
dnsRecord String
The DNS record of your endpoint
id String
The ID of the endpoint.
port Number
TCP port of the endpoint.

Import

MongoDB® instance can be imported using the id, e.g.

bash

$ pulumi import scaleway:mongodb/instance:Instance main fr-par-1/11111111-1111-1111-1111-111111111111
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
scaleway pulumiverse/pulumi-scaleway
License
Apache-2.0
Notes
This Pulumi package is based on the scaleway Terraform Provider.