s/localhost/127.0.0.1/

This commit is contained in:
Jan Lehnardt 2008-12-14 12:05:02 +01:00
parent 12c09085df
commit 7461e3fede
16 changed files with 46 additions and 46 deletions

View file

@ -2,7 +2,7 @@
require File.expand_path(File.dirname(__FILE__)) + '/../../couchrest'
cr = CouchRest.new("http://localhost:5984")
cr = CouchRest.new("http://127.0.0.1:5984")
@db = cr.database('word-count-example')
@word_memoizer = {}

View file

@ -1,6 +1,6 @@
require File.dirname(__FILE__) + '/../../couchrest'
couch = CouchRest.new("http://localhost:5984")
couch = CouchRest.new("http://127.0.0.1:5984")
db = couch.database('word-count-example')
db.delete! rescue nil
db = couch.create_db('word-count-example')
@ -62,6 +62,6 @@ end
# }
# })
# puts "The books have been stored in your CouchDB. To initiate the MapReduce process, visit http://localhost:5984/_utils/ in your browser and click 'word-count-example', then select view 'words' or 'count'. The process could take about 15 minutes on an average MacBook."
# puts "The books have been stored in your CouchDB. To initiate the MapReduce process, visit http://127.0.0.1:5984/_utils/ in your browser and click 'word-count-example', then select view 'words' or 'count'. The process could take about 15 minutes on an average MacBook."
#

View file

@ -1,6 +1,6 @@
require File.dirname(__FILE__) + '/../../couchrest'
couch = CouchRest.new("http://localhost:5984")
couch = CouchRest.new("http://127.0.0.1:5984")
db = couch.database('word-count-example')
puts "Now that we've parsed all those books into CouchDB, the queries we can run are incredibly flexible."
@ -35,5 +35,5 @@ puts "\nHere are the params for 'flight' in the da-vinci book:"
puts params.inspect
puts
puts 'The url looks like this:'
puts 'http://localhost:5984/word-count-example/_view/word_count/count?key=["flight","da-vinci"]'
puts 'http://127.0.0.1:5984/word-count-example/_view/word_count/count?key=["flight","da-vinci"]'
puts "\nTry dropping that in your browser..."