diff --git a/presto-docs/requirements.txt b/presto-docs/requirements.txt index f5ee358d6d1e4..3203e335054ca 100644 --- a/presto-docs/requirements.txt +++ b/presto-docs/requirements.txt @@ -1,3 +1,2 @@ sphinx==8.2.1 sphinx-immaterial==0.13.0 -sphinx-copybutton==0.5.2 diff --git a/presto-docs/src/main/sphinx/conf.py b/presto-docs/src/main/sphinx/conf.py index ea71636098d47..0ba35583db294 100644 --- a/presto-docs/src/main/sphinx/conf.py +++ b/presto-docs/src/main/sphinx/conf.py @@ -64,7 +64,7 @@ def get_version(): needs_sphinx = '8.2.1' extensions = [ - 'sphinx_immaterial', 'sphinx_copybutton', 'download', 'issue', 'pr', 'sphinx.ext.autosectionlabel' + 'sphinx_immaterial', 'download', 'issue', 'pr', 'sphinx.ext.autosectionlabel' ] copyright = 'The Presto Foundation. All rights reserved. Presto is a registered trademark of LF Projects, LLC' @@ -106,13 +106,8 @@ def get_version(): html_logo = 'images/logo.png' html_favicon = 'images/favicon.ico' -# doesn't seem to do anything -# html_baseurl = 'overview.html' - html_static_path = ['.'] -templates_path = ['_templates'] - # Set the primary domain to js because if left as the default python # the theme errors when functions aren't available in a python module primary_domain = 'js' diff --git a/presto-docs/src/main/sphinx/installation.rst b/presto-docs/src/main/sphinx/installation.rst index c67f47b4324c4..daef03acb5288 100644 --- a/presto-docs/src/main/sphinx/installation.rst +++ b/presto-docs/src/main/sphinx/installation.rst @@ -6,6 +6,6 @@ Installation :maxdepth: 1 installation/deployment - installation/deploy-docker installation/deploy-brew + installation/deploy-docker installation/deploy-helm diff --git a/presto-docs/src/main/sphinx/installation/deploy-brew.rst b/presto-docs/src/main/sphinx/installation/deploy-brew.rst index bed202f4bd4d0..3f7b768535753 100644 --- a/presto-docs/src/main/sphinx/installation/deploy-brew.rst +++ b/presto-docs/src/main/sphinx/installation/deploy-brew.rst @@ -1,6 +1,6 @@ -============================ -Deploy Presto using Homebrew -============================ +=========================== +Deploy Presto with Homebrew +=========================== This guide explains how to install and get started with Presto on macOS, Linux or WSL2 using the Homebrew package manager. diff --git a/presto-docs/src/main/sphinx/installation/deploy-docker.rst b/presto-docs/src/main/sphinx/installation/deploy-docker.rst index b6a824916c40e..d1a7882c7fced 100644 --- a/presto-docs/src/main/sphinx/installation/deploy-docker.rst +++ b/presto-docs/src/main/sphinx/installation/deploy-docker.rst @@ -1,60 +1,66 @@ -================================= -Deploy Presto From a Docker Image -================================= +========================= +Deploy Presto with Docker +========================= + +This guide explains how to install and get started with Presto using Docker. + +.. note:: + + These steps were developed and tested on Mac OS X, on both Intel and Apple Silicon chips. -These steps were developed and tested on Mac OS X, on both Intel and Apple Silicon chips. +Prepare the container environment +================================= -Follow these steps to: +If Docker is already installed, skip to step 4 to verify the setup. +Otherwise, follow the instructions below to install Docker and Colima using Homebrew or choose an alternative method. -- install the command line tools for brew, docker, and `Colima `_ -- verify your Docker setup -- pull the Docker image of the Presto server -- start your local Presto server +1. Install `Homebrew `_ if it is not already present on the system. -Installing brew, Docker, and Colima -=================================== +2. Install the Docker command line and `Colima `_ tools via the following command: -This task shows how to install brew, then to use brew to install Docker and Colima. + .. code-block:: shell -Note: If you have Docker installed you can skip steps 1-3, but you should -verify your Docker setup by running the command in step 4. + brew install docker colima -1. If you do not have brew installed, run the following command: +3. Run the following command to start Colima with defaults: - ``/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"`` + .. code-block:: shell -2. To install the Docker command line and `Colima `_ tools, run the following command: + colima start - ``brew install docker colima`` + .. note:: -3. Run the following command: + The default VM created by Colima uses 2 CPUs, 2GiB memory and 100GiB storage. To customize the VM resources, + see the Colima README for `Customizing the VM `_. - ``colima start`` +4. Verify the local setup by running the following command: - *Note*: The default VM created by Colima uses 2 CPUs, 2GB memory and 60GB storage. To customize the VM resources, - see the Colima README for `Customizing the VM `_. + .. code-block:: shell -4. To verify your local setup, run the following command: + docker run hello-world - ``docker run hello-world`` + The following output confirms a successful installation. - If you see a response similar to the following, you are ready. + .. code-block:: shell + :class: no-copy - ``Hello from Docker!`` - ``This message shows that your installation appears to be working correctly.`` + Hello from Docker! + This message shows that your installation appears to be working correctly. Installing and Running the Presto Docker container ================================================== -1. Download the latest non-edge Presto container from `Presto on DockerHub `_. Run the following command: +1. Download the latest non-edge Presto container from `Presto on DockerHub `_: + + .. code-block:: shell - ``docker pull prestodb/presto:latest`` + docker pull prestodb/presto:latest Downloading the container may take a few minutes. When the download completes, go on to the next step. -2. On your local system, create a file named ``config.properties`` containing the following text: +2. On the local system, create a file named ``config.properties`` containing the following text: - .. code-block:: none + .. code-block:: properties coordinator=true node-scheduler.include-coordinator=true @@ -62,7 +68,7 @@ Installing and Running the Presto Docker container discovery-server.enabled=true discovery.uri=http://localhost:8080 -3. On your local system, create a file named ``jvm.config`` containing the following text: +3. On the local system, create a file named ``jvm.config`` containing the following text: .. code-block:: none @@ -78,20 +84,26 @@ Installing and Running the Presto Docker container 4. To start the Presto server in the Docker container, run the command: - ``docker run -p 8080:8080 -it -v ./config.properties:/opt/presto-server/etc/config.properties -v ./jvm.config:/opt/presto-server/etc/jvm.config --name presto prestodb/presto:latest`` + .. code-block:: shell + + docker run -p 8080:8080 -it -v ./config.properties:/opt/presto-server/etc/config.properties -v ./jvm.config:/opt/presto-server/etc/jvm.config --name presto prestodb/presto:latest This command assigns the name ``presto`` for the newly-created container that uses the downloaded image ``prestodb/presto:latest``. - The Presto server logs startup information in the terminal window. Once you see a response similar to the following, the Presto server is running in the Docker container. + The Presto server logs startup information in the terminal window. The following output confirms the Presto server is running in the Docker container. + + .. code-block:: shell + :class: no-copy - ``======== SERVER STARTED ========`` + ======== SERVER STARTED ======== Removing the Presto Docker container ==================================== -To remove the Presto Docker container, run the following two commands: +To stop and remove the Presto Docker container, run the following commands: -``docker stop presto`` +.. code-block:: shell -``docker rm presto`` + docker stop presto + docker rm presto These commands return the name of the container ``presto`` when they succeed. diff --git a/presto-docs/src/main/sphinx/installation/deploy-helm.rst b/presto-docs/src/main/sphinx/installation/deploy-helm.rst index 5fe7d0225e8c2..1fefb226fd142 100644 --- a/presto-docs/src/main/sphinx/installation/deploy-helm.rst +++ b/presto-docs/src/main/sphinx/installation/deploy-helm.rst @@ -1,5 +1,5 @@ -=============================== -Deploy Presto Using Helm Charts -=============================== +======================= +Deploy Presto with Helm +======================= -To deploy Presto using Helm charts, see the `Presto Helm Charts README `_. \ No newline at end of file +To deploy Presto using Helm, see the `Presto Helm Charts README `_.