README.rdoc in engineyard-metadata-0.0.5 vs README.rdoc in engineyard-metadata-0.0.6

- old
+ new

@@ -9,23 +9,49 @@ == Examples * Get a dynamically updated list of all running app servers so that you can pool memcached over all of them. (<tt>EY::Metadata.app_servers</tt>) * Get the current database password so that you can write a script that connects to it. (<tt>EY::Metadata.database_password</tt>) -Get the full method list in {the engineyard-metadata rdoc}[http://rdoc.info/github/seamusabshere/engineyard-metadata]. +Here's the current method list: + EY::Metadata.present_instance_id (only works from cloud instances) + EY::Metadata.present_security_group (only works from cloud instances) + EY::Metadata.present_instance_role (only works from cloud instances) + EY::Metadata.present_public_hostname (only works from cloud instances) + EY::Metadata.database_password (only works from cloud instances) + EY::Metadata.database_username + EY::Metadata.database_name + EY::Metadata.database_host + EY::Metadata.ssh_username + EY::Metadata.ssh_password (only works from cloud instances) + EY::Metadata.app_servers + EY::Metadata.db_servers + EY::Metadata.utilities + EY::Metadata.app_master + EY::Metadata.db_master + EY::Metadata.mysql_command (only works from cloud instances) + EY::Metadata.mysqldump_command (only works from cloud instances) + EY::Metadata.app_slaves + EY::Metadata.db_slaves + EY::Metadata.solo + EY::Metadata.environment_name + EY::Metadata.stack_name + EY::Metadata.repository_uri + == Use -=== From the inside +See the rdoc at {the engineyard-metadata rdoc}[http://rubydoc.info/gems/engineyard-metadata]. +=== When you're executing this gem from INSIDE the cloud + When you're executing the gem from your instances, you don't have to configure anything. Just require the gem. -=== From the outside +=== When you're executing this gem from OUTSIDE the cloud -You need to provide... +You must... -* <tt>ENV['EY_CLOUD_TOKEN']</tt> or have <tt>~/.eyrc</tt> -* <tt>ENV['REPOSITORY_URI']</tt> or execute the gem from the local copy of your application's repo. +* have <tt>~/.eyrc</tt> or set <tt>EY::Metadata.ey_cloud_token=</tt> or set <tt>ENV['EY_CLOUD_TOKEN']</tt>. +* execute the gem from the local copy of your application's repo or set <tt>EY::Metadata.environment_name=</tt> or set <tt>ENV['EY_ENVIRONMENT_NAME']</tt>. === Where the methods are defined Metadata getters are defined directly on <tt>EY::Metadata</tt> (which in turn delegates out to various adapters). Even if EngineYard changes the structure of the config files or Amazon EC2's API changes, these methods will stay the same.