Struct docker_api::container::Container [−][src]
pub struct Container<'docker> { /* fields omitted */ }
Expand description
Interface for accessing and manipulating a docker container
Api Reference: https://docs.docker.com/engine/api/v1.41/#tag/Container
Implementations
Exports an interface exposing operations against a container instance
Inspects the current docker container instance’s details
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerInspect
Returns a top
view of information about the container process
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerTop
Returns a stream of logs emitted but the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerLogs
Attaches a [TtyMultiplexer]
to the container.
The [TtyMultiplexer]
implements Stream for returning Stdout and Stderr chunks. It also implements [AsyncWrite]
for writing to Stdin.
The multiplexer can be split into its read and write halves with the [split](TtyMultiplexer::split)
method
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerAttach
Returns a set of changes made to the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerChanges
Exports the current docker container into a tarball
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerExport
Returns a stream of stats specific to this container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerStats
Start the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerStart
Stop the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerStop
Restart the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerRestart
Kill the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerKill
Rename the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerRename
Pause the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerPause
Unpause the container instance
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerUnpause
Wait until the container stops
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerWait
Delete the container instance
Use remove instead to use the force/v options.
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerDelete
Delete the container instance (todo: force/v)
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerRemove
Execute a command in this container
Api Reference: https://docs.docker.com/engine/api/v1.41/#tag/Exec
Copy a file/folder from the container. The resulting stream is a tarball of the extracted files.
If path
is not an absolute path, it is relative to the container’s root directory. The
resource specified by path
must exist. To assert that the resource is expected to be a
directory, path
should end in /
or /
. (assuming a path separator of /
). If path
ends in /.
then this indicates that only the contents of the path directory should be
copied. A symlink is always resolved to its target.
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/ContainerArchive
Copy a byte slice as file into (see bytes
) the container.
The file will be copied at the given location (see path
) and will be owned by root
with access mask 644.
Api Reference: https://docs.docker.com/engine/api/v1.41/#operation/PutContainerArchive
Trait Implementations
Auto Trait Implementations
impl<'docker> !RefUnwindSafe for Container<'docker>
impl<'docker> !UnwindSafe for Container<'docker>