rcm

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2015 License: Apache-2.0 Imports: 18 Imported by: 0

README

RCM - Redis Cluster Manager

Build Status

RCM is a simple utility to manage Redis 3.x clusters for development purposes. Right now it supports only localhost as a host of the cluster. But probably Docker containers will be also supported.

Influenced by ccm (Cassandra Cluster Manager)

Prerequisites

  • Redis 3.x. The redis-server and redis-cli should be on the ${PATH}. Look at Installing Redis section

Installation

From source using go get

Install golang version 1.5 or later on your system first.

go get github.com/codegangsta/cli
go get github.com/fatih/color
go get github.com/goldobin/rcm

go install rcm

The RCM utility will appear in your ${GOPATH}/bin. Just do not forget to put ${GOPATH}/bin at your ${PATH} environment variable by executing export PATH=${PATH}:${GOPATH}/bin.

Usage

rcm create test1
rcm start test1
rcm distribute-slots test1

That sequence of commands will create a new Redis 3.x cluster with default parameters: 6 nodes and 1 replica per master. So the final cluster will consist of 3 master and 3 slave nodes. Also by default the cluster will be configured to not use persistence feature.

Run rcm info test1 to check if cluster is OK.

And of course you can start regular redis-cli session:

rcm cli test1

or just execute single Redis command

rcm cli test1 set x y

To get the complete list of commands and options please use rcm help

Installing Redis

Here are the short Redis installation notes

OS X:

brew install redis

Ubuntu:

sudo add-apt-repository ppa:chris-lea/redis-server
sudo apt-get update
sudo apt-get install redis-server

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL