DockerImage constructor

DockerImage({
  1. required String path,
  2. String? tag,
  3. bool cleanUp = true,
  4. String? dockerfilePath,
  5. bool noCache = false,
  6. DockerClient? dockerClient,
})

Creates a DockerImage from the given parameters.

An optional dockerClient can be injected for testing; the default instance reads connection settings from the environment.

Implementation

DockerImage({
  required this.path,
  this.tag,
  this.cleanUp = true,
  this.dockerfilePath,
  this.noCache = false,
  DockerClient? dockerClient,
}) : _dockerClient = dockerClient ?? DockerClient();