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

Move docker readme to docs #518

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
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
35 changes: 21 additions & 14 deletions docker/README.md → docs/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,21 @@

The Docker image of Trino Gateway is designed for the following use cases:

* Manual usage in front of Trino clusters by mounting in a configuration file
* Automated usage with an orchestration system like Kubernetes to simplify
deployment
* Manual usage in front of Trino clusters by mounting in a configuration file.
* Local development and testing with a simple `docker-compose` setup.
* Automated usage with [Helm chart for deployment of the container on
Kubernetes](installation.md#helm).

The latest version of the Trino Gateway container image is available on
DockerHub with the identifier `trinodb/trino-gateway`. Append where
`:<version>` with a version number to use a specific release, for example
`trinodb/trino-gateway:11`.

## Production setup

The healthcheck configurations in the `docker-compose` file is for suitable for development and testing purposes only.
Change the configuration for your production deployment based on the workload and your specific requirements.
The healthcheck configurations in the `docker-compose` file is for suitable
for development and testing purposes only. Change the configuration for
your production deployment based on the workload and your specific requirements.

## Build requirements

Expand All @@ -18,12 +25,12 @@ This docker build process requires the following software:
* [Docker Compose V2](https://docs.docker.com/compose/)
* jq

# Building a custom Docker image
## Building a custom Docker image

Use the following steps to build a Docker image from your local Trino Gateway
codebase

First, run the [Maven build in the project root](../docs/development.md).
First, run the [Maven build in the project root](development.md).

Then build the image for your desired processor architecture in the `docker` directory:

Expand All @@ -44,10 +51,10 @@ number and`-yyy` is the processor architecture:

```bash
$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
trino-gateway 6-SNAPSHOT-ppc64le a72b750d2745 33 seconds ago 547MB
trino-gateway 6-SNAPSHOT-arm64 bc5e8b0db63c 35 seconds ago 523MB
trino-gateway 6-SNAPSHOT-amd64 6c066fa5b0c5 36 seconds ago 518MB
REPOSITORY TAG IMAGE ID CREATED SIZE
trino-gateway 6-SNAPSHOT-ppc64le a72b750d2745 33 seconds ago 547MB
trino-gateway 6-SNAPSHOT-arm64 bc5e8b0db63c 35 seconds ago 523MB
trino-gateway 6-SNAPSHOT-amd64 6c066fa5b0c5 36 seconds ago 518MB
...
```

Expand All @@ -58,8 +65,8 @@ the `-r` option. The build script downloads all the required artifacts:
./build.sh -r 4
```

Set the environment variable `TRINO_GATEWAY_BASE_IMAGE` to use a specific base image
to build Trino Gateway image.
Set the environment variable `TRINO_GATEWAY_BASE_IMAGE` to use a specific base
image to build Trino Gateway image.

```bash
export TRINO_GATEWAY_BASE_IMAGE=<image>
Expand Down Expand Up @@ -92,7 +99,7 @@ Use a published image from Docker Hub.
export TRINO_GATEWAY_IMAGE="trinodb/trino-gateway:latest"
```

The release process publishes images for Trino Gateway 6 and newer to Docker Hub.
The release process publishes images for Trino Gateway 6 and newer to DockerHub.

Next set the image and platform:

Expand Down
13 changes: 9 additions & 4 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,15 @@

Trino Gateway is distributed as an executable JAR file. The [release
notes](release-notes.md) contain links to download specific versions.
Alternatively, you can look at the [development instructions](development.md) to
build the JAR file or use the TrinoGatewayRunner for local testing.

Every Trino Gateway release includes a [Docker container](docker.md) and a
[Helm chart](installation.md#helm) as alternative deployment methods.

Follow the [development instructions](development.md) to
build the JAR file and the Docker image instructions or use the
`TrinoGatewayRunner` class for local testing.
The [quickstart guide](quickstart.md) contains instructions for running the
application locally.
application locally.

Following are instructions for installing Trino Gateway for production
environments.
Expand Down Expand Up @@ -196,7 +201,7 @@ java -XX:MinRAMPercentage=50 -XX:MaxRAMPercentage=80 \
-jar gateway-ha.jar gateway-config.yml
```

### Helm
### Helm <a name="helm"></a>

Helm manages the deployment of Kubernetes applications by templating Kubernetes
resources with a set of Helm charts. The Trino Gateway Helm chart consists
Expand Down
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,5 +94,6 @@ nav:
- Migration to Airlift: migration-to-airlift.md
- Contribute:
- Code: development.md
- Docker: docker.md
Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe it should go in the installation section already now.. or in the follow up work as trimmed down separate page.

- Routers: routers.md
- Documentation: docs.md