Skip to content

Commit

Permalink
Minor (docs): Update how-to-use-the-playground.md document (#5955)
Browse files Browse the repository at this point in the history
### What changes were proposed in this pull request?

Revert helm-chart related descriptions in
`docs/how-to-use-the-playground.md`.

### Why are the changes needed?

Make documentation match `README.md` of `apache/gravitino-playground` .

### Does this PR introduce _any_ user-facing change?

Yes, documentation is affacted.

### How was this patch tested?

Manually.
  • Loading branch information
unknowntpo authored Dec 24, 2024
1 parent 5f0dcb7 commit a58b7f8
Showing 1 changed file with 6 additions and 67 deletions.
73 changes: 6 additions & 67 deletions docs/how-to-use-the-playground.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ Depending on your network and computer, startup time may take 3-5 minutes. Once
## Prerequisites

Install Git (optional), Docker, Docker Compose.
Docker Desktop (or Orbstack) with Kubernetes enabled and helm CLI is required if you use helm-chart to deploy services.

## System Resource Requirements

Expand Down Expand Up @@ -50,82 +49,22 @@ git clone git@github.com:apache/gravitino-playground.git
cd gravitino-playground
```

#### Docker

##### Start

```
./playground.sh docker start
```

##### Check status

```shell
./playground.sh docker status
```

##### Stop playground

```shell
./playground.sh docker stop
```

#### Kubernetes

Enable Kubernetes in Docker Desktop or Orbstack.

In the project root directory, execute this command:

```
helm upgrade --install gravitino-playground ./helm-chart/ --create-namespace --namespace gravitino-playground --set projectRoot=$(pwd)
```

##### Start
#### Start

```
./playground.sh k8s start
./playground.sh start
```

##### Check status
#### Check status

```shell
./playground.sh k8s status
```

##### Port Forwarding

To access pods or services at `localhost`, you need to do these steps:

1. Log in to the Gravitino playground Trino pod using the following command:

```
TRINO_POD=$(kubectl get pods --namespace gravitino-playground -l app=trino -o jsonpath="{.items[0].metadata.name}")
kubectl exec $TRINO_POD -n gravitino-playground -it -- /bin/bash
```

2. Log in to the Gravitino playground Spark pod using the following command:

```
SPARK_POD=$(kubectl get pods --namespace gravitino-playground -l app=spark -o jsonpath="{.items[0].metadata.name}")
kubectl exec $SPARK_POD -n gravitino-playground -it -- /bin/bash
```

3. Port-forward the Gravitino service to access it at `localhost:8090`.

```
kubectl port-forward svc/gravitino -n gravitino-playground 8090:8090
```

4. Port-forward the Jupyter Notebook service to access it at `localhost:8888`.

```
kubectl port-forward svc/jupyternotebook -n gravitino-playground 8888:8888
./playground.sh status
```

##### Stop playground
#### Stop playground

```shell
./playground.sh k8s stop
./playground.sh stop
```

## Experiencing Apache Gravitino with Trino SQL
Expand Down

0 comments on commit a58b7f8

Please sign in to comment.