Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@ categories:
- postgresql-and-mysql
---

<Message type="important">
Managed MongoDB® is currently in private beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

Managed MongoDB® provides fully-managed document Database Instances, with a MongoDB®-compatible API layer over a PostgreSQL engine to store and retrieve data.

This means you can use MongoDB® command line tools to use and manage your MongoDB® Databases.
Expand Down
8 changes: 0 additions & 8 deletions pages/managed-mongodb-databases/concepts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in private beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

## Block Storage Legacy

Block Storage Legacy is a volume type that is decoupled from your compute resources. You can increase your storage space to up to 10 TB without changing your node type.
Expand Down Expand Up @@ -60,10 +56,6 @@ Compared to traditional database management, which requires customers to provisi

<Macro id="region-and-az" />

<Message type="requirement">
During the MongoDB® Private Beta, only the France region is available.
</Message>

## Replica-set 1-node

An Instance of MongoDB® that runs as a single server and does not provide redundancy or high availability.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

<Macro id="requirements" />

- A Scaleway account logged into the [console](https://console.scaleway.com)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

Managed MongoDB® provides fully-managed document Database Instances, with MongoDB® as a database engine.

Document databases enable users to store and retrieve data in a document format, such as `json`. Compared to traditional relational databases where data is stored in a table-like format, document-type storage supports storing multiple nested keys and values in each document key.
Expand All @@ -41,7 +37,7 @@ Document databases enable users to store and retrieve data in a document format,
- Configure storage settings. You can:
- Choose the [IOPS](/block-storage/concepts/#iops) setting, between **5k** and **15k**.
- Define your volume size. Block Storage volumes can increase up to 10 TB.
- Review the snapshot configuration. During the private beta, only manual snapshots are available.
- Review the snapshot configuration.
4. Configure your Network. Choose one or both of the options below:
- **Attach to Private Network**: allows your databases to communicate in an isolated and secure network without requiring a public IP address. If you select this option, you must either:
- Select and attach an existing Private Network and select the network from the drop-down list.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

<Macro id="requirements" />

- A Scaleway account logged into the [console](https://console.scaleway.com)
Expand Down
4 changes: 0 additions & 4 deletions pages/managed-mongodb-databases/how-to/increase-volume.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

You can increase the Block Storage volume of your MongoDB® Database Instance in the Scaleway console anytime.

<Macro id="requirements" />
Expand Down
4 changes: 0 additions & 4 deletions pages/managed-mongodb-databases/how-to/manage-snapshots.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

[Snapshots](/managed-mongodb-databases/how-to/manage-snapshots/) allow you to restore data in a new Database Instance.

You can have up to 100 snapshots per Instance and project (depending on quotas).
Expand Down
131 changes: 123 additions & 8 deletions pages/managed-mongodb-databases/how-to/manage-users.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,13 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. Click [here](https://www.scaleway.com/en/managed-mongodb/) to join the waiting list.
</Message>

Users can connect to a database and access its data.

<Message type="important">
During the MongoDB® private beta, you can have only one user per Instance. The default user has admin rights on the Database Instance. The name and password of this default user can be set upon Database Instance creation.
</Message>

<Macro id="requirements" />

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- A valid [API key](/iam/how-to/create-api-keys/)
- A [MongoDB® Database Instance](/managed-mongodb-databases/quickstart)

## How to change the password of your user
Expand All @@ -37,3 +30,125 @@ Users can connect to a database and access its data.
4. Click **Change password** to do so. A pop-up appears.
5. Enter your new password and confirm.

## How to create multi-users via the API

When you create your MongoDB® Database Instance, the first user is created by default and has admin rights.

You can create more users and grant them pre-set roles via the [Scaleway Managed MongoDB® API](https://www.scaleway.com/en/developers/api/managed-database-mongodb/).

<Message type="important">
All users you create have at first administrator roles, which can be changed after creation with the [Apply user roles](https://www.scaleway.com/en/developers/api/managed-database-mongodb/#path-users-apply-user-roles) call. The default user's role cannot be changed.
</Message>

### How to create a user

1. Edit the POST request payload you will use to create your user. Replace the values of each parameter with your values of choice following the parameter descriptions below.
```
{
"name": "<username>",
"password": "<password>",
}
```

| Parameter | Description |
| :--------------- | :----------------------------------------------------------------- |
| `name` | Set a name for the database user. |
| `password` | Set a password for the database user.|

2. Run the following command to create a user. Make sure you include the payload you edited in the previous step. `{instance_id}` corresponds to the UUID of the Managed MongoDB®.
```
curl -X POST \
-H "X-Auth-Token: $SCW_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "<username>",
"password": "<password>",
}' \
"https://api.scaleway.com/mongodb/v1alpha1/regions/$SCW_REGION/par/instances/{instance_id}/users"
```

You should get a response like the following:
```
{
"name": "<username>",
"password": "<password>",
"roles": [
{
"role": "read_write",
"any_database": true
},
{
"role": "db_admin",
"any_database": true
},
{
"role": "sync",
"any_database": true
}
]
}
```

All users you create will have the `read_write`, `db_admin` and `sync` roles on all databases by default.

You can follow the steps below to update a user's role(s) to the one(s) of your choice.

### How to apply a role to a user

1. Edit the POST request payload you will use to update the user role. Replace the values of each parameter with your values of choice following the parameter descriptions below.

In this example, we define a single `read_write` role for the user. This role applies only in the `example-db` database.

<Message type="tip">
To grant the user this role in all databases, you can set `any_database` to true.
</Message>

```
{
"name": "<username>",
"roles": [
{
"role": "read_write",
"database": "example-db",
"any_database": false
}
]
}
```

| Role | Description |
| :--------------- | :----------------------------------------------------------------- |
| `read` | Read privileges on all non-system collections and the `system.js` collection. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/manual/reference/built-in-roles/#mongodb-authrole-read) for an extensive list of the privileges granted to this role. |
| `read_write` | Read and write privileges on all non-system collections and the `system.js` collection. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/manual/reference/built-in-roles/#mongodb-authrole-readWrite) for an extensive list of the privileges granted to this role. |
| `db_admin` | Privileges to perform administrative tasks on the database, such as schema-related tasks, indexing, and gathering statistics. This role does not grant privileges for user and role management. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/manual/reference/built-in-roles/#mongodb-authrole-dbAdmin) for an extensive list of the privileges granted to this role. |
| `sync` | Role that aggregates three MongoDB roles: |
| | `clusterMonitor` - Read-only access to monitoring tools. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/upcoming/reference/built-in-roles/#mongodb-authrole-clusterMonitor) for an extensive list of the privileges granted to this role. |
| | `backup` - Grants the minimal privileges needed to back up data. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/upcoming/reference/built-in-roles/#mongodb-authrole-backup) for an extensive list of the privileges granted to this role. |
| | `restore` - Grants the privileges needed to restore data from backups. Refer to the [official MongoDB® documentation](https://www.mongodb.com/docs/upcoming/reference/built-in-roles/#mongodb-authrole-restore) for an extensive list of the privileges granted to this role. |

2. Run the following command to apply a new role to the user. Make sure you include the payload you edited in the previous step and that you replace the parameters in the call with your information. `{instance_id}` corresponds to the UUID of the Managed MongoDB®.

```
curl -X PUT \
-H "X-Auth-Token: $SCW_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "<username>",
"roles": [
{
"role": "read_write",
"database": "<name_of_database>"
"any_database": false
}
]
}' \
"https://api.scaleway.com/mongodb/v1alpha1/regions/$SCW_REGION/instances/{instance_id}/roles"
```

If the call was successful, you will get the payload with the new role(s) as a response.

<Message type="note">
Assigning roles upon user creation will be possible by the second half of 2025. Refer to the [Scaleway Changelog](/docs/changelog/?product=mongodb) to keep up with the latest Managed MongoDB® updates.
</Message>


4 changes: 0 additions & 4 deletions pages/managed-mongodb-databases/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ content:
label="Managed MongoDB® Quickstart"
/>

<Message type="important">
Managed MongoDB® is currently in public beta. [Fill out the form](https://www.scaleway.com/en/managed-mongodb-form/) to be notified of the General Availability or if you want to get in touch with our team about Managed MongoDB®.
</Message>

## Getting Started

<Grid>
Expand Down
4 changes: 0 additions & 4 deletions pages/managed-mongodb-databases/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ categories:
- managed-databases
---

<Message type="important">
Managed MongoDB® is currently in public beta. [Fill out the form](https://www.scaleway.com/en/managed-mongodb/) to be notified of the General Availability or if you want to get in touch with our team about Managed MongoDB®.
</Message>

Managed MongoDB® provides fully-managed document Database Instances, with MongoDB® as a database engine.

MongoDB® databases enable users to store and retrieve data in a document format, such as `json`. Compared to traditional relational databases where data is stored in a table-like format, document-type storage supports storing multiple nested keys and values in each document key.
Expand Down
Loading