<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -51,6 +51,30 @@ def start_rabbitmq(type=&quot;normal&quot;)
   end
 end
 
+def configure_rabbitmq(type=&quot;normal&quot;)
+  # hack. wait for rabbit to come up.
+  sleep 2
+  
+  puts `rabbitmqctl add_vhost /nanite`
+
+  # create 'mapper' and 'nanite' users, give them each the password 'testing'
+  %w[mapper nanite].each do |agent|
+    puts `rabbitmqctl add_user #{agent} testing`
+  end
+
+  # grant the mapper user the ability to do anything with the /nanite vhost
+  # the three regex's map to config, write, read permissions respectively
+  puts `rabbitmqctl set_permissions -p /nanite mapper &quot;.*&quot; &quot;.*&quot; &quot;.*&quot;`
+
+  # grant the nanite user more limited permissions on the /nanite vhost
+  puts `rabbitmqctl set_permissions -p /nanite nanite &quot;.*&quot; &quot;.*&quot; &quot;.*&quot;`
+
+  puts `rabbitmqctl list_users`
+  puts `rabbitmqctl list_vhosts`
+  puts `rabbitmqctl list_permissions -p /nanite`
+  
+end
+
 def start_chef_solr(type=&quot;normal&quot;)
   @chef_solr_pid = nil
   cid = fork
@@ -99,6 +123,7 @@ end
 def start_dev_environment(type=&quot;normal&quot;)
   start_couchdb(type)
   start_rabbitmq(type)
+  configure_rabbitmq(type)
   start_chef_solr(type)
   start_chef_solr_indexer(type)
   start_chef_server(type)
@@ -170,9 +195,10 @@ namespace :dev do
       desc &quot;Start RabbitMQ for testing&quot;
       task :rabbitmq do
         start_rabbitmq(&quot;features&quot;)
+        configure_rabbitmq(&quot;features&quot;)
         wait_for_ctrlc
       end
-
+      
       desc &quot;Start Chef Solr for testing&quot;
       task :chef_solr do
         start_chef_solr(&quot;features&quot;)</diff>
      <filename>Rakefile</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>6ced5f1d985d47d49f39b7af10e01c295eefc2a9</id>
    </parent>
    <parent>
      <id>b16b493f2175f86c9ba32a6a4038fcb75491777b</id>
    </parent>
  </parents>
  <author>
    <name>Adam Jacob</name>
    <email>adam@opscode.com</email>
  </author>
  <url>http://github.com/opscode/chef/commit/71fbeed9f40510e3e0be9322825626a0de352a56</url>
  <id>71fbeed9f40510e3e0be9322825626a0de352a56</id>
  <committed-date>2009-10-29T08:30:28-07:00</committed-date>
  <authored-date>2009-10-29T08:30:28-07:00</authored-date>
  <message>Merge branch 'CHEF-656' of git://github.com/danielsdeleo/chef</message>
  <tree>6a5f8f83335eac2562dd7a16da0ce0eebd236bd8</tree>
  <committer>
    <name>Adam Jacob</name>
    <email>adam@opscode.com</email>
  </committer>
</commit>
