This is a Docker Remote API binding in Rust. Documentation is available here.
[dependencies]
docker = "0.0.13"
```rust extern crate docker;
use docker::Docker;
let docker = Docker::new(); ```
```rust extern crate docker;
use docker::Docker;
let containers = match docker.get_containers(false) { Ok(containers) => containers, Err(e) => { panic!("{}", e); } }; ```
```rust extern crate docker;
use docker::Docker;
let containers = match docker.get_containers(false) { Ok(containers) => containers, Err(e) => { panic!("{}", e); } };
let stats = match docker.get_stats(&containers[0]) { Ok(stats) => stats, Err(e) => { panic!("{}", e); } }; ```
```rust extern crate docker;
use docker::Docker;
let info = match docker.get_info() { Ok(info) => info, Err(e) => { panic!("{}", e); } }; ```