docker 0.3.5

  • Installing
  • Versions
  • 43


A Dart wrapper around the Docker command line. Mainly thought as a helper-library for Grinder.

Basic usage

@Task("Stop containers")
dockerStopp() {
    ["db-webappbase-test", "db-mobiad-test"].forEach((final String container) {
        log("Stopping container: $container");
            new Docker()..stop([container ],quiet: true);

@Task("Start container")
dockerStart() {
    new Docker()..start([ "db-webappbase-test" ],quiet: true);

@Task("Check if container runs and if container is available")
containerCheck() async {
    final Docker docker = new Docker();

    [ "db-mobiad-test"].forEach((final String name) => docker.stop([ name ]));
    docker.start([ containerNameToCheck] );

    final Container container = new Container(runningContainerIDs());
    if(!container.names.contains(containerNameToCheck)) {

        container.names.forEach((final String name) {
            log("Active containers: -${name}-");

        throw new ArgumentError("${containerNameToCheck} must be running for this test!");


If you need want to dive into Dockers JSON-API check out bwu_docker

Features and bugs

Please file feature requests and bugs at the issue tracker.


Copyright 2018 Michael Mitterer (,
IT-Consulting and Development Limited, Austrian Branch

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
either express or implied. See the License for the specific language
governing permissions and limitations under the License.

If this plugin is helpful for you - please (Circle) me or star this repo here on GitHub

Change Log for docker

A Dart wrapper around the Docker command line




  • Minimal SDK is now Dart 2.0 326df61

v0.3 - 2017-12-07


  • More relaxed version constraints 1bed1a5

v0.1.5 - 2016-11-16


v0.1.0 - 2015-12-10


This was generated with Changelog for Dart

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  docker: ^0.3.5

2. Install it

You can install packages from the command line:

with pub:

$ pub get

with Flutter:

$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:docker/docker.dart';
Version Uploaded Documentation Archive
0.3.5 Aug 28, 2018 Go to the documentation of docker 0.3.5 Download docker 0.3.5 archive
0.3.3 May 30, 2018 Go to the documentation of docker 0.3.3 Download docker 0.3.3 archive
0.3.1 May 30, 2018 Go to the documentation of docker 0.3.1 Download docker 0.3.1 archive
0.2.4 Dec 7, 2017 Go to the documentation of docker 0.2.4 Download docker 0.2.4 archive
0.2.0 Dec 7, 2017 Go to the documentation of docker 0.2.0 Download docker 0.2.0 archive
0.1.6 Dec 5, 2016 Go to the documentation of docker 0.1.6 Download docker 0.1.6 archive
0.1.5 Nov 16, 2016 Go to the documentation of docker 0.1.5 Download docker 0.1.5 archive
0.1.4 Oct 13, 2016 Go to the documentation of docker 0.1.4 Download docker 0.1.4 archive
0.1.3 Dec 10, 2015 Go to the documentation of docker 0.1.3 Download docker 0.1.3 archive
0.1.2 Dec 10, 2015 Go to the documentation of docker 0.1.2 Download docker 0.1.2 archive
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Jan 15, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.10


Detected platforms: Flutter, other

Primary library: package:docker/docker.dart with components: io.

Health suggestions

Fix lib/docker/DockerRunOptions.dart. (-1 points)

Analysis of lib/docker/DockerRunOptions.dart reported 2 hints:

line 38 col 26: 'SYSTEM_ENCODING' is deprecated and shouldn't be used.

line 39 col 26: 'SYSTEM_ENCODING' is deprecated and shouldn't be used.

Format lib/docker/Container.dart.

Run dartfmt to format lib/docker/Container.dart.

Format lib/docker/Docker.dart.

Run dartfmt to format lib/docker/Docker.dart.

Format lib/mock.dart.

Run dartfmt to format lib/mock.dart.

Maintenance issues and suggestions

Use analysis_options.yaml. (-10 points)

Rename old .analysis_options file to analysis_options.yaml.

Read more about the setup of analysis-options.yaml.

The description is too short. (-20 points)

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use docker.dart.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
logging >=0.11.3 <1.0.0 0.11.3+2
validate ^1.0.0 1.7.0
Dev dependencies
build_runner any
build_test any
build_web_compilers any
grinder any
test any