jenkins-bot has submitted this change and it was merged.

Change subject: Migrate npm legacy test to trusty nodepool
......................................................................


Migrate npm legacy test to trusty nodepool

Zuul: rename template npm-legacy to npm-node-0.10

Delete npm
Create npm-node-0.10

NOTE: the source code is cloned under /src/ to workaround banana checker
groking on pywikibot/i18n because of a /log/ file.

Bug: T119143
Bug: T130207
Depends-On: Ifb1dae3f572a9f6bc0c3998a3f1b97277b28ddf4
Change-Id: I4f2048625e9c568180393b636650430f3d8f004b
---
M jjb/job-templates.yaml
M zuul/layout.yaml
M zuul/parameter_functions.py
3 files changed, 46 insertions(+), 18 deletions(-)

Approvals:
  Hashar: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/jjb/job-templates.yaml b/jjb/job-templates.yaml
index 4fac0a5..afad179 100644
--- a/jjb/job-templates.yaml
+++ b/jjb/job-templates.yaml
@@ -102,17 +102,38 @@
     maven:
       goals: clean package
 
-- job:
-    name: 'npm'
-    node: contintLabsSlave && UbuntuTrusty
-    defaults: use-remote-zuul-shallow-clone
+- job: &job_npm-node-0_10
+    name: 'npm-node-0.10'
+    node: ci-trusty-wikimedia
+    defaults: use-remote-zuul-shallow-clone-to-src
     concurrent: true
+    properties:
+     - zeromq-event
     triggers:
      - zuul
     builders:
-     - npm
+     - assert-node-version-0.10
+     # FIXME: we should save node_modules and run npm prune
+     - castor-load
+     - shell: |
+         # For archiving build artifacts
+         mkdir -p "$WORKSPACE/log"
+         node --version
+         npm --version
+
+         cd src
+         npm install
+         npm test
     publishers:
-     - global-teardown
+     - archive-log-allow-empty
+     - castor-save
+
+- job-template:
+    !!merge : *job_npm-node-0_10
+    name: '{name}-npm-node-0.10'
+    # Reinject Zuul parameters since JJB strip for some reason
+    triggers:
+     - zuul
 
 - job: &job_npm-node-4_3
     name: 'npm-node-4.3'
@@ -184,23 +205,28 @@
      - archive-log-allow-empty
      - castor-save
 
-
 - job-template:
-    name: '{name}-{repository}-npm'
-    node: contintLabsSlave && UbuntuTrusty
+    name: '{name}-{repository}-npm-node-0.10'
+    node: ci-trusty-wikimedia
     defaults: use-remoteonly-zuul
     concurrent: true
+    properties:
+     - zeromq-event
     triggers:
      - zuul
     builders:
+     - assert-node-version-0.10
+     # FIXME: we should save node_modules and run npm prune
+     - castor-load
+     - shell: |
+         # For archiving build artifacts
+         mkdir -p "$WORKSPACE/log"
      - npm-oid:
          repository: '{repository}'
     publishers:
-     - global-teardown
+     - archive-log-allow-empty
+     - castor-save
 
-# Similar to '{name}-{repository}-npm' but:
-# - runs on Nodepool instances
-# - uses nodejs 4.3 as a result
 - job-template:
     name: '{name}-{repository}-npm-node-4.3'
     node: ci-jessie-wikimedia
diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index e379b8d..17536ac 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -1166,11 +1166,11 @@
     gate-and-submit:
       - npm-node-4.3
 
-  - name: npm-legacy
+  - name: npm-node-0.10
     test:
-      - npm
+      - npm-node-0.10
     gate-and-submit:
-      - npm
+      - npm-node-0.10
     experimental:
       - npm-node-4.3
 
@@ -2134,7 +2134,7 @@
   - name: wikimedia/fundraising/dash
     template:
       # Depends on [email protected] which does not work on Node 4.3
-      - name: npm-legacy
+      - name: npm-node-0.10
     check:
       - jshint
       - jsonlint
@@ -8004,7 +8004,7 @@
     template:
       # Cant switch to node-4.3 because we create a /log/ dir in the source
       # tree and banana complains it can not read /log/qqq.json
-      - name: npm-legacy  # T130207
+      - name: npm-node-0.10  # T130207
     check:
       - jsonlint
 
diff --git a/zuul/parameter_functions.py b/zuul/parameter_functions.py
index 7151cd3..d64bc34 100644
--- a/zuul/parameter_functions.py
+++ b/zuul/parameter_functions.py
@@ -45,6 +45,8 @@
         nodepool_params(item, job, params)
     elif job.name.endswith('node-4.3'):
         nodepool_params(item, job, params)
+    elif job.name.endswith('node-0.10'):
+        nodepool_params(item, job, params)
     elif job.name in ['integration-jjb-config-diff']:
         nodepool_params(item, job, params)
 

-- 
To view, visit https://gerrit.wikimedia.org/r/290486
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4f2048625e9c568180393b636650430f3d8f004b
Gerrit-PatchSet: 12
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Paladox <[email protected]>
Gerrit-Reviewer: Hashar <[email protected]>
Gerrit-Reviewer: JanZerebecki <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to