Skip to content

Instantly share code, notes, and snippets.

@raphaelmerx
Created April 20, 2015 23:27
Show Gist options
  • Save raphaelmerx/b3b4f1b5e569cd4f4f5c to your computer and use it in GitHub Desktop.
Save raphaelmerx/b3b4f1b5e569cd4f4f5c to your computer and use it in GitHub Desktop.
Delete scout server
# Script using scout api to delete the provided server
if ARGV.length < 4
puts "Please specify hostname of scout server you wish to remove"
puts "USAGE: delete_scout_entry.rb <account name> <username> <password> <server hostname>"
exit(0)
end
require 'scout_api'
scout = Scout::Account.new(ARGV[0], ARGV[1], ARGV[2])
server = Scout::Server.first(:name => ARGV[3])
server_id = server.id
Scout::Server.delete(server_id)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment