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

Add a naas.space.add function #7

Open
Dr0p42 opened this issue May 23, 2023 · 0 comments
Open

Add a naas.space.add function #7

Dr0p42 opened this issue May 23, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@Dr0p42
Copy link
Contributor

Dr0p42 commented May 23, 2023

We need to implement a naas.space.add function making it possible to create a new space.

The specifications are:

naas.space.add(
  space_name="my-data-product",
  space_type="docker",  
  dockerfile_path="Dockerfile",
  docker_context=".",
  container_port="8080",
  generate_ci=True, 
  ci_type="github-actions", 
  cpu=None,
  memory=None
) 

All values should be default, only the space_name should be required.

space_name: The name the user wants to give to the space.
space_type: The type of space to create. This is mainly to make it easier for the user in the case it's not of type docker. We can provide default Dockerfiles etc if needed.
dockerfile_path: The path where the Dockerfile is in the project. Starting from the root folder.
docker_context: From which folder we should build the container.
container_port: On which port the container will listen once started. This should be used to configure the Knative space.
generate_ci: Wether we should generate the CI/CD configuration for the user.
ci_type: The type of CI to which we want to generate the configuration for.
cpu: The cpu request for the container to run.
memory: The memory request for the container to run.

This is a low code formula that should take advantage of other already existing functions allowing to do the following:

  • Create a new Docker registry on space.naas.ai
  • Create a new space on space.naas.ai
  • Generate CI/CD for github.

Estimate: 3
Priority: low

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: 👀 In review
Development

No branches or pull requests

2 participants