GithubHelp home page GithubHelp logo

sasha-bichkov / redis-rack Goto Github PK

View Code? Open in Web Editor NEW

This project forked from redis-store/redis-rack

0.0 0.0 0.0 115 KB

Redis session store for Rack

Home Page: http://redis-store.org/redis-rack

License: MIT License

Ruby 100.00%

redis-rack's Introduction

Redis session store for Rack

redis-rack provides a Redis-backed session store for Rack.

See the main redis-store readme for general guidelines.

NOTE: This is not redis-rack-cache, the library for using Redis as a backend store for the Rack::Cache HTTP cache. All this gem does is store the Rack session within Redis.

Build Status Code Climate Gem Version

Installation

Install with Bundler by adding the following to Gemfile:

gem 'redis-rack'

Then, run:

$ bundle install

Or, you can install it manually using RubyGems:

$ gem install redis-rack

Usage

If you are using redis-store with Rails, consider using the redis-rails gem instead. For standalone usage:

# config.ru
require 'rack'
require 'rack/session/redis'

use Rack::Session::Redis

# Alternatively you can specify options to use:
use Rack::Session::Redis,
  :redis_server => "redis://redis:6379/0",
  :expires_in => 3600 # Seconds. If you are using ActiveSupport you can use 1.hour

Development

To install this gem for development purposes:

$ gem install bundler # note: you don't need to do this if you already have it installed
$ git clone git://github.com/redis-store/redis-rack.git
$ cd redis-rack
$ bundle install

Running tests

To run tests:

$ bundle exec rake

If you are on Snow Leopard you have to run the following command to build this software:

$ env ARCHFLAGS="-arch x86_64" bundle exec rake

Copyright

2009 - 2013 Luca Guidi - http://lucaguidi.com, released under the MIT license

redis-rack's People

Contributors

tubbo avatar le0pard avatar radar avatar film42 avatar jodosha avatar marcroberts avatar mstruve avatar shiro16 avatar loe avatar shaneog avatar dreyks avatar pikachuexe avatar n-rodriguez avatar mattbrictson avatar mathieujobin avatar marceloboeira avatar kuraga avatar shepmaster avatar danielmbarlow avatar tgwizard avatar kaptajnkold 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.