You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by wi...@apache.org on 2019/10/14 09:34:42 UTC

[couchdb-fauxton] branch nodejs-10 created (now 03fe481)

This is an automated email from the ASF dual-hosted git repository.

willholley pushed a change to branch nodejs-10
in repository https://gitbox.apache.org/repos/asf/couchdb-fauxton.git.


      at 03fe481  Run production build in Travis

This branch includes the following new commits:

     new 4775d3d  Add node 10 to the CI build
     new 09a7864  WIP Jenkinsfile
     new 6036ded  Fix Node 10 localstorage in tests
     new 03fe481  Run production build in Travis

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[couchdb-fauxton] 03/04: Fix Node 10 localstorage in tests

Posted by wi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

willholley pushed a commit to branch nodejs-10
in repository https://gitbox.apache.org/repos/asf/couchdb-fauxton.git

commit 6036ded470d34a254292f324938b0178032ed609
Author: Will Holley <wi...@gmail.com>
AuthorDate: Mon Oct 14 10:06:47 2019 +0100

    Fix Node 10 localstorage in tests
---
 jest-setup.js | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/jest-setup.js b/jest-setup.js
index f137257..c7f01b0 100644
--- a/jest-setup.js
+++ b/jest-setup.js
@@ -14,7 +14,13 @@ require('jest');
 require('whatwg-fetch');
 require('mock-local-storage');
 
-window.localStorage = global.localStorage;
+Object.defineProperty(window, 'localStorage', {
+  value: global.localStorage,
+  configurable:true,
+  enumerable:true,
+  writable:true
+});
+
 window.$ = window.jQuery = require('jquery');
 window._ = require('lodash');
 window.Backbone = require('backbone');


[couchdb-fauxton] 04/04: Run production build in Travis

Posted by wi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

willholley pushed a commit to branch nodejs-10
in repository https://gitbox.apache.org/repos/asf/couchdb-fauxton.git

commit 03fe481c6ae6e4611f371a0504a0fe199777b228
Author: Will Holley <wi...@gmail.com>
AuthorDate: Mon Oct 14 10:33:45 2019 +0100

    Run production build in Travis
---
 .travis.yml | 57 ++++++++++++++++++++++++++++++---------------------------
 1 file changed, 30 insertions(+), 27 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 62c27b2..e679a1c 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -8,30 +8,33 @@ services:
 git:
   depth: 1
 
-env:
-  - COUCHDB_IMAGE=apache/couchdb:2.3.1 NIGHTWATCH_SKIPTAGS="search,partitioned"
-  - COUCHDB_IMAGE=couchdb:dev NIGHTWATCH_SKIPTAGS="search,nonpartitioned"
-  - COUCHDB_IMAGE=ibmcom/couchdb3:preview-1569600329 NIGHTWATCH_SKIPTAGS=nonpartitioned
-
-before_install:
-  - npm install -g npm@latest
-  - ./bin/build-couchdb-dev.sh
-install:
-  - npm ci
-before_script:
-  - travis_retry ./bin/docker-up-and-check.sh
-  - curl http://127.0.0.1:5984
-  - npm run stylecheck
-  - npm test
-  - grunt debugDev
-  - DIST=./dist/debug ./bin/fauxton &
-  - sleep 30
-script:
-  - ./node_modules/.bin/grunt nightwatch_retries
-after_script:
-  - npm run docker:down
-
-cache:
-  - apt
-  - directories:
-    - "$HOME/.npm"
+jobs:
+  include:
+    - stage: production-build
+      script: npm install --production && ./node_modules/grunt-cli/bin/grunt couchdb
+    - stage: test
+      env:
+        - COUCHDB_IMAGE=apache/couchdb:2.3.1 NIGHTWATCH_SKIPTAGS="search,partitioned"
+        - COUCHDB_IMAGE=couchdb:dev NIGHTWATCH_SKIPTAGS="search,nonpartitioned"
+        - COUCHDB_IMAGE=ibmcom/couchdb3:preview-1569600329 NIGHTWATCH_SKIPTAGS=nonpartitioned
+      before_install:
+        - npm install -g npm@latest
+        - ./bin/build-couchdb-dev.sh
+      install:
+        - npm ci
+      before_script:
+        - travis_retry ./bin/docker-up-and-check.sh
+        - curl http://127.0.0.1:5984
+        - npm run stylecheck
+        - npm test
+        - grunt debugDev
+        - DIST=./dist/debug ./bin/fauxton &
+        - sleep 30
+      script:
+        - ./node_modules/.bin/grunt nightwatch_retries
+      after_script:
+        - npm run docker:down
+      cache:
+        - apt
+        - directories:
+          - "$HOME/.npm"


[couchdb-fauxton] 02/04: WIP Jenkinsfile

Posted by wi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

willholley pushed a commit to branch nodejs-10
in repository https://gitbox.apache.org/repos/asf/couchdb-fauxton.git

commit 09a78643d6762ed72e07bf88d5a6f6df88b8824c
Author: Will Holley <wi...@gmail.com>
AuthorDate: Mon Oct 14 09:37:24 2019 +0100

    WIP Jenkinsfile
---
 Jenkinsfile | 290 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 290 insertions(+)

diff --git a/Jenkinsfile b/Jenkinsfile
new file mode 100644
index 0000000..efb4a5c
--- /dev/null
+++ b/Jenkinsfile
@@ -0,0 +1,290 @@
+#!groovy
+//
+//
+// Licensed under the Apache License, Version 2.0 (the "License"); you may not
+// use this file except in compliance with the License. You may obtain a copy of
+// the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+// License for the specific language governing permissions and limitations under
+// the License.
+
+make_packages = '''
+npm install --production && ./node_modules/grunt-cli/bin/grunt couchdb
+'''
+
+pipeline {
+
+  // no top-level agent; agents must be declared for each stage
+  agent {
+    label 'ubuntu'
+  }
+
+  environment {
+    recipient = 'notifications@couchdb.apache.org'
+  }
+
+  options {
+    buildDiscarder(logRotator(numToKeepStr: '10', artifactNumToKeepStr: '10'))
+    // This fails the build immediately if any parallel step fails
+    parallelsAlwaysFailFast()
+    preserveStashes(buildCount: 10)
+    timeout(time: 3, unit: 'HOURS')
+    timestamps()
+  }
+
+  stages {
+    parallel {
+      stage('FreeBSD') {
+        agent {
+        label 'couchdb && freebsd'
+        }
+        options {
+        skipDefaultCheckout()
+        timeout(time: 90, unit: "MINUTES")
+        }
+        steps {
+        // deleteDir is OK here because we're not inside of a Docker container!
+        deleteDir()
+        sh( script: make_packages )
+        } // steps
+      } // stage FreeBSD
+
+      stage('CentOS 6') {
+        agent {
+          docker {
+            image 'couchdbdev/centos-6-erlang-19.3.6:latest'
+            alwaysPull true
+            label 'ubuntu'
+            // this keeps builds landing on the same host from clashing with each other
+            customWorkspace pwd() + '/centos6'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('CentOS 7') {
+        agent {
+          docker {
+            image 'couchdbdev/centos-7-erlang-19.3.6:latest'
+            alwaysPull true
+            label 'ubuntu'
+            customWorkspace pwd() + '/centos7'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('Ubuntu Xenial') {
+        agent {
+          docker {
+            image 'couchdbdev/ubuntu-xenial-erlang-19.3.6:latest'
+            alwaysPull true
+            label 'ubuntu'
+            customWorkspace pwd() + '/xenial'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('Ubuntu Bionic') {
+        agent {
+          docker {
+            image 'couchdbdev/ubuntu-bionic-erlang-19.3.6:latest'
+            alwaysPull true
+            label 'ubuntu'
+            customWorkspace pwd() + '/bionic'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('Debian Jessie') {
+        agent {
+          docker {
+              image 'couchdbdev/debian-jessie-erlang-19.3.6:latest'
+              alwaysPull true
+              label 'ubuntu'
+              customWorkspace pwd() + '/jessie'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('Debian Stretch x86_64') {
+        agent {
+          docker {
+            image 'couchdbdev/debian-stretch-erlang-19.3.6:latest'
+            alwaysPull true
+            label 'ubuntu'
+            customWorkspace pwd() + '/stretch'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+
+      stage('Debian Stretch aarch64') {
+        agent {
+          docker {
+            image 'couchdbdev/aarch64-debian-stretch-erlang-20.3.8.20:latest'
+            alwaysPull true
+            label 'arm'
+            customWorkspace pwd() + '/arm'
+          }
+        }
+        options {
+          skipDefaultCheckout()
+          timeout(time: 90, unit: "MINUTES")
+        }
+        environment {
+          platform = 'centos6'
+        }
+        stages {
+          stage('Build') {
+            steps {
+              sh( script: make_packages )
+            }
+          }
+        } // stages
+        post {
+          cleanup {
+            sh 'rm -rf ${WORKSPACE}/*'
+          }
+        } // post
+      } // stage
+    } // parallel
+  } // stages
+
+  post {
+    success {
+      mail to: "${env.recipient}",
+        replyTo: "${env.recipient}",
+        subject: "[Jenkins] SUCCESS: ${currentBuild.fullDisplayName}",
+        body: "Yay, we passed. ${env.RUN_DISPLAY_URL}"
+    }
+    unstable {
+      mail to: "${env.recipient}",
+        replyTo: "${env.recipient}",
+        subject: "[Jenkins] SUCCESS: ${currentBuild.fullDisplayName}",
+        body: "Eep! Build is unstable... ${env.RUN_DISPLAY_URL}"
+    }
+    failure {
+      mail to: "${env.recipient}",
+        replyTo: "${env.recipient}",
+        subject: "[Jenkins] FAILURE: ${currentBuild.fullDisplayName}",
+        body: "Boo, we failed. ${env.RUN_DISPLAY_URL}"
+    }
+  }
+} // pipeline


[couchdb-fauxton] 01/04: Add node 10 to the CI build

Posted by wi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

willholley pushed a commit to branch nodejs-10
in repository https://gitbox.apache.org/repos/asf/couchdb-fauxton.git

commit 4775d3d899c19af3f0ef73b2b2c8576048581142
Author: Will Holley <wi...@gmail.com>
AuthorDate: Mon Oct 14 09:06:08 2019 +0100

    Add node 10 to the CI build
    
    CouchDB Docker images use nodejs 10 by default now. This adds it
    to the Travis builds so that we can verify that Fauxton will build
    on that version.
---
 .travis.yml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/.travis.yml b/.travis.yml
index a5081cf..62c27b2 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,6 +1,7 @@
 language: node_js
 node_js:
-   - "8.9"
+   - 8
+   - 10
 sudo: false
 services:
   - docker