Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 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
24 changes: 4 additions & 20 deletions menu/navigation.json
Original file line number Diff line number Diff line change
Expand Up @@ -3630,12 +3630,8 @@
{
"items": [
{
"label": "Create a Functions namespace",
"slug": "create-a-functions-namespace"
},
{
"label": "Manage a Functions namespace",
"slug": "manage-a-functions-namespace"
"label": "Create, manage, and delete a namespace",
"slug": "create-manage-delete-functions-namespace"
},
{
"label": "Create a function",
Expand Down Expand Up @@ -3676,10 +3672,6 @@
{
"label": "Delete a function",
"slug": "delete-a-function"
},
{
"label": "Delete a Functions namespace",
"slug": "delete-a-functions-namespace"
}
],
"label": "How to",
Expand Down Expand Up @@ -3796,12 +3788,8 @@
{
"items": [
{
"label": "Create a Containers namespace",
"slug": "create-a-containers-namespace"
},
{
"label": "Manage a Containers namespace",
"slug": "manage-a-containers-namespace"
"label": "Create, manage, and delete a namespace",
"slug": "create-manage-delete-containers-namespace"
},
{
"label": "Deploy a container",
Expand Down Expand Up @@ -3838,10 +3826,6 @@
{
"label": "Delete a container",
"slug": "delete-a-container"
},
{
"label": "Delete a Containers namespace",
"slug": "delete-a-containers-namespace"
}
],
"label": "How to",
Expand Down
2 changes: 1 addition & 1 deletion serverless/containers/concepts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ A vCPU (Virtual Central Processing Unit) is equivalent to 1000 mVCPU.

## Namespace

A namespace is a project that allows you to [group your containers](/serverless/containers/how-to/create-a-containers-namespace/). Containers in the same Namespace can share environment variables and access tokens, defined at the namespace level.
A namespace is a project that allows you to [group your containers](/serverless/containers/how-to/create-manage-delete-containers-namespace/). Containers in the same Namespace can share environment variables and access tokens, defined at the namespace level.

## NATS trigger

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ A trigger can be an HTTP request, a message from a queue or stream, a CRON sched

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- Created a [containers namespace](/serverless/containers/how-to/create-a-containers-namespace/)
- Created a [containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/)
- Deployed a container from [Scaleway Container Registry](/serverless/containers/how-to/deploy-container/) or an [external registry](/serverless/containers/how-to/deploy-container/)
- [Activated SQS](/serverless/messaging/how-to/get-started/#how-to-activate-sqs-or-sns)
- [Created credentials](/serverless/messaging/how-to/create-credentials/) for SQS
Expand Down
34 changes: 0 additions & 34 deletions serverless/containers/how-to/create-a-containers-namespace.mdx

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ This page shows you how to create and manage an authentication token from the Sc

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- [Created a containers namespace](/serverless/containers/how-to/create-a-containers-namespace/)
- [Created a containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/)
- [Deployed a container](/serverless/containers/how-to/deploy-container/)

## Creating authentication tokens from the Scaleway console
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
---
meta:
title: How to create, manage and delete a Containers namespace
description: Create, manage, and delete namespaces in Scaleway Serverless Containers.
content:
h1: How to create, manage, and delete a Containers namespace
paragraph: Create, manage, and delete namespaces in Scaleway Serverless Containers.
tags: container namespace manage create delete environment variable secret
dates:
validation: 2024-11-14
posted: 2021-05-26
categories:
- serverless
- containers
---

This page shows you how to create and manage a Serverless Containers namespace. [Namespaces](/serverless/containers/concepts/#namespace) allow you to group your containers and share environment variables between them.

<Macro id="requirements" />

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization

## Creating a Serverless Containers namespace

1. Click **Containers** in the **Serverless** section of the side menu. The list of your containers namespaces displays.
2. Click **Create namespace**. If you have no existing Serverless Containers resources in your current Project, click **Deploy container**.
3. Complete the following steps in the wizard:
- Enter a **name**, and optionally a **description** for your namespace. The name must only contain alphanumeric characters and dashes.
- Choose a **region**, which is the geographical location in which your namespace will be deployed.
- Enter any **environment variables** required for your namespace. Environment variables configured in a namespace will be available in all containers/apps within the same namespace. For each environment variable, click **+Add new variable** and enter the key / value pair.
- Set secret environment variables (optional). **Secrets** are environment variables that are injected into your container and stored securely, but not displayed in the console after initial validation. Add a **key** and a **value**.
- Verify the **estimated cost**.
4. Click **Create namespace only** to finish, or click **Create namespace and add container** if you want to [deploy a container](/serverless/containers/how-to/deploy-container/) next.

## Managing a Serverless Containers namespace

### Generating and managing access tokens

The Scaleway console allows you to generate authentication tokens to grant users and applications access to the containers present in your namespace.

1. Click **Containers** in the **Serverless** section of the side menu. The containers page displays.

2. Click the containers namespace you want to manage.

3. Click the **Namespace settings** tab. Information about the region, registry endpoint and description of your namespace display.

4. Click **+ Generate token** to create an access token for this namespace.

<Message type="important">
The token key will only be available for copy once. Make sure to store it securely before leaving the page.
</Message>

Private containers present in your namespace now require the authentication token to be executed, as shown below:
```curl
curl -H "X-Auth-Token: <YOUR_NAMESPACE_TOKEN>" <YOUR_CONTAINER_ENDPOINT>
```

### Adding and managing environment variables and secrets

The Scaleway console allows you to define environment variables and secrets at the namespace-level to pass to the containers present in the namespace.

1. Click **Containers** in the **Serverless** section of the side menu. The containers page displays.

2. Click the containers namespace you want to manage.

3. Click the **Namespace settings** tab. Information about the region, registry endpoint and description of your namespace display.

4. Add environment variables by clicking the <Icon name="edit" /> icon, **+ Add variable**, entering the key/value pair, and clicking <Icon name="validate"/>.

5. Add secrets by clicking the <Icon name="edit" /> icon, **+ Add secret**, entering the key/value pair, and clicking <Icon name="validate"/>.

The environment variables and secrets defined will now be passed to your containers. Every container in a **ready** state is redeployed to take the change into account.

## Deleting a Serverless Containers namespace

<Message type="important">
- This action will permanently delete your namespace and all your containers will be lost.
- This action is irreversible.
- The Container Registry namespace associated with your Serverless Containers namespace will be deleted.
</Message>

1. Click **Containers** in the **Serverless** section of the side menu. The containers page displays.

2. Click the <Icon name="more" /> icon next to the namespace you want to delete, and select **Delete** from the drop-down menu.

3. Type **DELETE** in the pop-up that asks you to confirm the action, then click **Delete namespace**.

<Message type="tip">
You can also delete a namespace from the **Namespace settings** tab.
</Message>
39 changes: 0 additions & 39 deletions serverless/containers/how-to/delete-a-containers-namespace.mdx

This file was deleted.

2 changes: 1 addition & 1 deletion serverless/containers/how-to/deploy-container.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ You can deploy a container from the [Scaleway Container Registry](/containers/co

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- [Created a containers namespace](/serverless/containers/how-to/create-a-containers-namespace/)
- [Created a containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/)
- [Created a Container Registry namespace](/containers/container-registry/how-to/create-namespace/) and [pushed a container image](/containers/container-registry/how-to/push-images/) to it

## Deploy from the Scaleway Container Registry
Expand Down
31 changes: 0 additions & 31 deletions serverless/containers/how-to/manage-a-containers-namespace.mdx

This file was deleted.

2 changes: 1 addition & 1 deletion serverless/containers/how-to/secure-a-container.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ This page explains how to secure your container.

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- [Created a containers namespace](/serverless/containers/how-to/create-a-containers-namespace/)
- [Created a containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/)
- [Deployed a container](/serverless/containers/how-to/deploy-container/)
- Created an [authentication token](/serverless/containers/how-to/create-auth-token-from-console/) for your container

Expand Down
4 changes: 2 additions & 2 deletions serverless/containers/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ If you have no existing Serverless Containers resources in your current Project,
- Choose a **region**, which is the geographical location in which your namespace will be deployed.
4. Click **Create namespace and add container**. The container creation wizard displays.
<Message type="note">
Refer to the [How to create a Containers namespace](/serverless/containers/how-to/create-a-containers-namespace/) documentation page for more information on the different parameters.
Refer to the [How to create a Containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/) documentation page for more information on the different parameters.
</Message>
5. Complete the following steps in the wizard:
- Select the **Scaleway** Container Registry.
Expand Down Expand Up @@ -82,7 +82,7 @@ If you have no existing Serverless Containers resources in your current Project,
- Choose a **region**, which is the geographical location in which your namespace will be deployed.
4. Click **Create namespace and add container**. The container creation wizard displays.
<Message type="note">
Refer to the [How to create a Containers namespace](/serverless/containers/how-to/create-a-containers-namespace/) documentation page for more information on the different parameters.
Refer to the [How to create a Containers namespace](/serverless/containers/how-to/create-manage-delete-containers-namespace/) documentation page for more information on the different parameters.
</Message>
5. Complete the following steps in the wizard:
- Select the **External** container registry.
Expand Down
2 changes: 1 addition & 1 deletion serverless/functions/concepts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ A handler is a routine/function/method that processes specific events. Upon invo

## Namespace

A namespace is a project that allows you to [group your functions](/serverless/functions/how-to/create-a-functions-namespace/). Functions in the same Namespace can share environment variables and access tokens, defined at the namespace level.
A namespace is a project that allows you to [group your functions](/serverless/functions/how-to/create-manage-delete-functions-namespace/). Functions in the same Namespace can share environment variables and access tokens, defined at the namespace level.

## NATS trigger

Expand Down
2 changes: 1 addition & 1 deletion serverless/functions/how-to/add-trigger-to-a-function.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ A trigger can be an HTTP request, a message from a queue or stream, a CRON sched

- A Scaleway account logged into the [console](https://console.scaleway.com)
- [Owner](/identity-and-access-management/iam/concepts/#owner) status or [IAM permissions](/identity-and-access-management/iam/concepts/#permission) allowing you to perform actions in the intended Organization
- Created a [functions namespace](/serverless/functions/how-to/create-a-functions-namespace/)
- Created a [functions namespace](/serverless/functions/how-to/create-manage-delete-functions-namespace/)
- Created a [function](/serverless/functions/how-to/create-a-function/)
- [Activated SQS](/serverless/messaging/how-to/get-started/#how-to-activate-sqs-or-sns)
- [Created credentials](/serverless/messaging/how-to/create-credentials/) for SQS
Expand Down
Loading
Loading