You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by ho...@apache.org on 2018/08/22 18:04:41 UTC

[incubator-openwhisk-package-alarms] branch master updated: Add the code scanning check-up (#159)

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

houshengbo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-package-alarms.git


The following commit(s) were added to refs/heads/master by this push:
     new d59ee2c  Add the code scanning check-up (#159)
d59ee2c is described below

commit d59ee2c00730c46c7f391ad954346ed807f2cc07
Author: Vincent <sh...@us.ibm.com>
AuthorDate: Wed Aug 22 14:04:38 2018 -0400

    Add the code scanning check-up (#159)
---
 .travis.yml                              | 17 +++++++++++-
 CONTRIBUTING.md                          | 31 +++++++++++----------
 README.md                                | 47 ++++++++++++++++++++++----------
 action/alarm.js                          |  3 ++
 action/alarmWebAction.js                 |  3 ++
 action/lib/Database.js                   |  3 ++
 action/lib/common.js                     |  3 ++
 action/lib/config.js                     |  3 ++
 gradle/wrapper/gradle-wrapper.properties |  3 ++
 installCatalog.sh                        | 17 ++++++++++++
 provider/Logger.js                       |  3 ++
 provider/app.js                          |  3 ++
 provider/lib/active.js                   |  3 ++
 provider/lib/authHandler.js              |  3 ++
 provider/lib/constants.js                |  3 ++
 provider/lib/cronAlarm.js                |  3 ++
 provider/lib/dateAlarm.js                |  3 ++
 provider/lib/health.js                   |  3 ++
 provider/lib/intervalAlarm.js            |  3 ++
 provider/lib/ras.js                      |  3 ++
 provider/lib/sanitizer.js                |  3 +-
 provider/lib/utils.js                    |  3 ++
 tools/travis/build.sh                    | 25 +++++++++++++++--
 tools/travis/deploy.sh                   | 17 ++++++++++++
 tools/travis/setup.sh                    | 45 ++++++++++++------------------
 25 files changed, 193 insertions(+), 60 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index d30ce44..4bb2ae3 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,4 +1,19 @@
-# A Travis CI configuration file.
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
 
 sudo: required
 group: deprecated-2017Q3
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index c32a97e..ab2f597 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,18 +1,19 @@
 <!--
 #
-# Licensed to the Apache Software Foundation (ASF) under one or more contributor 
-# license agreements.  See the NOTICE file distributed with this work for additional 
-# information regarding copyright ownership.  The ASF licenses this file to you
-# 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:
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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
+#     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.
+# 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.
 #
 -->
 
@@ -35,18 +36,18 @@ Instructions on how to do this can be found here:
 [http://www.apache.org/licenses/#clas](http://www.apache.org/licenses/#clas)
 
 Once submitted, you will receive a confirmation email from the Apache Software Foundation (ASF) and be added to
-the following list: http://people.apache.org/unlistedclas.html. 
+the following list: http://people.apache.org/unlistedclas.html.
 
 Project committers will use this list to verify pull requests (PRs) come from contributors that have signed a CLA.
 
-We look forward to your contributions! 
+We look forward to your contributions!
 
 ## Raising issues
 
-Please raise any bug reports on the respective project repository's GitHub issue tracker. Be sure to search the 
+Please raise any bug reports on the respective project repository's GitHub issue tracker. Be sure to search the
 list to see if your issue has already been raised.
 
-A good bug report is one that make it easy for us to understand what you were trying to do and what went wrong. 
+A good bug report is one that make it easy for us to understand what you were trying to do and what went wrong.
 Provide as much context as possible so we can try to recreate the issue.
 
 ### Discussion
diff --git a/README.md b/README.md
index 466feaf..e73f7ed 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,22 @@
+<!--
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
+-->
+
 # Using the Alarm package
 
 [![License](https://img.shields.io/badge/license-Apache--2.0-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0)
@@ -23,7 +42,7 @@ The `/whisk.system/alarms/interval` feed configures the Alarm service to fire a
 
 - `trigger_payload` (*optional*): The value of this parameter becomes the content of the Trigger every time the Trigger is fired.
 
-- `startDate` (*optional*): The date when the first trigger will be fired.  Subsequent fires will occur based on the interval length specified by the `minutes` parameter.   
+- `startDate` (*optional*): The date when the first trigger will be fired.  Subsequent fires will occur based on the interval length specified by the `minutes` parameter.
 
 - `stopDate` (*optional*): The date when the Trigger will stop running.  Triggers will no longer be fired once this date has been reached.
 
@@ -38,26 +57,26 @@ The following example creates a trigger that is fired once every 2 minutes. The
     --param trigger_payload "{\"name\":\"Odin\",\"place\":\"Asgard\"}" \
     --param stopDate "2019-01-31T23:59:00.000Z"
   ```
-  
+
 Each generated event includes parameters, which are the properties that are specified by the `trigger_payload` value. In this case, each Trigger event has the parameters `name=Odin` and `place=Asgard`.
 
-## Firing a trigger event once  
+## Firing a trigger event once
 
 The `/whisk.system/alarms/once` feed configures the Alarm service to fire a trigger event on a specified date. The parameters are as follows:
 
-- `date` (*required*): The date when the Trigger will be fired.  The Trigger will be fired just once at the given time. 
+- `date` (*required*): The date when the Trigger will be fired.  The Trigger will be fired just once at the given time.
 
-  **Note**: The `date` parameter supports an integer or string value.  The integer value represents the number of milliseconds 
+  **Note**: The `date` parameter supports an integer or string value.  The integer value represents the number of milliseconds
   since 1 January 1970 00:00:00 UTC and the string value should be in the ISO 8601 format (http://www.ecma-international.org/ecma-262/5.1/#sec-15.9.1.15).
 
-- `trigger_payload` (*optional*): The value of this parameter becomes the content of the Trigger when the Trigger is fired. 
+- `trigger_payload` (*optional*): The value of this parameter becomes the content of the Trigger when the Trigger is fired.
 
-- `deleteAfterFire` (*optional*, default: false): The value of this parameter determines whether the Trigger and potentially all of its associated rules will be deleted after the Trigger is fired.  
-  - `false`: No action will be taken after the Trigger fires. 
-  - `true`: The Trigger will be deleted after it fires. 
+- `deleteAfterFire` (*optional*, default: false): The value of this parameter determines whether the Trigger and potentially all of its associated rules will be deleted after the Trigger is fired.
+  - `false`: No action will be taken after the Trigger fires.
+  - `true`: The Trigger will be deleted after it fires.
   - `rules`: The Trigger and all of its associated rules will be deleted after it fires.
 
-The following is an example of creating a trigger that will be fired once on December 25, 2019, 12:30:00 UTC.  After the Trigger fires it will be deleted as well as all of its associated rules.  
+The following is an example of creating a trigger that will be fired once on December 25, 2019, 12:30:00 UTC.  After the Trigger fires it will be deleted as well as all of its associated rules.
 
   ```
   wsk trigger create fireOnce \
@@ -65,7 +84,7 @@ The following is an example of creating a trigger that will be fired once on Dec
     --param trigger_payload "{\"name\":\"Odin\",\"place\":\"Asgard\"}" \
     --param date "2019-12-25T12:30:00.000Z" \
     --param deleteAfterFire "rules"
-  ``` 
+  ```
 
 ## Firing a Trigger on a time-based schedule using cron
 
@@ -78,15 +97,15 @@ For more information, see: http://crontab.org. The following strings are example
   - `0 * * * *`: The Trigger fires at the top of every hour.
   - `0 */2 * * *`: The Trigger fires every 2 hours (that is, 02:00:00, 04:00:00, ...).
   - `0 9 8 * *`: The Trigger fires at 9:00:00AM (UTC) on the eighth day of every month.
-  
+
   **Note**: The parameter `cron` supports five or six fields.  Not all OpenWhisk vendors may support 6 fields so please check their documentation for support.
   For more details about using this custom cron syntax, see: https://github.com/ncb000gt/node-cron.
   Here is an example using six fields notation:
     - `*/30 * * * * *`: every thirty seconds.
-    
+
 - `trigger_payload` (*optional*): The value of this parameter becomes the content of the Trigger every time the Trigger is fired.
 
-- `startDate` (*optional*): The date when the Trigger will start running. The Trigger fires based on the schedule specified by the cron parameter.  
+- `startDate` (*optional*): The date when the Trigger will start running. The Trigger fires based on the schedule specified by the cron parameter.
 
 - `stopDate` (*optional*): The date when the Trigger will stop running. Triggers are no longer fired once this date is reached.
 
diff --git a/action/alarm.js b/action/alarm.js
index 9467ece..0c39587 100644
--- a/action/alarm.js
+++ b/action/alarm.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 const common = require('./lib/common');
 
 function main(msg) {
diff --git a/action/alarmWebAction.js b/action/alarmWebAction.js
index 8383578..8209783 100644
--- a/action/alarmWebAction.js
+++ b/action/alarmWebAction.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 const CronJob = require('cron').CronJob;
 const moment = require('moment');
 const common = require('./lib/common');
diff --git a/action/lib/Database.js b/action/lib/Database.js
index 236f2f5..41dad5d 100644
--- a/action/lib/Database.js
+++ b/action/lib/Database.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 const common = require('./common');
 
 // constructor for DB object - a thin, promise-loving wrapper around nano
diff --git a/action/lib/common.js b/action/lib/common.js
index 9480fb5..9f98fbe 100644
--- a/action/lib/common.js
+++ b/action/lib/common.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 const request = require('request');
 const openwhisk = require('openwhisk');
 const config = require('./config');
diff --git a/action/lib/config.js b/action/lib/config.js
index 550f42a..0b58bed 100644
--- a/action/lib/config.js
+++ b/action/lib/config.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 function getOpenWhiskConfig(triggerData) {
     return {ignore_certs: true, namespace: triggerData.namespace, api_key: triggerData.apikey};
 }
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index f16d266..d7cc33f 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,3 +1,6 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more contributor
+# license agreements; and to You under the Apache License, Version 2.0.
+
 distributionBase=GRADLE_USER_HOME
 distributionPath=wrapper/dists
 zipStoreBase=GRADLE_USER_HOME
diff --git a/installCatalog.sh b/installCatalog.sh
index ca6c150..01dff74 100755
--- a/installCatalog.sh
+++ b/installCatalog.sh
@@ -1,5 +1,22 @@
 #!/bin/bash
 #
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
+
+#
 # use the command line interface to install standard actions deployed
 # automatically
 #
diff --git a/provider/Logger.js b/provider/Logger.js
index d234edc..4d4acf7 100644
--- a/provider/Logger.js
+++ b/provider/Logger.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var _ = require('lodash');
 var moment = require('moment');
 var winston = require('winston');
diff --git a/provider/app.js b/provider/app.js
index d4df969..3cc3acf 100755
--- a/provider/app.js
+++ b/provider/app.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 'use strict';
 /**
  * Service which can be configured to listen for triggers from a provider.
diff --git a/provider/lib/active.js b/provider/lib/active.js
index 510a0a2..c9f2942 100644
--- a/provider/lib/active.js
+++ b/provider/lib/active.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 module.exports = function(logger, utils) {
 
   // Active Endpoint
diff --git a/provider/lib/authHandler.js b/provider/lib/authHandler.js
index 9e25242..8ec79a9 100644
--- a/provider/lib/authHandler.js
+++ b/provider/lib/authHandler.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 function handleAuth(triggerData) {
 
     var auth = triggerData.apikey.split(':');
diff --git a/provider/lib/constants.js b/provider/lib/constants.js
index dca9352..522fad5 100644
--- a/provider/lib/constants.js
+++ b/provider/lib/constants.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 const TRIGGER_DB_SUFFIX = 'alarmservice';
 const DEFAULT_MAX_TRIGGERS = -1;
 const RETRY_ATTEMPTS = 10;
diff --git a/provider/lib/cronAlarm.js b/provider/lib/cronAlarm.js
index 42d3150..b811ce1 100644
--- a/provider/lib/cronAlarm.js
+++ b/provider/lib/cronAlarm.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var CronJob = require('cron').CronJob;
 var lt =  require('long-timeout');
 var constants = require('./constants.js');
diff --git a/provider/lib/dateAlarm.js b/provider/lib/dateAlarm.js
index 247ef03..921ebcf 100644
--- a/provider/lib/dateAlarm.js
+++ b/provider/lib/dateAlarm.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var CronJob = require('cron').CronJob;
 
 module.exports = function(logger, newTrigger) {
diff --git a/provider/lib/health.js b/provider/lib/health.js
index e0210ca..a318591 100644
--- a/provider/lib/health.js
+++ b/provider/lib/health.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var si = require('systeminformation');
 var v8 = require('v8');
 var _ = require('lodash');
diff --git a/provider/lib/intervalAlarm.js b/provider/lib/intervalAlarm.js
index f3f6540..34d2cf9 100644
--- a/provider/lib/intervalAlarm.js
+++ b/provider/lib/intervalAlarm.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var lt =  require('long-timeout');
 
 module.exports = function(logger, newTrigger) {
diff --git a/provider/lib/ras.js b/provider/lib/ras.js
index 2b7d352..d3113c6 100644
--- a/provider/lib/ras.js
+++ b/provider/lib/ras.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 module.exports = function() {
 
   // Test Endpoint
diff --git a/provider/lib/sanitizer.js b/provider/lib/sanitizer.js
index 982cfab..62791f3 100644
--- a/provider/lib/sanitizer.js
+++ b/provider/lib/sanitizer.js
@@ -1,4 +1,5 @@
-
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
 
 module.exports = function(logger, utils) {
 
diff --git a/provider/lib/utils.js b/provider/lib/utils.js
index e443d49..1ebe486 100644
--- a/provider/lib/utils.js
+++ b/provider/lib/utils.js
@@ -1,3 +1,6 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
 var request = require('request');
 var HttpStatus = require('http-status-codes');
 var lt =  require('long-timeout');
diff --git a/tools/travis/build.sh b/tools/travis/build.sh
index fe7a4ec..8525d95 100755
--- a/tools/travis/build.sh
+++ b/tools/travis/build.sh
@@ -1,4 +1,21 @@
 #!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
+
 set -e
 
 # Build script for Travis-CI.
@@ -9,8 +26,12 @@ UTILDIR="$ROOTDIR/../incubator-openwhisk-utilities"
 
 # run scancode
 cd $UTILDIR
-scancode/scanCode.py $ROOTDIR
+scancode/scanCode.py --config scancode/ASF-Release.cfg $ROOTDIR
+
+# jshint support
+sudo apt-get -y install nodejs npm
+sudo npm install -g jshint
 
 # run jshint
 cd $ROOTDIR
-jshint --exclude tests .
\ No newline at end of file
+jshint --exclude tests .
diff --git a/tools/travis/deploy.sh b/tools/travis/deploy.sh
index 6451c37..adc5c9d 100755
--- a/tools/travis/deploy.sh
+++ b/tools/travis/deploy.sh
@@ -1,4 +1,21 @@
 #!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
+
 set -eu
 
 dockerhub_image_prefix="$1"
diff --git a/tools/travis/setup.sh b/tools/travis/setup.sh
index b0bab04..6dcffac 100755
--- a/tools/travis/setup.sh
+++ b/tools/travis/setup.sh
@@ -1,40 +1,31 @@
 #!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+#
 
 SCRIPTDIR=$(cd $(dirname "$0") && pwd)
 HOMEDIR="$SCRIPTDIR/../../../"
-WHISKDIR="$HOMEDIR/openwhisk"
 
-sudo gpasswd -a travis docker
-sudo -E bash -c 'echo '\''DOCKER_OPTS="-H tcp://0.0.0.0:4243 -H unix:///var/run/docker.sock --api-enable-cors --storage-driver=aufs"'\'' > /etc/default/docker'
-
-# Docker
-sudo apt-get -y update -qq
-sudo apt-get -o Dpkg::Options::="--force-confold" --force-yes -y install docker-engine=1.12.0-0~trusty
-sudo service docker restart
-echo "Docker Version:"
-docker version
-echo "Docker Info:"
-docker info
-
-# Python
-sudo apt-get -y install python-pip
-pip install --user jsonschema
-
-# Ansible
-pip install --user ansible==2.1.2.0
-
-# jshint support
-sudo apt-get -y install nodejs npm
-sudo npm install -g jshint
-
-# clone OpenWhisk repo. in order to run scanCode.py
 cd $HOMEDIR
 git clone https://github.com/apache/incubator-openwhisk-utilities.git
 
-# OpenWhisk stuff
 cd $HOMEDIR
 git clone https://github.com/apache/incubator-openwhisk.git openwhisk
-cd $WHISKDIR
+cd $HOMEDIR/openwhisk
+./tools/travis/setup.sh
 
 TERM=dumb ./gradlew \
 :common:scala:install \