~gagbo/rustpad

e74e171265dbae68f4371e1e4be6a935375a50f9 — Gerry Agbobada 4 months ago 043cd37 gagbo_piston
fix(ci): fix pushing tagged images without rebuild
1 files changed, 3 insertions(+), 3 deletions(-)

M .builds/main.yml
M .builds/main.yml => .builds/main.yml +3 -3
@@ 14,9 14,9 @@ tasks:
  - test_and_build: |
      cd rustpad
      git fetch
      docker build -t gagbo/rustpad:piston-latest --build-arg GIT_SHA=$(git rev-parse HEAD) --build-arg GIT_DESC=$(git describe --tags) .
      docker build -t rustpad_ci --build-arg GIT_SHA=$(git rev-parse HEAD) --build-arg GIT_DESC=$(git describe --tags) .
  - deploy: |
      cd rustpad
      git fetch
      [ `git rev-parse HEAD` == `git rev-parse origin/gagbo_piston` ] && docker push gagbo/rustpad:piston-latest || echo "Skipping docker push for $(git name-rev --name-only HEAD) (head of gagbo_piston branch is $(git rev-parse origin/gagbo_piston))"
      [ `git describe --exact-match` != "" ] && docker push gagbo/rustpad:piston-$(git describe --exact-match) || echo "Not pushing tagged version"
      [ `git rev-parse HEAD` == `git rev-parse origin/gagbo_piston` ] && docker tag rustpad_ci gagbo/rustpad:piston-latest && docker push gagbo/rustpad:piston-latest || echo "Skipping docker push for $(git name-rev --name-only HEAD) (head of gagbo_piston branch is $(git rev-parse origin/gagbo_piston))"
      [ `git describe --exact-match` != "" ] && docker tag rustpad_ci gagbo/rustpad:piston-$(git describe --exact-match) && docker push gagbo/rustpad:piston-$(git describe --exact-match) || echo "Not pushing tagged version"