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

docs: Revamp info on how to add a new hub #498

Merged
merged 7 commits into from
Aug 2, 2021
Merged
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
87 changes: 82 additions & 5 deletions docs/howto/operate/add-hub.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,85 @@
# Add a new hub

Adding a new hub requires that we do three things:
## Step 0: Open a GitHub issue to track hub creation

1. [Create a new GitHub issue for the hub](https://github.com/2i2c-org/pilot-hubs/issues/new).
2. Create the hub via appending a new hub entry in the appropriate cluster file under
`config/hubs` file (see [](../../topic/config.md) for more information).
3. Start following [team process](team-process) around operating the hubs.
In order to track progress on deploying the new hub, [open a GitHub issue in the
`pilot-hubs/` repository](https://github.com/2i2c-org/pilot-hubs/issues/new/choose).
Make sure to choose the `new-hub` issue template.

## Step 1: Decide where the hub will live
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
## Step 1: Decide where the hub will live
## Step 0: Open a GitHub issue
In order to track progress on deploying the new hub, [open a GitHub issue in the `support/` repository](https://github.com/2i2c-org/support/issues/new/choose).
Make sure to choose the `new-hub` issue template.
## Step 1: Decide where the hub will live

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

per @GeorgianaElena's comment, I've created an empty support/ repo that we can start to modify to suit our support processes. For creating a hub, how about the text above + we create an issue template for creating a new hub that has a checklist corresponding to each of the steps here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I incorporated this, but pointing to pilot-hubs still. 2i2c-org/team-compass#151 talks about the support/ repository.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that is OK for now, @choldgraf?


Hubs need to exist on a kubernetes cluster, so we will need to
decide which cluster it should live in.
damianavila marked this conversation as resolved.
Show resolved Hide resolved

1. For standalone hubs where we are being paid or the client has cloud
credits, we will need to create a cluster specifically for this hub
before deploying it. As a general rule, we will create one cluster per
billing account.
2. For hubs we are running for free, they will go into the `pilot-hubs`
cluster.
3. Hubs run with the support of [cloudbank](https://www.cloudbank.org/),
will go in the `cloudbank` cluster.

damianavila marked this conversation as resolved.
Show resolved Hide resolved
Each cluster has configuration + list of hubs it supports under
`config/hubs/<cluster-name>.cluster.yaml`.

## Step 2: Decide the template used for the hub

Hub templates map on to different major use-cases that we aim to enable.
Ask the hub user(s) about their needs and expected usage, and use their answer to select a [hub template](../../topic/hub-templates.md).
to be used.

damianavila marked this conversation as resolved.
Show resolved Hide resolved
## Step 3: Decide the authentication provider to be used

In consultation with the users, decide
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On this page, perhaps we should define a Community Champion role for a hub (or maybe we should re-name this "user representative"?) and then suggest that we ask this person questions throughout the process, rather than to use a generic "user" identity like here? I'd like us to move away from the possibility that multiple users on a hub might be needed to answer questions.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like us to move away from the possibility that multiple users on a hub might be needed to answer questions.

💯

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@choldgraf, until we have the Community champion role well defined, I think this is OK for now. Let us know if you disagree.

[which authentication provider](https://pilot.2i2c.org/en/latest/admin/configuration/login.html#authentication)
the hub should use.


```{note}
While this can be changed later, it's a messy
process - so we should try to get this right the first time
```

## Step 4: Decide the user image for the hub

The default user image is present in this repository (`images/user`),
and is geared towards simple datascience classes - with both R and
Python. Determine if this is acceptable - if not, you need to
make a [custom image](../configure/update-env.md) for them.

damianavila marked this conversation as resolved.
Show resolved Hide resolved
## Step 5: Add hub config

Add an entry for the hub in `config/hubs/<cluster-name>.cluster.yaml` for this hub.
The following docs might be helpful:

1. [Configuration Structure](../../topic/config.md)
2. [JSON Schema for `.cluster.yaml` file](https://github.com/2i2c-org/pilot-hubs/blob/master/config/hubs/schema.yaml)
3. [Zero to JupyterHub on k8s Docs](https://zero-to-jupyterhub.readthedocs.io/en/latest/), since ultimately
that is what we are configuring.

## Step 6: Deploy manually and test

[Deploy the hub manually](./manual-deploy.md) and test to make sure it works
damianavila marked this conversation as resolved.
Show resolved Hide resolved
the way you would like it to. This might take some iteration and multiple
tries. Specifically test that at least the following work ok:

1. Authentication provider
2. Admin user access
3. User image in use (check the `JUPYTER_IMAGE` environment variable in a spawned server)
4. Default user interface when the user logs in (lab, notebook, rstudio, retrolab, etc)
damianavila marked this conversation as resolved.
Show resolved Hide resolved
5. Home page display configuration
6. (Optionally) `dask-gateway` functionality
7. (Optionally) Access to any cloud resources (like storage buckets, etc)
granted to the hub users
damianavila marked this conversation as resolved.
Show resolved Hide resolved

## Step 7: Make a PR

Make a PR with your changes, referencing the issue for creation of the hub. Seek
review from someone else, and get this merged!

Getting this merged will mark the hub as being deployed.

Finally, notify the users of the hub that it is now deployed, and ask that they test it out to make sure it works as expected.
If they are happy with the result, then close the issue for deploying the new hub.
Congratulations, you are done! 🎉