From bf436a081442be041b7114f90babc23c67e2d767 Mon Sep 17 00:00:00 2001 From: Drew Short Date: Tue, 7 Apr 2020 16:11:19 -0500 Subject: [PATCH] Added pipeline --- pipeline.yml | 40 ++++++++++++++++++++++++++++++++++++++++ upload_pipeline.sh | 11 +++++++++++ 2 files changed, 51 insertions(+) create mode 100644 pipeline.yml create mode 100755 upload_pipeline.sh diff --git a/pipeline.yml b/pipeline.yml new file mode 100644 index 0000000..e46b707 --- /dev/null +++ b/pipeline.yml @@ -0,0 +1,40 @@ +--- +resources: + - name: git-resource + type: git + icon: git + source: + uri: https://git.nulloctet.com/docker/botamusique.git + tag_filter: "*[0-9].*[0-9].*[0-9]" + - name: git-resource-image-nexus + type: docker-image + icon: docker + source: + repository: ((nexus_docker_write.host))/sothr/botamusiqe + username: ((nexus_docker_write.username)) + password: ((nexus_docker_write.password)) + - name: git-resource-image + type: docker-image + icon: docker + source: + repository: sothr/botamusique + username: ((hub_docker_write.username)) + password: ((hub_docker_write.password)) + +jobs: + - name: build-image + plan: + - get: git-resource + trigger: true + - put: git-resource-image-nexus + params: + build: git-resource + tag_file: git-resource/.git/ref + tag_as_latest: true + get_params: {skip_download: true} + - put: git-resource-image + params: + build: git-resource + tag_file: git-resource/.git/ref + tag_as_latest: true + get_params: {skip_download: true} diff --git a/upload_pipeline.sh b/upload_pipeline.sh new file mode 100755 index 0000000..8b9d060 --- /dev/null +++ b/upload_pipeline.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +TEAM=docker +PIPELINE=botamusique + +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" +pushd "${DIR}" + +fly -t ${TEAM} set-pipeline --pipeline ${PIPELINE} --config pipeline.yml + +popd