terraform-provider-docker/docs/resources/image.md
2021-05-13 08:06:55 +02:00

1.3 KiB

page_title subcategory description
docker_image Resource - terraform-provider-docker

docker_image (Resource)

Schema

Required

  • name (String)

Optional

  • build (Block Set, Max: 1) (see below for nested schema)
  • force_remove (Boolean) Force remove the image when the resource is destroyed
  • id (String) The ID of this resource.
  • keep_locally (Boolean)
  • pull_trigger (String, Deprecated)
  • pull_triggers (Set of String)

Read-Only

  • latest (String)
  • output (String)

Nested Schema for build

Required:

  • path (String) Context path

Optional:

  • build_arg (Map of String) Set build-time variables
  • dockerfile (String) Name of the Dockerfile (Default is 'PATH/Dockerfile')
  • force_remove (Boolean) Always remove intermediate containers
  • label (Map of String) Set metadata for an image
  • no_cache (Boolean) Do not use cache when building the image
  • remove (Boolean) Remove intermediate containers after a successful build (default true)
  • tag (List of String) Name and optionally a tag in the 'name:tag' format
  • target (String) Set the target build stage to build