From a02149bff821c6dd895363ff98dc0f7132005b24 Mon Sep 17 00:00:00 2001
From: David Hoese <david.hoese@ssec.wisc.edu>
Date: Tue, 21 Jul 2020 16:16:08 -0500
Subject: [PATCH] Update rabbitmq deploy to only selectively run

---
 .gitlab-ci.yml | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 182bc0e..e06f753 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -138,7 +138,14 @@ deploy_prod_rabbit:
   rules:
     - if: '$kubekorner_k3s_config == ""'
       when: never
-    - when: on_success
+    # no need to build if another project triggered us
+    - if: $CI_PIPELINE_SOURCE == "pipeline"
+      when: never
+    - changes:
+        - production/values-geosphere-rabbit.yaml
+      when: always
+    - if: $DEPLOY_RABBIT
+      when: always
 
 
 deploy_g16_grb:
-- 
GitLab