Automatically generate Organization Namespace Name #44

Closed
opened 2025-04-09 06:33:34 +00:00 by tobru · 0 comments
Owner

Current Situation

We allow manually setting the name of the Kubernetes Namespace when creating the organization. This is suboptimal because the namespace cannot be renamed on the Kubernetes API. Should the user mistype it or the organization name changes, the Namespace name cannot be renamed.

As the name of the organization namespace is a technical implementation detail and isn't surfaced to the user of the Portal (for shared control-planes, see #45), we should automatically generate the name of the namespace.

Change Required

Do not let the user choose the name of the organization namespace, instead generate it. We have several possibilities to generate the name:

  • UUID: While quick and easy, debugging something on the control-plane makes this a real pain
  • Generate Name: Something like "purple-brook" or "still-sun" (e.g. Haikunator) - while cool, it didn't serve us too well in the past
  • DB ID: Use the database ID to create a name like org-$ID

Let's use: org-$ID, where ID is the database ID of the organization. By prefixing with org we adhere to RFC 1035 Label Names.

Keep the field "Kubernetes Namespace" in the model and continue using the content of this field should it be set, otherwise use the org-$ID name.

## Current Situation We allow manually setting the name of the Kubernetes Namespace when creating the organization. This is suboptimal because the namespace cannot be renamed on the Kubernetes API. Should the user mistype it or the organization name changes, the Namespace name cannot be renamed. As the name of the organization namespace is a technical implementation detail and isn't surfaced to the user of the Portal (for shared control-planes, see #45), we should automatically generate the name of the namespace. ## Change Required Do not let the user choose the name of the organization namespace, instead generate it. We have several possibilities to generate the name: * **UUID**: While quick and easy, debugging something on the control-plane makes this a real pain * **Generate Name**: Something like "purple-brook" or "still-sun" (e.g. Haikunator) - while cool, it didn't serve us too well in the past * **DB ID**: Use the database ID to create a name like `org-$ID` Let's use: `org-$ID`, where ID is the database ID of the organization. By prefixing with `org` we adhere to [RFC 1035 Label Names](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#rfc-1035-label-names). Keep the field "Kubernetes Namespace" in the model and continue using the content of this field should it be set, otherwise use the `org-$ID` name.
tobru added this to the Servala Portal MVP milestone 2025-04-09 06:33:34 +00:00
tobru added the
change
label 2025-04-09 06:33:34 +00:00
tobru added this to the Servala Portal project 2025-04-09 06:33:34 +00:00
tobru changed title from Organization Namespace Naming Change to Automatically generate Organization Namespace Name 2025-04-09 06:35:09 +00:00
rixx closed this issue 2025-04-09 14:07:51 +00:00
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: servala/servala-portal#44
No description provided.