[][src]Struct longshoreman::Docker

pub struct Docker { /* fields omitted */ }

A Docker client.

The Docker client provides top-level API endpoints, and is used to instantiate the other clients.

Example

use longshoreman::Docker;

let docker_client = Docker::new();

Implementations

impl Docker[src]

#[must_use]pub fn new() -> Docker[src]

constructs a new Docker instance for a docker host listening at a url specified by an env var DOCKER_HOST, falling back to unix:///var/run/docker.sock

pub fn unix(socket_path: impl Into<PathBuf>) -> Docker[src]

Creates a new docker instance for a docker host listening on a given Unix socket.

pub fn host(host: &Uri) -> Docker[src]

constructs a new Docker instance for docker host listening at the given host url

#[must_use]pub fn images(&self) -> Images[src]

Return an Images client.

See the Images client docs for more details

Example

use longshoreman::Docker;

let images = Docker::new().images();

#[must_use]pub fn containers(&self) -> Containers[src]

Return an Containers client.

See the Containers client docs for more details

Example

use longshoreman::Docker;

let containers = Docker::new().containers();

Trait Implementations

impl Debug for Docker[src]

impl Default for Docker[src]

Auto Trait Implementations

impl !RefUnwindSafe for Docker

impl Send for Docker

impl Sync for Docker

impl Unpin for Docker

impl !UnwindSafe for Docker

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.