Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPI] Prefix names of objects in OpenShift recipe on provisioning step #5963

Closed
sleshchenko opened this issue Aug 10, 2017 · 0 comments
Closed
Assignees
Labels
kind/task Internal things, technical debt, and to-do tasks to be performed. target/branch Indicates that a PR will be merged into a branch other than master.

Comments

@sleshchenko
Copy link
Member

sleshchenko commented Aug 10, 2017

It is needed to rename objects in OpenShift recipe to make it possible to create two OpenShift workspace in one project aka namespace.
To make it possible it is needed to prefixes all objects in original user's OpenShift Recipe with some unique for workspace value like id.

It would be more readable to prefix them with workspace name (it is also unique) but OpenShift objects name is not сompatible with workspace name pattern:
Workspace name pattern is [a-zA-Z0-9][-_.a-zA-Z0-9]{1,18}[a-zA-Z0-9] see
While OpenShift object name must match the regex [a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)* (e.g. 'example.com')

Now it is known the following list of fields which must be updated:

Pod
    metadata:
        name: PREFIX
Service
    metadata:
        name: DO_NOT_PREFIX,  # see UPDATE
Route
    metadata:
        name: PREFIX

Update: Services names should not be prefixed because a user may use it for communication between pods. Note that in this case, a workspace will fail to start if there is another running workspace which contains at least one service with the same name.
Removed prefixing of labels and selectors keys. Issues with ensuring that services use only pods in the same workspace will be solved by adding label and selector fields entry with workspace id within this issue.

@sleshchenko sleshchenko added kind/task Internal things, technical debt, and to-do tasks to be performed. team/platform labels Aug 10, 2017
@sleshchenko sleshchenko changed the title Add prefixes to names of objects in OpenShift recipe on provisioning step Prefix names of objects in OpenShift recipe on provisioning step Aug 10, 2017
@akorneta akorneta self-assigned this Sep 14, 2017
@akorneta akorneta added target/branch Indicates that a PR will be merged into a branch other than master. status/in-progress This issue has been taken by an engineer and is under active development. labels Sep 14, 2017
@benoitf benoitf changed the title Prefix names of objects in OpenShift recipe on provisioning step [SPI] Prefix names of objects in OpenShift recipe on provisioning step Sep 15, 2017
@akorneta akorneta added status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. and removed status/in-progress This issue has been taken by an engineer and is under active development. status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. labels Sep 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/task Internal things, technical debt, and to-do tasks to be performed. target/branch Indicates that a PR will be merged into a branch other than master.
Projects
None yet
Development

No branches or pull requests

2 participants