Hi
You can change passwd via rabbitmqctl, the command line tool.
Also you can use the HTTP API to manage the password.
Here is my code (ruby):
def initialize(admin_host,mq_host,mq_port,mq_user,mq_pass)
@mq_host = mq_host
@mq_port = mq_port
endpoint = "http://#{admin_host}:15672"
@client = RabbitMQ::HTTP::Client.new(endpoint, :username =>
mq_user, :password => mq_pass)
end
def create_mq_dsn
vhost = "/" + SecureRandom.hex(6)
user = SecureRandom.hex(6)
pass = SecureRandom.hex(8)
@client.create_vhost(vhost)
@client.update_user(user, :tags => "autodeploy", :password => pass)
@client.update_permissions_of(vhost, user, :write => ".*",
:read => ".*", :configure => ".*")
dsn = {:host => @mq_host, :port => @mq_port, :vhost => vhost,
:user => user, :pass => pass}
return dsn
end