From 95697fae6a054115a7b052e0a45bd5b6891c9622 Mon Sep 17 00:00:00 2001 From: "Stephen M. Coakley" Date: Thu, 8 Aug 2019 16:39:53 -0500 Subject: [PATCH] Add docker-compose push support --- .../plugins/buildkite/BuildkitePipeline.groovy | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/buildSrc/src/main/groovy/com/widen/plugins/buildkite/BuildkitePipeline.groovy b/buildSrc/src/main/groovy/com/widen/plugins/buildkite/BuildkitePipeline.groovy index dd8e8c5..6bdf17f 100644 --- a/buildSrc/src/main/groovy/com/widen/plugins/buildkite/BuildkitePipeline.groovy +++ b/buildSrc/src/main/groovy/com/widen/plugins/buildkite/BuildkitePipeline.groovy @@ -346,6 +346,20 @@ class BuildkitePipeline implements ConfigurableEnvironment { model.run = service } + /** + * Push a built service to a repository. Multiple pushes are allowed in one step. + */ + void push(String service, String image) { + model.get('push', []) << "$service:$image" + } + + /** + * Push a built service to a repository. Multiple pushes are allowed in one step. + */ + void push(String service, String image, String tag) { + push(service, "$image:$tag") + } + /** * The repository for pushing and pulling pre-built images. */