Giter Site home page Giter Site logo

redis's Introduction

redis

This role helps to deploy a Redis master or replication server on target host. This roles sets several default values for Redis configuration which can be overrriden by the user.

Requirements

This role requires Ansible 1.4 or higher, and platform requirements are listed in the metadata file.

Role Variables

The variables that can be passed to this role and a brief description about them are as follows. See the documentation for Redis for details:

redis_bind_address                # The network address for redis to bind to 
    redis_port: 6379                  # Port for redis server
redis_syslog_enabled: "yes"       # enable_syslog
redis_databases: 16               # Set number of databases
redis_database_save_times:        # Save the DB on disk (seconds changes)
  - [900, 1]
  - [300, 10]
  - [60, 10000]
redis_dbfilename: dump.rdb        # Filename for the db
redis_db_dir: /var/lib/redis      # DB directory
redis_role: master                # The role for this redis deployment (master/slave)
redis_requirepass: false          # If password is required for querying
redis_pass: None                  # Password if require_pass is enabled
redis_max_clients: 128
redis_max_memory: 512mb
redis_maxmemory_policy: volatile-lru
redis_appendfsync: everysec       # How often to sync the filesystem

# If redis_role is "slave", set these values too
redis_master_ip: 1.1.1.1          # The master's IP
redis_master_port: 6379           # master port
redis_master_auth: None           # master auth

# This isn't a redis setting, but if set to true, then the role won't try to
# change the kernel setting (useful for containers).
redis_no_vm_overcommit: false

Examples

The following example sets up a master Redis server.

- hosts: all
  sudo: true
  roles:
  - {role: bennojoy.redis, redis_port: 11244}

The following example sets up a slave Redis server.

- hosts: all
  sudo: true
  roles:
  - {role: bennojoy.redis,
     redis_role: 'slave',
     master_ip: '192.168.2.10',
     master_auth: 'foobar'}

Dependencies

None

License

BSD

Author Information

Benno Joy

redis's People

Contributors

bennojoy avatar tgerla avatar

Watchers

 avatar  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.