google-cloud-metadata 0.5.0

Google Cloud Platform rust client.
Documentation

google-cloud-metadata

Google Cloud Platform GCE check library.

crates.io

Installation

[dependencies]
google-cloud-metadata = <version>

Usage

use google_cloud_metadata::*;

#[tokio::test]
async fn test_on_gce() {
    // true: server is running on the GCP such as GCE and GKE.
    let result = on_gce().await;
    assert_eq!(true, result);
}