From 3c967e50558b8acfc248b7bd143a282ea7fcc587 Mon Sep 17 00:00:00 2001
From: Adar Nimrod <nimrod@shore.co.il>
Date: Fri, 4 Jun 2021 17:27:17 +0300
Subject: [PATCH] Fix GitLab CI pipeline.

Without the CONTEXT variable, the rules for push jobs was broken and
always triggered. This also pulled in the dependency jobs. I don't see a
way to avoid defining the CONTEXT variable in both build and push jobs.
---
 .gitlab-ci.yml | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index d56652a..98e537e 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -16,7 +16,6 @@ stages:
 # hard-coded to latest.
 variables:
   TAG: latest
-  CONTEXT: "$IMAGE"
 
 # Job templates:
 
@@ -72,6 +71,7 @@ build-httpd:
 push-httpd:
   extends: .push
   variables:
+    CONTEXT: httpd/buster
     IMAGE: httpd
   needs:
     - job: build-httpd
@@ -82,6 +82,7 @@ push-httpd:
 push-httpd-buster:
   extends: .push
   variables:
+    CONTEXT: httpd/buster
     IMAGE: httpd
     TAG: buster
   needs:
@@ -98,6 +99,7 @@ build-httpd-bullseye:
 push-httpd-bullseye:
   extends: .push
   variables:
+    CONTEXT: httpd/bullseye
     IMAGE: httpd
     TAG: bullseye
   needs:
-- 
GitLab