From d7245c03985f6a7cc14137edb48b72c453ab2f85 Mon Sep 17 00:00:00 2001
From: Neda Moeini <neda.moeini@geant.org>
Date: Mon, 6 Nov 2023 10:18:44 +0100
Subject: [PATCH] Added trigger_jenkins_build job to the pipeline.

---
 .gitlab-ci.yml | 12 ++++++++++++
 Jenkinsfile    | 20 --------------------
 2 files changed, 12 insertions(+), 20 deletions(-)
 delete mode 100644 Jenkinsfile

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index ecc1e2412..8b17e2a48 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -3,6 +3,7 @@ stages:
   - tox
   - documentation
   - sonarqube
+  - trigger_jenkins_build
 include:
   - docs/.gitlab-ci.yml
 
@@ -55,3 +56,14 @@ sonarqube:
     - sonar-scanner -Dsonar.login=$SONAR_TOKEN -Dproject.settings=./sonar.properties
   tags:
     - docker-executor
+
+trigger_jenkins_build:
+  stage: deploy
+  script:
+    - curl "http://test-swd-release-service01.geant.org:8080/job/build-python-snapshot/buildWithParameters" \
+      --user $JENKINS_USERNAME:$JENKINS_API_TOKEN \
+      --data "PROJECT=${PROJECT_NAME}"
+  only:
+    - develop
+  tags:
+    - docker-executor
\ No newline at end of file
diff --git a/Jenkinsfile b/Jenkinsfile
deleted file mode 100644
index 6d5a7cc76..000000000
--- a/Jenkinsfile
+++ /dev/null
@@ -1,20 +0,0 @@
-// https://gitlab.geant.net/live-projects/jenkins-pipeline/-/tree/master/vars
-library 'SWDPipeline'
-
-// Parameters:
-// name (must match the name of the project in GitLab/SWD release jenkins)
-String name = 'geant-service-orchestrator'
-
-// emails of people to always notify on build status changes
-List<String> extraRecipients = ['erik.reid@geant.org']
-
-// python versions (docker tags) to test against, must be explicit versions
-List<String> pythonTestVersions = ['3.11']
-
-// Environment variables you want to pass
-Map<String, String> appEnvironmentVariables = [
-    'SKIP_ALL_TESTS': '1',
-    // add more as needed
-]
-
-SimplePythonBuild(name, extraRecipients, pythonTestVersions, appEnvironmentVariables)
-- 
GitLab