Sha256: b9f340f7cc22da5f97148ffeac4f81354c3b6292388c8ec9e91be12f7ba586b0
Contents?: true
Size: 1.66 KB
Versions: 5
Compression:
Stored size: 1.66 KB
Contents
= rest_connection Quick Start == Install ==== Installing with rubygems "gem install rest_connection" ==== Installing from source "git clone http://github.com/rightscale/rest_connection.git" "gem install jeweler rspec" "rake check_dependencies" <- Install any gems listed. "rake install" == Configuration You must setup ~/.rest_connection/rest_api_config.yaml or /etc/rest_connection/rest_api_config.yaml Copy the example from GEMHOME/rest_connection/config/rest_api_config.yaml.sample and fill in your connection info. Pro Tip: to find a GEMHOME, use gemedit "gem install gemedit" "gem edit rest_connection" == Usage: some IRB samples for the RightScale API module $ irb ruby> require 'rubygems'; require 'rest_connection' === Lookup and run a RightScript first_fe = Server.find(:first) { |s| s.nickname =~ /Front End/ } st = ServerTemplate.find(first_fe.server_template_href) connect_script = st.executables.detect { |ex| ex.name =~ /LB [app|mongrels]+ to HA proxy connect/i } state = first_fe.run_executable(connect_script) state.wait_for_completed === Stop a Deployment deployment = Deployment.find(opts[:id]) my_servers = deployment.servers my_servers.each { |s| s.stop } my_servers.each { |s| s.wait_for_state("stopped") } === Activate an Ec2ServerArray / Display instances IPs my_array = Ec2ServerArray.find(opts[:href]) my_array.active = true my_array.save puts my_array.instances.map { |i| i['ip-address'] } === To cut a new gem and push to rubygems.org Edit VERSION and bump the number rake gemspec rake install visit www.rubygems.org gem push pkg/rest_connection-0.0.0.gem (use your new version number in this command)
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
rest_connection-1.0.2 | README.rdoc |
rest_connection-1.0.1 | README.rdoc |
rest_connection-1.0.0 | README.rdoc |
rest_connection-0.1.12 | README.rdoc |
rest_connection-0.1.11 | README.rdoc |