openci: Fix the event origin in compose job
[releng.git] / jjb / openci / openci-opnfv-daily-jobs.yaml
index 78b2eb1..ad2bce0 100644 (file)
@@ -44,7 +44,7 @@
           name: SCENARIO_METADATA_LOCATION
           default: https://url/to/scenario/metadata/on/opnfv/artifact/repo/$BUILD_NUMBER
           description: 'The location of the scenario metadata'
-      - 'opnfv-build-defaults'
+      - 'ericsson-build4-defaults'
 
     wrappers:
       - credentials-binding:
@@ -57,7 +57,7 @@
     triggers:
       - jms-messaging:
           provider-name: openci.activemq
-          selector: JMSType = 'ArtifactPublishedEvent' and JMSOrigin = 'ODL'
+          selector: JMSType = 'ArtifactPublishedEvent' and JMSOrigin = '{origin}'
 
     builders:
       - shell: |
           name: CONFIDENCE_LEVEL
           default: "'opnfvdaily': 'SUCCESS'"
           description: 'The confidence level the published artifact gained'
-      - 'opnfv-build-defaults'
+      - 'ericsson-build4-defaults'
+
+    wrappers:
+      - credentials-binding:
+          - username-password-separated:
+              credential-id: openci-connect-activemq
+              username: ACTIVEMQ_USER
+              password: ACTIVEMQ_PASSWORD
+      - workspace-cleanup
 
     triggers:
       - jms-messaging:
           provider-name: openci.activemq
-          selector: CI_TYPE = 'custom'
-          checks:
-            - field: origin
-              expected-value: 'OPNFV'
-            - field: type
-              expected-value: 'CompositionDefinedEvent'
-            - field: scenario
-              expected-value: '{scenario}'
+          selector: JMSType = 'CompositionDefinedEvent' and JMSOrigin = 'OPNFV' and JMSScenario = '{scenario}'
 
     builders:
       - shell: |
           echo "----------------------------------"
       - shell:
           !include-raw-escape: ./create-clme.sh
-      - inject:
-          properties-file: "$WORKSPACE/event.properties"