Redis version 1.01 - How to Download and Install on Mac OS X
Monday the 23rd of November, 2009

    version 1.01

      View the most recent changes for the redis port at: redis.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for redis.
      The raw portfile for redis 1.01 is located here:
      http://redis.darwinports.com/dports/databases/redis/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/redis


      # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
      The redis Portfile 58420 2009-09-28 14:52:46Z macsforever2000 macports.org $

      PortSystem 1.0

      Name: redis
      Version: 1.01
      Category: databases
      Maintainers: gmail.com:brianjlandau openmaintainer
      Homepage: http://code.google.com/p/redis/
      Platform: darwin
      Master Sites: googlecode

      Description: A persistent key-value database with built-in net interface written in ANSI-C for POSIX systems

      Long Description: Redis is a key-value database. It is similar to memcached but the dataset is not volatile, and values can be strings, exactly like in memcached, but also lists and sets with atomic operations to push/pop elements. In order to be very fast but at the same time persistent the whole dataset is taken in memory and from time to time and/or when a number of changes to the dataset are performed it is written asynchronously on disk. You may lost the last few queries that is acceptable in many applications but it is as fast as an in memory DB (beta 6 of Redis includes initial support for master-slave replication in order to solve this problem by redundancy).

      Checksums: md5 555730b90ad34839687cce0f3117cd6e sha1 416121fdec212746523b707edd3efd0458175326 rmd160 e0729d75b4ec0310047f5c649aedc1109616aa9f

      use_configure no

      build.env-append CC=${configure.cc}
      post-build {
      copy ${filespath}/redis.conf.sample.in ${workpath}/redis.conf.sample
      copy ${filespath}/redis-daemon.conf.sample.in ${workpath}/redis-daemon.conf.sample
      reinplace "s| PREFIX |${prefix}|g" ${workpath}/redis.conf.sample ${workpath}/redis-daemon.conf.sample
      }

      destroot.keepdirs ${destroot}${prefix}/var/db/redis
      destroot {
      xinstall -d ${destroot}${prefix}/var/db/redis
      xinstall -m 0755 -W ${worksrcpath} redis-benchmark redis-cli redis-server ${destroot}${prefix}/bin
      xinstall -m 0644 -W ${workpath} redis.conf.sample redis-daemon.conf.sample ${destroot}${prefix}/etc
      }

      post-activate {
      if {![file exists ${prefix}/etc/redis-daemon.conf]} {
      file copy ${prefix}/etc/redis-daemon.conf.sample ${prefix}/etc/redis-daemon.conf
      }
      if {![file exists ${prefix}/etc/redis.conf]} {
      file copy ${prefix}/etc/redis.conf.sample ${prefix}/etc/redis.conf
      }
      touch ${prefix}/var/log/redis.log
      ui_msg "
      =============================================================================
      * To start up a redis server instance use this command:
      *
      * redis-server ${prefix}/etc/redis.conf
      *
      =============================================================================
      "
      }

      startupitem.create yes
      startupitem.start "${prefix}/bin/redis-server ${prefix}/etc/redis-daemon.conf"
      startupitem.stop "echo \"SHUTDOWN\" | nc localhost 6379"

    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/redis
      % sudo port install redis
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching redis
      ---> Verifying checksum for redis
      ---> Extracting redis
      ---> Configuring redis
      ---> Building redis with target all
      ---> Staging redis into destroot
      ---> Installing redis
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using redis with these commands:
      %  man redis
      % apropos redis
      % which redis
      % locate redis

     Where to find more information:

    Darwin Ports



    Lightbox this page.