Skip to content

Latest commit

 

History

History
71 lines (43 loc) · 1.84 KB

README.md

File metadata and controls

71 lines (43 loc) · 1.84 KB

ECR Push Buildkite Plugin

Note: This plugin is a fork of [seek-oss/docker-ecr-publish-buildkite-plugin].

A Buildkite plugin to build, tag, and push Docker images to Amazon ECR.

Example

The following pipeline builds the default ./Dockerfile and pushes it to a pre-existing ECR repository my-repo:

steps:
  - plugins:
      - Shuttl-Tech/ecr-push#v1.0.0:
          repository: my-repo

An alternate Dockerfile may be specified:

steps:
  - plugins:
      - Shuttl-Tech/ecr-push#v1.0.0:
          dockerfile: path/to/final.Dockerfile
          repository: my-repo

Build-time variables are supported, either with an explicit value, or without one to propagate an environment variable from the pipeline step:

Configuration

  • context (optional, string)

    The Docker build context. Valid values are as per the API

    Default: .

  • cache_from_tag (optional, string)

    Images tag in target repository for Docker to use as cache sources, e.g. a base or dependency image.

  • dockerfile (optional, string)

    Local path to a custom Dockerfile.

    Default: Dockerfile

  • repository (required, string)

    Name of the ECR repository.

  • region (optional, string)

    Region the ECR registry is in, defaults to $AWS_DEFAULT_REGION and then to the AWS region of build agent if not set.

  • tags (optional, array|string)

    Tags to push on all builds.

    Default: $BUILDKITE_COMMIT and first 8 characters of the commit hash.

  • public_org_name (optional, string)

    Name of the public ECR organization if the image is to be pushed to a public ECR repository.

License

MIT (see LICENSE)