From 077c13b60951ad80d6e3034ca55afb6a7350e9ba Mon Sep 17 00:00:00 2001
From: Carlos Natalino <carlos.natalino@chalmers.se>
Date: Fri, 28 Apr 2023 16:31:41 +0200
Subject: [PATCH] Removing `deploy` stage

---
 src/dbscanserving/.gitlab-ci.yml          | 48 +++++++++++------------
 src/opticalattackdetector/.gitlab-ci.yml  | 48 +++++++++++------------
 src/opticalattackmanager/.gitlab-ci.yml   | 48 +++++++++++------------
 src/opticalattackmitigator/.gitlab-ci.yml | 48 +++++++++++------------
 4 files changed, 96 insertions(+), 96 deletions(-)

diff --git a/src/dbscanserving/.gitlab-ci.yml b/src/dbscanserving/.gitlab-ci.yml
index 0b212779b..443858454 100644
--- a/src/dbscanserving/.gitlab-ci.yml
+++ b/src/dbscanserving/.gitlab-ci.yml
@@ -78,27 +78,27 @@ unit_test dbscanserving:
 
 
 # Deployment of the dbscanserving service in Kubernetes Cluster
-deploy dbscanserving:
-  variables:
-    IMAGE_NAME: 'dbscanserving' # name of the microservice
-    IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
-  stage: deploy
-  needs:
-    - unit test dbscanserving
-    # - integ_test execute
-  script:
-    - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
-    - kubectl version
-    - kubectl get all
-    - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
-    - kubectl get all
-  # environment:
-  #   name: test
-  #   url: https://example.com
-  #   kubernetes:
-  #     namespace: test
-  rules:
-    - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
-      when: manual    
-    - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
-      when: manual
\ No newline at end of file
+# deploy dbscanserving:
+#   variables:
+#     IMAGE_NAME: 'dbscanserving' # name of the microservice
+#     IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
+#   stage: deploy
+#   needs:
+#     - unit test dbscanserving
+#     # - integ_test execute
+#   script:
+#     - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
+#     - kubectl version
+#     - kubectl get all
+#     - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
+#     - kubectl get all
+#   # environment:
+#   #   name: test
+#   #   url: https://example.com
+#   #   kubernetes:
+#   #     namespace: test
+#   rules:
+#     - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
+#       when: manual    
+#     - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
+#       when: manual
\ No newline at end of file
diff --git a/src/opticalattackdetector/.gitlab-ci.yml b/src/opticalattackdetector/.gitlab-ci.yml
index 313a1da97..438079454 100644
--- a/src/opticalattackdetector/.gitlab-ci.yml
+++ b/src/opticalattackdetector/.gitlab-ci.yml
@@ -77,27 +77,27 @@ unit_test opticalattackdetector:
 
 
 # Deployment of the opticalattackdetector service in Kubernetes Cluster
-deploy opticalattackdetector:
-  variables:
-    IMAGE_NAME: 'opticalattackdetector' # name of the microservice
-    IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
-  stage: deploy
-  needs:
-    - unit test opticalattackdetector
-    # - integ_test execute
-  script:
-    - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
-    - kubectl version
-    - kubectl get all
-    - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
-    - kubectl get all
-  # environment:
-  #   name: test
-  #   url: https://example.com
-  #   kubernetes:
-  #     namespace: test
-  rules:
-    - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
-      when: manual    
-    - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
-      when: manual
\ No newline at end of file
+# deploy opticalattackdetector:
+#   variables:
+#     IMAGE_NAME: 'opticalattackdetector' # name of the microservice
+#     IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
+#   stage: deploy
+#   needs:
+#     - unit test opticalattackdetector
+#     # - integ_test execute
+#   script:
+#     - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
+#     - kubectl version
+#     - kubectl get all
+#     - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
+#     - kubectl get all
+#   # environment:
+#   #   name: test
+#   #   url: https://example.com
+#   #   kubernetes:
+#   #     namespace: test
+#   rules:
+#     - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
+#       when: manual    
+#     - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
+#       when: manual
\ No newline at end of file
diff --git a/src/opticalattackmanager/.gitlab-ci.yml b/src/opticalattackmanager/.gitlab-ci.yml
index 6814bc4f0..bbb5c437e 100644
--- a/src/opticalattackmanager/.gitlab-ci.yml
+++ b/src/opticalattackmanager/.gitlab-ci.yml
@@ -79,27 +79,27 @@ unit_test opticalattackmanager:
         junit: src/$IMAGE_NAME/tests/${IMAGE_NAME}_report.xml
 
 # Deployment of the service in Kubernetes Cluster
-deploy opticalattackmanager:
-  variables:
-    IMAGE_NAME: 'opticalattackmanager' # name of the microservice
-    IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
-  stage: deploy
-  needs:
-    - unit test opticalattackmanager
-    # - integ_test execute
-  script:
-    - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
-    - kubectl version
-    - kubectl get all
-    - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
-    - kubectl get all
-  # environment:
-  #   name: test
-  #   url: https://example.com
-  #   kubernetes:
-  #     namespace: test
-  rules:
-    - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
-      when: manual    
-    - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
-      when: manual
+# deploy opticalattackmanager:
+#   variables:
+#     IMAGE_NAME: 'opticalattackmanager' # name of the microservice
+#     IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
+#   stage: deploy
+#   needs:
+#     - unit test opticalattackmanager
+#     # - integ_test execute
+#   script:
+#     - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
+#     - kubectl version
+#     - kubectl get all
+#     - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
+#     - kubectl get all
+#   # environment:
+#   #   name: test
+#   #   url: https://example.com
+#   #   kubernetes:
+#   #     namespace: test
+#   rules:
+#     - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
+#       when: manual    
+#     - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
+#       when: manual
diff --git a/src/opticalattackmitigator/.gitlab-ci.yml b/src/opticalattackmitigator/.gitlab-ci.yml
index fcb3ccf10..58e8e2680 100644
--- a/src/opticalattackmitigator/.gitlab-ci.yml
+++ b/src/opticalattackmitigator/.gitlab-ci.yml
@@ -76,27 +76,27 @@ unit_test opticalattackmitigator:
 
 
 # Deployment of the opticalattackmitigator service in Kubernetes Cluster
-deploy opticalattackmitigator:
-  variables:
-    IMAGE_NAME: 'opticalattackmitigator' # name of the microservice
-    IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
-  stage: deploy
-  needs:
-    - unit test opticalattackmitigator
-    # - integ_test execute
-  script:
-    - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
-    - kubectl version
-    - kubectl get all
-    - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
-    - kubectl get all
-  # environment:
-  #   name: test
-  #   url: https://example.com
-  #   kubernetes:
-  #     namespace: test
-  rules:
-    - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
-      when: manual    
-    - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
-      when: manual
\ No newline at end of file
+# deploy opticalattackmitigator:
+#   variables:
+#     IMAGE_NAME: 'opticalattackmitigator' # name of the microservice
+#     IMAGE_TAG: 'latest' # tag of the container image (production, development, etc)
+#   stage: deploy
+#   needs:
+#     - unit test opticalattackmitigator
+#     # - integ_test execute
+#   script:
+#     - 'sed -i "s/$IMAGE_NAME:.*/$IMAGE_NAME:$IMAGE_TAG/" manifests/${IMAGE_NAME}service.yaml'
+#     - kubectl version
+#     - kubectl get all
+#     - kubectl apply -f "manifests/${IMAGE_NAME}service.yaml"
+#     - kubectl get all
+#   # environment:
+#   #   name: test
+#   #   url: https://example.com
+#   #   kubernetes:
+#   #     namespace: test
+#   rules:
+#     - if: '$CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH)'
+#       when: manual    
+#     - if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == "develop"'
+#       when: manual
\ No newline at end of file
-- 
GitLab