From 4158305f80185071befe77b16085cda68ca213f3 Mon Sep 17 00:00:00 2001 From: "Bruno P. Kinoshita" Date: Fri, 2 Dec 2022 16:28:19 +0100 Subject: [PATCH] Include Docker instructions for etcd --- docs/source/guide/getting_started.rst | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/docs/source/guide/getting_started.rst b/docs/source/guide/getting_started.rst index 8b6ebc3..f7af8a3 100644 --- a/docs/source/guide/getting_started.rst +++ b/docs/source/guide/getting_started.rst @@ -37,6 +37,24 @@ Installing # start a local etcd server /tmp/etcd-download-test/etcd +Or if you prefer to use Docker: + +.. code-block:: console + + export NODE1=$(hostname -I | awk '{ print $1 }') + export REGISTRY=gcr.io/etcd-development/etcd + + docker run --rm \ + -p 2379:2379 \ + -p 2380:2380 \ + --volume=${DATA_DIR}:/etcd-data \ + --name etcd ${REGISTRY}:v3.4.14 \ + /usr/local/bin/etcd \ + --data-dir=/etcd-data --name node1 \ + --initial-advertise-peer-urls http://${NODE1}:2380 --listen-peer-urls http://0.0.0.0:2380 \ + --advertise-client-urls http://${NODE1}:2379 --listen-client-urls http://0.0.0.0:2379 \ + --initial-cluster node1=http://${NODE1}:2380 + For more advanced configuration or installation on different platforms please refer to the official documentation on the release_ page. Note that the etcd version mentioned in the script above is the latest available at the time of writing this documentation. Use any compatible version. .. _release: https://github.com/etcd-io/etcd/releases @@ -106,4 +124,4 @@ This example represents the landing event for the flight AZ203 in Fiumicino(FCO) ``payload`` is used to assign a value to the specific event notified. It is, however, optional. If not given the payload will be `None`. This last case is used when only an acknowledgement that something happened is needed. -The complete list of available commands can be found in :ref:`notification_cli` \ No newline at end of file +The complete list of available commands can be found in :ref:`notification_cli`