Skip to content

Commit

Permalink
Add documentation on dependencies and migrate user management doc
Browse files Browse the repository at this point in the history
  • Loading branch information
adriansuarez committed Sep 5, 2023
1 parent cdd374c commit a6bc26d
Show file tree
Hide file tree
Showing 2 changed files with 408 additions and 7 deletions.
61 changes: 54 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,18 @@ $ helm repo add nuodb-cp https://nuodb.github.io/nuodb-cp-releases/charts

$ helm search repo nuodb-cp
NAME CHART VERSION APP VERSION DESCRIPTION
nuodb-cp/nuodb-cp-crd 2.1.0 2.1.0 NuoDB Control Plane custom resource definitions...
nuodb-cp/nuodb-cp-doc 2.1.0 2.1.0 Interactive documentation for the NuoDB Control...
nuodb-cp/nuodb-cp-operator 2.1.0 2.1.0 NuoDB Control Plane Operator
nuodb-cp/nuodb-cp-rest 2.1.0 2.1.0 NuoDB Control Plane REST service
nuodb-cp/nuodb-cp-crd 2.1.1 2.1.1 NuoDB Control Plane custom resource definitions...
nuodb-cp/nuodb-cp-doc 2.1.1 2.1.1 Interactive documentation for the NuoDB Control...
nuodb-cp/nuodb-cp-operator 2.1.1 2.1.1 NuoDB Control Plane Operator
nuodb-cp/nuodb-cp-rest 2.1.1 2.1.1 NuoDB Control Plane REST service
```

The NuoDB Control Plane can now be installed as follows:

```sh
helm install nuodb-cp-crd nuodb-cp/nuodb-cp-crd
helm install nuodb-cp-operator nuodb-cp/nuodb-cp-operator --set image.repository=ghcr.io/nuodb/nuodb-cp-images
helm install nuodb-cp-rest nuodb-cp/nuodb-cp-rest --set image.repository=ghcr.io/nuodb/nuodb-cp-images
helm install nuodb-cp-operator nuodb-cp/nuodb-cp-operator
helm install nuodb-cp-rest nuodb-cp/nuodb-cp-rest
```

## Helm charts
Expand All @@ -43,4 +43,51 @@ This must always be installed.
- `nuodb-cp-rest` contains a REST service that exposes access to the NuoDB Control Plane in a Database as a Service (DBaaS) model.
This allows users without access to Kubernetes APIs to manage NuoDB domains and databases.
- `nuodb-cp-doc` exposes an endpoint for interactive documentation of the NuoDB Control Plane REST service.
See https://nuodb.github.io/nuodb-cp-releases/api-doc for non-interactive documentation of the REST service.
See [api-doc](https://nuodb.github.io/nuodb-cp-releases/api-doc) for non-interactive documentation of the REST service.

## Dependencies

The NuoDB Control Plane depends on Kubernetes version 1.19 or later.

Additional dependencies are listed below.

### Ingress controller

An Ingress controller can be used to enable external connectivity to the NuoDB Control Plane REST API and to the databases created by it.
The [HAProxy Ingress Controller](https://github.com/haproxytech/kubernetes-ingress) can be installed as follows:

```sh
helm repo add haproxytech https://haproxytech.github.io/helm-charts
helm install haproxy-ingress haproxytech/kubernetes-ingress
```

### Cert-manager

To enable [admission webhooks](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/) that perform synchronous validation of NuoDB custom resource definitions, [cert-manager](https://github.com/cert-manager/cert-manager) should be installed to automatically generate certificates for the webhook server.

This can be done as follows:

```sh
helm repo add jetstack https://charts.jetstack.io
helm install cert-manager jetstack/cert-manager
```

## Usage

To enable multi-tenancy, NuoDB _databases_ managed by the NuoDB Control Plane are grouped into _projects_, which are themselves grouped into _organizations_.

Create a NuoDB database as follows:

1. Create a project using the `PUT projects` REST endpoint:
```sh
curl -X PUT -H 'Content-Type: application/json' \
$BASE_URL/projects/acme/messaging -d '{"sla": "dev", "tier": "n0.small"}'
```
2. Create a database using the `PUT databases` REST endpoint:
```sh
curl -X PUT -H 'Content-Type: application/json' \
$BASE_URL/databases/acme/messaging/demo -d '{"dbaPassword": "dba"}'
```

> *NOTE*: Projects and databases are identified by resource path segments `<organization>/<project>` and `<organization>/<project>/<database>`, respectively.
The example above creates the database `demo` within the project `messaging` within the organization `acme`.
Loading

0 comments on commit a6bc26d

Please sign in to comment.