Coder Social home page Coder Social logo

sohailalam2 / redskull Goto Github PK

View Code? Open in Web Editor NEW

This project forked from therealbill/redskull

0.0 2.0 0.0 4.8 MB

Red Skull is a Sentinel management system

License: Apache License 2.0

Makefile 0.03% Go 4.22% PHP 0.08% CSS 12.84% HTML 41.86% JavaScript 40.89% Shell 0.09%

redskull's Introduction

What Is Red Skull?

Red Skull is a Sentinel management system. It is designed to run on each sentinel node you operate and provide a single, yet distributed, mechanism for managing Sentinel as well as interacting with it.

Overview

Written in Go, Red Skull runs on each Sentinel and bootstraps itself from that Sentinel's configuration file. It will then interrogate any known-sentinel directives as well as run `setinel sentinels for each pod found in the config file. It essentially crawls through your Sentinel constellation and discovers all sentinels, masters, and slaves.

It then provides a decent web interface for viewing and managing your sentinels, and by proxy the Redis instances under management. It introduces some new concepts/terminology and these will be explained in the documentation tree.

In addition to the front end Red Skull provides an HTTP/JSON REST-like interface for interacting with programmaticly. Adding the redis Sentinel API as another interface is planned as well.

Better Documentation

You can find better guides to redskull at Redskull.IO.

Current State

The initial import is of the base working code. It still likely has many bugs as it is the result of only ~3-4 total weeks of effort and there are still much error handling to be written. That said, the base functionality is there and working.

The initial effort after import will be a focus on documenting Red Skull. Primarily how to install and use it; its design, goals, and contribution guidelines; and the direction and needs for it's advancement.

Can you use it for "production use". Yes. Will it destroy your setup? Not likely. Some of the truly destructive things are disabled, even. Yup, a bit paranoid sometimes. :)

Most of the things you can do in the web UI are also available in the JSON+HTTP API but there may be some new functionality I've not yet added to the API.

Requirements

As RS is written in Go you need Go installed. Once cloned, you will need to install a few dependencies:

  • go get "github.com/kelseyhightower/envconfig"
  • go get "github.com/therealbill/airbrake-go"
  • go get "github.com/therealbill/libredis/client"
  • go get "github.com/therealbill/libredis/info"
  • go get "github.com/zenazn/goji"

Then you can execute go build in the root of the repo

Installation

Assuming you have Git and Go (sounds like a techie oriented convenience store - "the Git and Go") installed, installing Red Skull is fairly simple. The dependencies are listed in the Godeps file. If you have/use gpm (a Go dependency manager), you can do the following:

go get github.com/therealbill/redskull 
cd $GOPATH/src/github.com/therealbill/redskull 
gpm install 
go build
./redskull

And, assuming you have a sentinel config at /etc/redis/sentinel.conf it will be up and running on localhost port 8000.

If you don't use gpm the following should work reasonably well:

go get github.com/therealbill/redskull 
cd $GOPATH/src/github.com/therealbill/redskull 
for x in `cat Godeps`; do
go get $x 
go build
./redskull

There is also a Makefile now. Targets are "redskull" "dist-tar", and "docker-image".

Running Red Skull

Red Skull expects to find the sentinel config file in /etc/redis/sentinel.conf. You can, however, alter this by the setting the environment variable REDSKULL_SENTINELCONFIGFILE.

RS currently expects the html directory to be in the same location as the binary. For example you can do create a directory named /usr/redskull, place the redskull binary in it, and copy the html directory to it, then launch ./redskull and it should work. You'll find it running on port 8000, Alternatively you can configure the location of the HTML directory via REDSKULL_TEMPLATEDIRECTORY,

Calling the API

Err, for now look in main.go to see the URLs and whether you need to do a GET, PUT, DEL, or POST for that call. Most of it is pretty simple. I've just not documented it yet as I prefer to do it once things stabilize. If you want to help get that jumpstarted pull requests are welcome. :)

Can you use it for "production use"? Yes. Will it destroy your setup? Not likely. It only executes read-only commands unless you click the button to make a change.

redskull's People

Contributors

therealbill avatar xethron avatar badboy avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.