You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/09/27 11:44:10 UTC
[GitHub] [pulsar] liangyepianzhou opened a new pull request, #17853: [fxi][doc] Rewrite the steps of docker-deploy
liangyepianzhou opened a new pull request, #17853:
URL: https://github.com/apache/pulsar/pull/17853
Master https://github.com/apache/pulsar/issues/17774
### Motivation
The old implementation is incomplete.
### Modification
Rewrite it.
### Documentation
- [x] `doc`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274073381
@Anonymitaet Thanks for the reminder again.
Here is a very interesting point.
When you told me last time that you needed to attach a screenshot of the preview, I understood the preview from the perspective of a technician, so I attached a screenshot of the successful deployment of the cluster.
But in fact, you meant to attach a preview screenshot of the document/website.
I think this question may also confuse other newcomers.
To solve this problem, I have a small suggestion about the description template.
```
### Documentation
<!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
- [ ] `doc` <!-- Your PR contains doc changes -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
- [ ] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->
Document in the google doc: <! -- ENTER URL HERE -->
<! If your PR contains a lot of doc changes -->
Website local preview <! ATTACH PREVIEW SCREENSHOTS>
<! If your PR contains doc changes, you need to run `sh start.sh` at `$pwd`/site2/website and attach the preview screenshots at here. -->
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou merged pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou merged PR #17853:
URL: https://github.com/apache/pulsar/pull/17853
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984162217
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
Review Comment:
```suggestion
## Start ZooKeeper and initialize cluster metadata
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
Review Comment:
```suggestion
Start the ZooKeeper service in the Docker container by running the following commands.
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
Review Comment:
```suggestion
1. Open the ZooKeeper container.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on a diff in pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r991805653
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
Review Comment:
I made a suggestion to modify the description template. I think we should process this to ensure that rather than hope that reviewers and authors are always right.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Anonymitaet commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Anonymitaet commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1260252596
@Demogorgon314
could you please review this PR from a technical perspective? Thank you!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r981866128
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,127 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. modify the broker.conf and bookkeeper.conf
+4. create a network, and make the container connects to it.
+5. start the zookeeper, and then init the cluster metadata
+6. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -it --privileged=true -u=root --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
Review Comment:
Why do we use `-it` to start an interactive tty here? We should start the container in the background by using the `-d` options.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984444172
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
+```
+bin/pulsar-daemon start zookeeper
+```
+3. init the cluster metadata
+```
+ bin/pulsar initialize-cluster-metadata \
+ --cluster cluster-a \
+ --zookeeper zookeeper:2181 \
+ --configuration-store zookeeper:2181 \
+ --web-service-url http://broker:8080 \
+ --broker-service-url pulsar://broker:6650 \
+```
+## start the broker and bookie service
+Start the broker and bookie service in the docker container by the following commands:
+### Start broker service
+1. Open the broker container
+```
+docker exec -it broker bash
+```
+2. Start the broker service
+```
+bin/pulsar-daemon start broker
+```
+
+### Start bookie service
+1. Open the bookie container
+```
+docker exec -it bookie bash
+```
+2. Start the bookie service
+```
+bin/pulsar-daemon start bookie
Review Comment:
Can you add an example of using a local pulsar client to produce and consume by connecting to the docker pulsar service?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263124086
@Demogorgon314 @momo-jun The docker-compose.yaml has been completed at the [google doc](https://docs.google.com/document/d/1MS9KDvmdOBMK58kZtHlqOUl5z7oNBjPNXayP7_uu_D4/edit), you can review it when you have time.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on a diff in pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r991805653
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
Review Comment:
I made a suggestion to modify the description template. I think we should guarantee correctness from the process and institutional should be, rather than expecting reviewers and authors always to be correct.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984161373
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
Review Comment:
```suggestion
To deploy a Pulsar cluster on Docker, you need to complete the following steps:
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263675560
> After trying the `docker-compose.yaml` . I find out the health check implement is wrong.
>
> For more details, please refer to https://gist.github.com/Demogorgon314/c0d397a21c5a05b40235bb43272a4a88
I write the health check according to this PR https://github.com/apache/skywalking-rust/pull/9/files#diff-29d8d8c569345f7e4339e3bab5342fa39d73d2293303d372c0f00cd04ad242eb
And the cluster can be start up correctly, right?
There may be some flaws in the health check here, but it does not affect the correct deployment of the pulsar cluster.
And I think the correct way to solve the problem should be to comment on the original google doc instead of copying it elsewhere for modification.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Anonymitaet commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Anonymitaet commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274299184
> @Anonymitaet Thanks for the reminder again. Here is a very interesting point. When you told me last time that I needed to attach a screenshot of the preview, I understood the preview from the perspective of a technician, so I attached a screenshot of the successful deployment of the cluster. But in fact, you meant to attach a preview screenshot of the document/website. I think this question may also confuse other newcomers. To solve this problem, I have a small suggestion about the description template.
>
> ```
> ### Documentation
>
> <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
>
> - [ ] `doc` <!-- Your PR contains doc changes -->
> - [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
> - [ ] `doc-not-needed` <!-- Your PR changes do not impact docs -->
> - [ ] `doc-complete` <!-- Docs have been already added -->
>
>
> Document in the google doc: <!-- ENTER URL HERE -->
> <!-- If your PR contains a lot of doc changes -->
>
> Website local preview <!-- ATTACH PREVIEW SCREENSHOTS -->
> <!-- If your PR contains doc changes, you need to run `sh start.sh` at `$pwd`/site2/website and attach the preview screenshots here. -->
> ```
Hi @liangyepianzhou thanks for your feedback!
1. Local preview screenshots
When talking about "local preview screenshots", it refers to the "local preview screenshots" in https://github.com/apache/pulsar/pull/14314#issue-1139667381 rather than "preview screenshots" in https://github.com/apache/pulsar/pull/17853#issue-1387615390
2. Google docs
Google docs is not a must for every doc PR. But if you working on a large doc set, to accelerate the review process and collaborate efficiently, it is recommended to follow the steps below:
(1) Draft in a google doc
(2) Request technical reviews and incorporate comments
(3) Request technical writing reviews and incorporate comments
(4) Send a PR, attach the google doc link (to show your writings have been reviewed by others) and local preview screenshots (to show everything goes fine)
In this way, you can get PRs merged faster and more smoothly.
cc @DaveDuggins @momo-jun @D-2-Ed
๐น๐น๐น
Besides, I've added a simple reminder to the PR template, https://github.com/apache/pulsar/pull/17999, PTAL @liangyepianzhou @tisonkun
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984162328
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
Review Comment:
```suggestion
2. Start the ZooKeeper service.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1260287963
I also have another idea about docker deployment, we can add a `docker-compose` to simplify the docker deployment.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1264174816
Actually, "latest" is just a label, just like other versions. When you pull the โlatestโ image to local, the image will never update.
You need to delete the โlatestโ image and re-pull it again.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984161937
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
Review Comment:
```suggestion
* Create a ZooKeeper container
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
Review Comment:
Does it make sense to add a language highlight like `bash` after ```? If yes, it applies to all the following commands.
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
Review Comment:
```suggestion
* Create a broker container
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
Review Comment:
```suggestion
* Create a bookie container
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263696635
@Demogorgon314 Thanks for your support of my work. After verifying the changes for the health check and other optimizations, I will accept them in the google doc. And then if you have other suggestions, feel free to leave comments in the google doc.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] tisonkun commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
tisonkun commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274351703
> adding a CI task
We cannot now, although XD.
The build scripts and relative paths are quite brittle to modularize and automatize: https://github.com/apache/pulsar-site/pull/246#issuecomment-1274090596
It still needs some efforts to refactor the build process.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Anonymitaet commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Anonymitaet commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1273993662
@liangyepianzhou Thanks for your contribution!
In this PR, the correct local preview screenshots are not attached in the PR description.
1. Can you preview the changes locally and attach the screenshots? So that we can verify everything goes fine.
2. After that, we can merge the doc PR. Please do not merge a doc PR without preview screenshots in the PR description.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984162394
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
+```
+bin/pulsar-daemon start zookeeper
+```
+3. init the cluster metadata
Review Comment:
```suggestion
3. Initialize the cluster metadata.
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
+```
+bin/pulsar-daemon start zookeeper
+```
+3. init the cluster metadata
+```
+ bin/pulsar initialize-cluster-metadata \
+ --cluster cluster-a \
+ --zookeeper zookeeper:2181 \
+ --configuration-store zookeeper:2181 \
+ --web-service-url http://broker:8080 \
+ --broker-service-url pulsar://broker:6650 \
+```
+## start the broker and bookie service
Review Comment:
```suggestion
## Start broker and bookie services
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
+```
+bin/pulsar-daemon start zookeeper
+```
+3. init the cluster metadata
+```
+ bin/pulsar initialize-cluster-metadata \
+ --cluster cluster-a \
+ --zookeeper zookeeper:2181 \
+ --configuration-store zookeeper:2181 \
+ --web-service-url http://broker:8080 \
+ --broker-service-url pulsar://broker:6650 \
+```
+## start the broker and bookie service
+Start the broker and bookie service in the docker container by the following commands:
Review Comment:
```suggestion
Start the broker and bookie services in the Docker container by running the following commands.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984161662
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
Review Comment:
```suggestion
4. Start ZooKeeper and initialize cluster metadata.
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
Review Comment:
```suggestion
3. Create a network connected to the containers.
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
Review Comment:
```suggestion
2. Create ZooKeeper, bookie, and broker containers.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984466128
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
## Prepare
+To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on Docker Hub, and pull a Pulsar image for the broker. You can also pull only one Pulsar image and create three containers with this image. This tutorial takes the second option as an example.
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
-
-### Pull a Pulsar image
-You can pull a Pulsar image from [Docker Hub](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) with the following command.
+## Pull a Pulsar image
+You can pull a Pulsar image from Docker Hub with the following command. If you want to use some connectors, you can use apachepulsar/pulsar-all there.
-```shell
+```java
docker pull apachepulsar/pulsar-all:latest
```
+## Create containers
+* Create zookeeper container
+
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
+```
-### Create three containers
-Create containers for ZooKeeper, BookKeeper and broker. In this example, they are named as `zookeeper`, `bookkeeper` and `broker` respectively. You can name them as you want with the `--name` flag. By default, the container names are created randomly.
+* Create broker container
-```shell
-docker run -it --name bookkeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name zookeeper apachepulsar/pulsar-all:latest /bin/bash
-docker run -it --name broker apachepulsar/pulsar-all:latest /bin/bash
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_metadataStoreUrl=zk:zookeeper:2181 -e PULSAR_PREFIX_cluster-name=cluster-a -e PULSAR_PREFIX_managedLedgerDefaultEnsembleSize=1 -e PULSAR_PREFIX_managedLedgerDefaultWriteQuorum=1 -e PULSAR_PREFIX_managedLedgerDefaultAckQuorum=1 --name broker apachepulsar/pulsar-all:latest /bin/bash
```
-### Create a network
-To deploy a Pulsar cluster on Docker, you need to create a `network` and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network `pulsar`:
+* Create bookie container
-```shell
+```
+docker run -d --privileged=true -u=root -e PULSAR_PREFIX_zkServers=zookeeper:2181 -e PULSAR_PREFIX_metadataServiceUri=metadata-store:zk:zookeeper:2181 --name bookie apachepulsar/pulsar-all:latest /bin/bash
+```
+## Create the network
+To deploy a Pulsar cluster on Docker, you need to create a network and connect the containers of ZooKeeper, BookKeeper and broker to this network. The following command creates the network pulsar:
+```
docker network create pulsar
```
+Connect the containers of ZooKeeper, BookKeeper and broker to the pulsar network with the following commands.
-### Connect containers to network
-Connect the containers of ZooKeeper, BookKeeper and broker to the `pulsar` network with the following commands.
-
-```shell
+```
docker network connect pulsar zookeeper
+```
+```
docker network connect pulsar bookkeeper
+```
+```
docker network connect pulsar broker
+```
+## start the zookeeper, and init the cluster metadata
+Start the zookeeper service in the docker container by the following commands:
+1. Open the zookeeper container
+```
+docker exec -it zookeeper bash
+```
+2. Start the zookeeper service
+```
+bin/pulsar-daemon start zookeeper
+```
+3. init the cluster metadata
+```
+ bin/pulsar initialize-cluster-metadata \
+ --cluster cluster-a \
+ --zookeeper zookeeper:2181 \
+ --configuration-store zookeeper:2181 \
+ --web-service-url http://broker:8080 \
+ --broker-service-url pulsar://broker:6650 \
+```
+## start the broker and bookie service
+Start the broker and bookie service in the docker container by the following commands:
+### Start broker service
+1. Open the broker container
+```
+docker exec -it broker bash
+```
+2. Start the broker service
+```
+bin/pulsar-daemon start broker
+```
+
+### Start bookie service
+1. Open the bookie container
+```
+docker exec -it bookie bash
+```
+2. Start the bookie service
+```
+bin/pulsar-daemon start bookie
Review Comment:
This is a deployment instead of ` get start`, right?
But I think we can export the ports.
And you can comment on the google doc.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263747133
There are some exceptions when using the [docker-compose.yaml ](https://gist.github.com/Demogorgon314/c0d397a21c5a05b40235bb43272a4a88)to start up the cluster. The exception happens after 9 minutes, so I only adopt the health check for the zookeeper in the google doc. And I'll add it when the problem is solved.
<img width="1150" alt="image" src="https://user-images.githubusercontent.com/55571188/193309306-77961405-5424-49bf-98ab-1db164bb87b3.png">
<img width="1419" alt="image" src="https://user-images.githubusercontent.com/55571188/193309221-5762d631-4110-4e76-ad61-bff2284bf6b0.png">
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] xiaogang-sn commented on a diff in pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
xiaogang-sn commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r992131738
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
Review Comment:
Shouldn't there be a sanity check CI job for any documentation change in the repo if full pipeline is too expensive?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274087674
@tisonkun When the PR contains more documents, we hope this document can be placed in Google Docs or other documents first so that it can be reviewed more quickly.
But where to put it is a problem. If you put it in the comment, it will not be easy to find when there are many comments.
So it would be helpful to have a suitable place to put documentation links in the description.
Both CI tasks and preview screenshots can solve this problem very well, but there must be one. And use the preview screenshot, then it should be part of the description, not a tacit agreement of people who often do this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274342531
> And a clean solution is to sort out the site build process and add a CI task to pre-commit site changes.
@tisonkun I Agree, adding a CI task to give a site changes preview is a better solution.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] tisonkun commented on a diff in pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
tisonkun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r991803704
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
Review Comment:
This is an obvious syntax error that fails the site build.
Please be careful when reviewing...Always previewing your changes helps.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263775139
@liangyepianzhou Thanks for reporting the issue. Maybe you should pull the latest version of Pulsar image. See https://github.com/apache/pulsar/pull/12353 already removed the check.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Demogorgon314 commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
Demogorgon314 commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263583612
After trying the `docker-compose.yaml` . I find out the health check implement is wrong.
For more details, please refer to https://gist.github.com/Demogorgon314/c0d397a21c5a05b40235bb43272a4a88
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r984161814
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
Review Comment:
```suggestion
1. Pull the Pulsar Docker image.
```
##########
site2/docs/deploy-docker.md:
##########
@@ -3,50 +3,97 @@ id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
---
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
+## Deploy a cluster on Docker
+To deploy a Pulsar cluster on Docker, you need to complete the next steps:
+1. pull the pulsar docker image
+2. create the zookeeper, bookie, broker container by the image
+3. create a network, and make the container connects to it.
+4. start the zookeeper, and then init the cluster metadata
+5. start the broker and bookie
Review Comment:
```suggestion
5. Start brokers and bookies.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1263779719
> @liangyepianzhou Thanks for reporting the issue. Maybe you should pull the latest version of Pulsar image. See #12353 already removed the check.
The image of the docker is configured in the docker-compose.yaml, It is the latest, right?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] tisonkun commented on a diff in pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
tisonkun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r991807135
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
Review Comment:
No. The community runs by meritocracy so reviewers should be careful. It's not irreversible to make mistake like this and I'm not blaming you here. But send a notice that you should follow the process. Adding more description hints you to follow the process also but I believe few people really read the whole description.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] tisonkun commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
tisonkun commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274075940
@liangyepianzhou I don't think it helps so much. Longer and longer templates attract little careness to read, except we add some clear failure.
Basically, the doc reviewers should be careful. And a clean solution is to sort out the site build process and add a CI task to pre-commit site changes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] liangyepianzhou commented on pull request #17853: [fix][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
liangyepianzhou commented on PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#issuecomment-1274089239
>I don't think it helps so much. Longer and longer templates attract little careness to read, except we add some clear failure.
If this PR is about documentation, he only cares about the description in the document section. If it's not about the documentation, maybe he'll just choose `doc-not-needed` in the documentation section and don't care about anything else. So I think adding these four lines of description will help a lot for those who need him, who are just starting work for documentation, without burdening others who don't work for documentation.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] momo-jun commented on a diff in pull request #17853: [fxi][doc] Rewrite the steps of docker-deploy
Posted by GitBox <gi...@apache.org>.
momo-jun commented on code in PR #17853:
URL: https://github.com/apache/pulsar/pull/17853#discussion_r991184207
##########
site2/docs/deploy-docker.md:
##########
@@ -2,51 +2,163 @@
id: deploy-docker
title: Deploy a cluster on Docker
sidebar_label: "Docker"
----
-
-To deploy a Pulsar cluster on Docker, complete the following steps:
-1. Deploy a ZooKeeper cluster (optional)
-2. Initialize cluster metadata
-3. Deploy a BookKeeper cluster
-4. Deploy one or more Pulsar brokers
-
-## Prepare
-
-To run Pulsar on Docker, you need to create a container for each Pulsar component: ZooKeeper, BookKeeper and broker. You can pull the images of ZooKeeper and BookKeeper separately on [Docker Hub](https://hub.docker.com/), and pull a [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) for the broker. You can also pull only one [Pulsar image](https://hub.docker.com/r/apachepulsar/pulsar-all/tags) and create three containers with this image. This tutorial takes the second option as an example.
+โ
+You can use two kinds of methods to deploy a Pulsar cluster on Docker.
+The first uses Docker commands, while the second uses a `docker-compose.yaml` file.
+## Deploy a cluster using Docker commands
+To deploy a Pulsar cluster on Docker, you need to complete the following steps:
+Pull a Pulsar Docker image.
Review Comment:
```suggestion
1. Pull a Pulsar Docker image.
```
The three steps missed the numbering. Can you pls add them all?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org