Sha256: 02611853794cae95efd6054721d8761225e70f3aed479ede81def9748a5b2c30

Contents?: true

Size: 694 Bytes

Versions: 6

Compression:

Stored size: 694 Bytes

Contents

#!/usr/bin/env ruby

$LOAD_PATH.unshift File.expand_path(File.dirname(__FILE__) + '/../lib')
begin
  require 'vegas'
rescue LoadError
  require 'rubygems'
  require 'vegas'
end

require 'rewritten/server'

Vegas::Runner.new(Rewritten::Server, 'rewritten-web', {
                    before_run: lambda {|v|
                      path = (ENV['RESQUECONFIG'] || v.args.first)
                      load path.to_s.strip if path
                    }
                  }) do |runner, opts, _app|
  opts.on('-N NAMESPACE', '--namespace NAMESPACE', 'set the Redis namespace') {|namespace|
    runner.logger.info "Using Redis namespace '#{namespace}'"
    Rewritten.redis.namespace = namespace
  }
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
rewritten-0.16.5 bin/rewritten-web.rb
rewritten-0.16.4 bin/rewritten-web.rb
rewritten-0.16.3 bin/rewritten-web.rb
rewritten-0.16.2 bin/rewritten-web.rb
rewritten-0.16.1 bin/rewritten-web.rb
rewritten-0.16.0 bin/rewritten-web.rb