def deploy!(archive, env)
            archive.upload(Beanstalk.api)
            
            if env.status.empty?
                puts "Creating stack '#{@stack}' for #{archive.app_name}-#{archive.version}..."
                env.create!(archive, @stack, @cnames, @config)
                env.wait_until_status_is_not "Launching"
            else
                puts "Deploying #{archive.version} to #{env.name}..."
                env.deploy!(archive, @config)
                env.wait_until_status_is_not "Updating"
            end
            
            env.wait_until_healthy
            puts "Done. Visit http://#{env.url} in your browser."
            DeploymentInfo.new env, archive
        end
def deploy!(archive, env)
            archive.upload(Beanstalk.api)
            
            if env.status.empty?
                puts "Creating stack '#{@stack}' for #{archive.app_name}-#{archive.version}..."
                env.create!(archive, @stack, @cnames, @config)
                env.wait_until_status_is_not "Launching"
            else
                puts "Deploying #{archive.version} to #{env.name}..."
                env.deploy!(archive, @config)
                env.wait_until_status_is_not "Updating"
            end
            
            env.wait_until_healthy
            puts "Done. Visit http://#{env.url} in your browser."
            DeploymentInfo.new env, archive
        end
config is an array of hashes:
   :namespace, :option_name, :value
 Deploy an archive to an environment.
 If the environment doesn't exist, it will be created.