[−][src]Crate gcemeta
This library provides access to GCE metadata service
.
Example
use gcemeta::*; println!("on_gce = {:?}", on_gce()); println!("project_id = {:?}", project_id());
Structs
Error | Represents errors that can occur during handling metadata service. |
Enums
ErrorKind | Represents the details of the |
Functions
external_ip | Get the instance's primary external (public) IP address. |
get | Get value from the metadata service. |
hostname | Get the instance's hostname. |
instance_attribute_value | Get the value of the provided VM instance attribute. |
instance_attributes | Get the list of user-defined attributes, assigned when initially creating a GCE VM instance. |
instance_id | Get the current VM's numeric instance ID. |
instance_name | Get the current VM's instance ID string. |
instance_tags | Get the list of user-defined instance tags, assigned when initially creating a GCE instance. |
internal_ip | Get the instance's primary internal IP address. |
numeric_project_id | Get the current instance's numeric project ID. |
on_gce | Report whether this process is running on Google Compute Engine. |
project_attribute_value | Get the value of the provided project attribute. |
project_attributes | Get the list of user-defined attributes applying to the project as a whole, not just this VM. |
project_id | Get the current instance's project ID string. |
scopes | Get the service account scopes for the given account. |
zone | Get the current VM's zone, such as |
Type Definitions
Result | Wrapper for the |