Add stop and kill docker scripts specific to arm64

This commit is contained in:
Chris Bono
2022-11-19 21:24:54 -06:00
parent d9018ea51c
commit 6638eeb439
4 changed files with 28 additions and 9 deletions

View File

@@ -15,13 +15,6 @@ To start the cluster run the following script from project root dir:
./tools/pulsar/docker/standalone/pulsar-start.sh
----
===== Mac M1 (Arm64)
If you are running on Mac M1 (ARM64) and have issues running the above image, try running the following script from project root dir:
[source,shell]
----
./tools/pulsar/docker/standalone/pulsar-start-arm64.sh
----
==== Stop
To stop the cluster run the following script from project root dir:
[source,shell]
@@ -36,4 +29,18 @@ To completely remove the cluster and volumes run the following script from proje
./tools/pulsar/docker/standalone/pulsar-destroy.sh
----
==== Mac M1 (Arm64)
If you are running on Mac M1 (ARM64) and have issues running the above commands,
instead use the scripts with the `-arm64` suffix. There is one for each command.
* `./tools/pulsar/docker/standalone/pulsar-start-arm64.sh`
* `./tools/pulsar/docker/standalone/pulsar-stop-arm64.sh`
* `./tools/pulsar/docker/standalone/pulsar-kill-arm64.sh`
Also note that the two docker volumes used in this case are also suffixed accordingly:
* `pulsardata-arm64`
* `pulsarconf-arm64`
'''
More information can be found in the official https://pulsar.apache.org/docs/next/getting-started-docker[Pulsar docs].

View File

@@ -0,0 +1,7 @@
#!/bin/bash
echo "Finding and removing Pulsar container..."
docker ps -a | grep "kezhenxu94/pulsar" | awk '{print $1}' | xargs docker rm -f
echo "Removing Pulsar volumes..."
docker volume rm pulsardata-arm64 pulsarconf-arm64
echo "All traces of Pulsar standalone removed"

View File

@@ -1,7 +1,7 @@
#!/bin/bash
docker run -it -p 6650:6650 -p 8080:8080 \
--mount source=pulsardata,target=/pulsar/data \
--mount source=pulsarconf,target=/pulsar/conf \
--mount source=pulsardata-arm64,target=/pulsar/data \
--mount source=pulsarconf-arm64,target=/pulsar/conf \
kezhenxu94/pulsar:latest \
bin/pulsar standalone

View File

@@ -0,0 +1,5 @@
#!/bin/bash
echo "Finding and stopping Pulsar container..."
docker ps -a | grep "kezhenxu94/pulsar" | awk '{print $1}' | xargs docker stop
echo "Container stopped - you can run 'pulsar-start-arm64.sh' when/if you want to restart it"