Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

openstack-compute

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

openstack-compute

  • 1.1.10
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

= Ruby OpenStack Compute

== Description

Ruby Openstack Compute binding for the v1.0 OSAPI.

Currently supports both v1.0 and v2.0 (keystone) auth.

== Examples

See the class definitions for documentation on specific methods and operations.

require 'openstack/compute'

cs = OpenStack::Compute::Connection.new(:username => USERNAME, :api_key => API_KEY, :authtenant => TENANT, :auth_url => API_URL)

Get a listing of all current servers

cs.servers => [{:name=>"Server1", :id=>110917}]

Access a specific server

server = cs.server(110917) server.name => "Server1"

See what type of server this is

server.flavor.name => "256 server" server.image.name => "Ubuntu 8.04.2 LTS (hardy)"

Soft-reboot the server

server.reboot => true

Create a new 512MB CentOS 5.2 server. The root password is returned in the adminPass method.

image = cs.get_image(8) => #<OpenStack::Compute::Image:0x1014a8060 ...>, status"ACTIVE" image.name => "CentOS 5.2" flavor = cs.get_flavor(2) => #<OpenStack::Compute::Flavor:0x101469130 @disk=20, @name="512 server", @id=2, @ram=512> flavor.name => "512 server" newserver = cs.create_server(:name => "New Server", :imageRef => image.id, :flavorRef => flavor.id) => #<OpenStack::Compute::Server:0x101433f08 .... newserver.status => "BUILD" newserver.progress => 0 newserver.adminPass => "NewServerMbhzUnO" newserver.refresh => true newserver.progress => 12

Delete the new server

newserver.delete! => true

== Authors

By Dan Prince dprince@redhat.com, Naveed Massjouni naveedm9@gmail.com

Based on the Rackspace Cloud Servers Ruby API.

== License

See COPYING for license information.

FAQs

Package last updated on 24 Jul 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc