Skip to content

Use docker-compose to deploy a rabbitmq cluster with one click;使用docker-compose一键部署rabbitmq的集群。

License

Notifications You must be signed in to change notification settings

hsu1943/rabbitmq-cluster-docker-compose

Repository files navigation

English | 简体中文

Introduction

Deploy a RabbitMQ cluster with one click using docker-compose, including 3 nodes.

Usage

  1. Install docker and docker-compose
  2. Download this project
git clone https://github.com/hsu1943/rabbitmq-cluster-docker-compose.git
  1. Configure the environment variables in stack.env Copy a copy of stack.env.example, named stack.env
cp stack.env.example stack.env

Specific configuration:

# RabbitMQ management username and password
RABBITMQ_DEFAULT_USER=admin
RABBITMQ_DEFAULT_PASS=admin

# Shared cookie for RabbitMQ cluster
RABBITMQ_ERLANG_COOKIE=rabbit-cookie

# This directory path
RABBITMQ_PATH=.
  1. Grant execute permission to the script
chmod +x ./join-cluster.sh
  1. Start
docker-compose --env-file ./stack.env up -d

Log in to RabbitMQ management: http://localhost:15672, you can see the cluster status of 3 nodes: rabbitmq-cluster

Notice

This is just a demo for practicing the deployment of rabbitmq multi-node. Please do not use it in your production environment. In the production environment, different nodes should be deployed on different servers to ensure high availability.

Reference

License

MIT

About

Use docker-compose to deploy a rabbitmq cluster with one click;使用docker-compose一键部署rabbitmq的集群。

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages