From ef41ae732f5296cbf0a5b78494c4f0e5db2183a6 Mon Sep 17 00:00:00 2001 From: Agnes Lin Date: Mon, 18 Nov 2019 10:34:07 -0500 Subject: [PATCH] set up cloudant locally with one script --- .travis.yml | 4 +- .../repository-cloudant/docker.setup.js | 29 ++- .../repository-cloudant/package-lock.json | 213 ++++++++++++++++++ acceptance/repository-cloudant/package.json | 10 +- acceptance/repository-cloudant/setup.sh | 1 - .../src/__tests__/cloudant.datasource.ts | 4 +- package-lock.json | 163 -------------- package.json | 9 +- 8 files changed, 247 insertions(+), 186 deletions(-) rename docker.setup.js => acceptance/repository-cloudant/docker.setup.js (89%) delete mode 100644 acceptance/repository-cloudant/setup.sh diff --git a/.travis.yml b/.travis.yml index d1111ae82f75..50324e19cb13 100644 --- a/.travis.yml +++ b/.travis.yml @@ -86,10 +86,10 @@ matrix: - TASK=test-repository-cloudant script: # set up docker image and create admin for cloudant. - - npm run docker:setup - npm run postinstall -- --scope "@loopback/test-repository-cloudant" --include-dependencies - npm run build -- --scope "@loopback/test-repository-cloudant" --include-dependencies - - source cloudant-config.sh && cd acceptance/repository-cloudant && npm run mocha + - cd acceptance/repository-cloudant && run docker:setup + - source cloudant-config.sh && npm run mocha branches: only: diff --git a/docker.setup.js b/acceptance/repository-cloudant/docker.setup.js similarity index 89% rename from docker.setup.js rename to acceptance/repository-cloudant/docker.setup.js index c4552b671bc4..3450642800e9 100644 --- a/docker.setup.js +++ b/acceptance/repository-cloudant/docker.setup.js @@ -7,19 +7,23 @@ const _ = require('lodash'); const async = require('async'); -const spawn = require('child_process').spawn; const docker = new require('dockerode')(); -const fmt = require('util').format; const http = require('http'); const ms = require('ms'); const fs = require('fs-extra'); -// // we don't pass any node flags, so we can call _mocha instead the wrapper -// const mochaBin = require.resolve('mocha/bin/_mocha'); +/** + * This script creates a new couchDB3 container locally. And it also creates the admin for + * the container. Type in bash command: + * ```bash + * CLOUDANT_PASSWORD=myadmin CLOUDANT_PASSWORD=mypass CLOUDANT_DATABASE=mydb node docker.setup.sh + * ``` + * to customize the names. + */ -process.env.CLOUDANT_DATABASE = 'testdb'; -process.env.CLOUDANT_PASSWORD = 'pass'; -process.env.CLOUDANT_USERNAME = 'admin'; +process.env.CLOUDANT_DATABASE = process.env.CLOUDANT_DATABASE || 'testdb'; +process.env.CLOUDANT_PASSWORD = process.env.CLOUDANT_PASSWORD || 'pass'; +process.env.CLOUDANT_USERNAME = process.env.CLOUDANT_USERNAME || 'admin'; // these are placeholders. They get set dynamically based on what IP and port // get assigned by docker. @@ -39,7 +43,7 @@ async.waterfall( setCloudantEnv, waitFor('/_all_dbs'), createAdmin(), - createDB('testdb'), + createDB(process.env.CLOUDANT_DATABASE), listUser(), exportENV(), ], @@ -53,12 +57,14 @@ async.waterfall( function sleep(n) { return function delayedPassThrough() { + // eslint-disable-next-line prefer-rest-params const args = [].slice.call(arguments); // last argument is the callback const next = args.pop(); // prepend `null` to indicate no error args.unshift(null); setTimeout(function() { + // eslint-disable-next-line prefer-spread next.apply(null, args); }, n); }; @@ -68,6 +74,7 @@ function dockerStart(imgName) { return function pullAndStart(next) { console.log('pulling image: %s', imgName); docker.pull(imgName, function(err, stream) { + // eslint-disable-next-line no-shadow docker.modem.followProgress(stream, function(err, output) { if (err) { return next(err); @@ -80,6 +87,7 @@ function dockerStart(imgName) { PublishAllPorts: true, }, }, + // eslint-disable-next-line no-shadow function(err, container) { console.log( 'recording container for later cleanup: ', @@ -89,6 +97,7 @@ function dockerStart(imgName) { if (err) { return next(err); } + // eslint-disable-next-line no-shadow container.start(function(err, data) { next(err, container); }); @@ -164,6 +173,7 @@ function waitFor(path) { }); }) .on('error', tryAgain); + // eslint-disable-next-line no-shadow function tryAgain(err) { setTimeout(ping, CONNECT_DELAY, err, tries - 1); } @@ -173,7 +183,7 @@ function waitFor(path) { function createAdmin() { return function createAdminUser(container, next) { - const data = '"pass"'; + const data = `"${process.env.CLOUDANT_PASSWORD}"`; const uri = '/_node/couchdb@127.0.0.1/_config/admins/' + process.env.CLOUDANT_USERNAME; @@ -288,6 +298,7 @@ function exportENV() { } // clean up any previous containers +// eslint-disable-next-line @typescript-eslint/no-unused-vars function dockerCleanup(next) { if (containerToDelete) { console.log('cleaning up container: %s', containerToDelete.id); diff --git a/acceptance/repository-cloudant/package-lock.json b/acceptance/repository-cloudant/package-lock.json index 34a3162c8672..d0e9a4c548f4 100644 --- a/acceptance/repository-cloudant/package-lock.json +++ b/acceptance/repository-cloudant/package-lock.json @@ -10,6 +10,16 @@ "integrity": "sha512-RElZIr/7JreF1eY6oD5RF3kpmdcreuQPjg5ri4oQ5g9sq7YWU8HkfB3eH8GwAwxf5OaCh0VPi7r4N/yoTGelrA==", "dev": true }, + "JSONStream": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.2.tgz", + "integrity": "sha1-wQI3G27Dp887hHygDCC7D85Mbeo=", + "dev": true, + "requires": { + "jsonparse": "^1.2.0", + "through": ">=2.2.7 <3" + } + }, "accept-language": { "version": "3.0.18", "resolved": "https://registry.npmjs.org/accept-language/-/accept-language-3.0.18.tgz", @@ -133,6 +143,34 @@ "integrity": "sha1-ns5bWsqJopkyJC4Yv5M975h2zBc=", "dev": true }, + "buffer-alloc": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/buffer-alloc/-/buffer-alloc-1.2.0.tgz", + "integrity": "sha512-CFsHQgjtW1UChdXgbyJGtnm+O/uLQeZdtbDo8mfUgYXCHSM1wgrVxXm6bSyrUuErEb+4sYVGCzASBRot7zyrow==", + "dev": true, + "requires": { + "buffer-alloc-unsafe": "^1.1.0", + "buffer-fill": "^1.0.0" + } + }, + "buffer-alloc-unsafe": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/buffer-alloc-unsafe/-/buffer-alloc-unsafe-1.1.0.tgz", + "integrity": "sha512-TEM2iMIEQdJ2yjPJoSIsldnleVaAk1oW3DBVUykyOLsEsFmEc9kn+SFFPz+gl54KQNxlDnAwCXosOS9Okx2xAg==", + "dev": true + }, + "buffer-fill": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-fill/-/buffer-fill-1.0.0.tgz", + "integrity": "sha1-+PeLdniYiO858gXNY39o5wISKyw=", + "dev": true + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "dev": true + }, "caseless": { "version": "0.12.0", "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", @@ -145,6 +183,12 @@ "integrity": "sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc=", "dev": true }, + "chownr": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.3.tgz", + "integrity": "sha512-i70fVHhmV3DtTl6nqvZOnIjbY0Pe4kAUjwHj8z0zAdgBtYrJyYwLKCCuRBQ5ppkyL0AkN7HKRnETdmdp1zqNXw==", + "dev": true + }, "cldrjs": { "version": "0.5.1", "resolved": "https://registry.npmjs.org/cldrjs/-/cldrjs-0.5.1.tgz", @@ -233,6 +277,18 @@ "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", "dev": true }, + "concat-stream": { + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", + "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^2.2.2", + "typedarray": "^0.0.6" + } + }, "core-util-is": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", @@ -282,6 +338,64 @@ "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", "dev": true }, + "docker-modem": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/docker-modem/-/docker-modem-1.0.9.tgz", + "integrity": "sha512-lVjqCSCIAUDZPAZIeyM125HXfNvOmYYInciphNrLrylUtKyW66meAjSPXWchKVzoIYZx69TPnAepVSSkeawoIw==", + "dev": true, + "requires": { + "JSONStream": "1.3.2", + "debug": "^3.2.6", + "readable-stream": "~1.0.26-4", + "split-ca": "^1.0.0" + }, + "dependencies": { + "debug": { + "version": "3.2.6", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", + "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + } + } + }, + "dockerode": { + "version": "2.5.8", + "resolved": "https://registry.npmjs.org/dockerode/-/dockerode-2.5.8.tgz", + "integrity": "sha512-+7iOUYBeDTScmOmQqpUYQaE7F4vvIt6+gIZNHWhqAQEI887tiPFB9OvXI/HzQYqfUNvukMK+9myLW63oTJPZpw==", + "dev": true, + "requires": { + "concat-stream": "~1.6.2", + "docker-modem": "^1.0.8", + "tar-fs": "~1.16.3" + } + }, "ecc-jsbn": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", @@ -363,6 +477,12 @@ "mime-types": "^2.1.12" } }, + "fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", + "dev": true + }, "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", @@ -519,6 +639,12 @@ "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", "dev": true }, + "jsonparse": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", + "integrity": "sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA=", + "dev": true + }, "jsprim": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", @@ -1027,6 +1153,12 @@ "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true }, + "split-ca": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/split-ca/-/split-ca-1.0.1.tgz", + "integrity": "sha1-bIOv82kvphJW4M0ZfgXp3hV2kaY=", + "dev": true + }, "sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -1095,6 +1227,69 @@ "yamljs": "^0.3.0" } }, + "tar-fs": { + "version": "1.16.3", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-1.16.3.tgz", + "integrity": "sha512-NvCeXpYx7OsmOh8zIOP/ebG55zZmxLE0etfWRbWok+q2Qo8x/vOR/IJT1taADXPe+jsiu9axDb3X4B+iIgNlKw==", + "dev": true, + "requires": { + "chownr": "^1.0.1", + "mkdirp": "^0.5.1", + "pump": "^1.0.0", + "tar-stream": "^1.1.2" + }, + "dependencies": { + "pump": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/pump/-/pump-1.0.3.tgz", + "integrity": "sha512-8k0JupWme55+9tCVE+FS5ULT3K6AbgqrGa58lTT49RpyfwwcGedHqaC5LlQNdEAumn/wFsu6aPwkuPMioy8kqw==", + "dev": true, + "requires": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + } + } + }, + "tar-stream": { + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-1.6.2.tgz", + "integrity": "sha512-rzS0heiNf8Xn7/mpdSVVSMAWAoy9bfb1WOTYC78Z0UQKeKa/CWS8FOq0lKGNa8DWKAn9gxjCvMLYc5PGXYlK2A==", + "dev": true, + "requires": { + "bl": "^1.0.0", + "buffer-alloc": "^1.2.0", + "end-of-stream": "^1.0.0", + "fs-constants": "^1.0.0", + "readable-stream": "^2.3.0", + "to-buffer": "^1.1.1", + "xtend": "^4.0.0" + }, + "dependencies": { + "bl": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/bl/-/bl-1.2.2.tgz", + "integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==", + "dev": true, + "requires": { + "readable-stream": "^2.3.5", + "safe-buffer": "^5.1.1" + } + } + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "to-buffer": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/to-buffer/-/to-buffer-1.1.1.tgz", + "integrity": "sha512-lx9B5iv7msuFYE3dytT+KE5tap+rNYw+K4jVkb9R/asAb+pbBSM17jtunHplhBe6RRJdZx3Pn2Jph24O32mOVg==", + "dev": true + }, "tough-cookie": { "version": "2.4.3", "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", @@ -1128,6 +1323,18 @@ "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", "dev": true }, + "typedarray": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz", + "integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=", + "dev": true + }, + "typescript": { + "version": "3.7.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.7.2.tgz", + "integrity": "sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ==", + "dev": true + }, "underscore": { "version": "1.9.1", "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.9.1.tgz", @@ -1181,6 +1388,12 @@ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, + "xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "dev": true + }, "yamljs": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/yamljs/-/yamljs-0.3.0.tgz", diff --git a/acceptance/repository-cloudant/package.json b/acceptance/repository-cloudant/package.json index 60356e6c09d6..e8d45781958d 100644 --- a/acceptance/repository-cloudant/package.json +++ b/acceptance/repository-cloudant/package.json @@ -12,7 +12,8 @@ "pretest": "npm run build", "test": "npm run mocha", "mocha": "lb-mocha \"dist/__tests__/**/*.js\"", - "verify": "npm pack && tar xf loopback-test-repository-cloudant*.tgz && tree package && npm run clean" + "verify": "npm pack && tar xf loopback-test-repository-cloudant*.tgz && tree package && npm run clean", + "docker:setup": "node ./docker.setup.js" }, "author": "IBM Corp.", "copyright.owner": "IBM Corp.", @@ -23,7 +24,12 @@ "@loopback/repository": "^1.15.2", "@loopback/repository-tests": "^0.6.1", "@types/node": "^10.17.5", - "loopback-connector-cloudant": "2.3.2" + "loopback-connector-cloudant": "2.3.2", + "typescript": "~3.7.2", + "async": "^3.1.0", + "debug": "^4.1.1", + "lodash": "^4.17.11", + "dockerode": "^2.4.3" }, "files": [ "README.md", diff --git a/acceptance/repository-cloudant/setup.sh b/acceptance/repository-cloudant/setup.sh deleted file mode 100644 index 34f115b82f47..000000000000 --- a/acceptance/repository-cloudant/setup.sh +++ /dev/null @@ -1 +0,0 @@ -source ./node_modules/loopback-connector-cloudant/setup.sh diff --git a/acceptance/repository-cloudant/src/__tests__/cloudant.datasource.ts b/acceptance/repository-cloudant/src/__tests__/cloudant.datasource.ts index 973816b8bb68..4b8cfec19509 100644 --- a/acceptance/repository-cloudant/src/__tests__/cloudant.datasource.ts +++ b/acceptance/repository-cloudant/src/__tests__/cloudant.datasource.ts @@ -10,11 +10,11 @@ const connector = require('loopback-connector-cloudant'); export const CLOUDANT_CONFIG: DataSourceOptions = { connector, host: process.env.CLOUDANT_HOST || 'localhost', - port: process.env.CLOUDANT_PORT || 8080, + port: process.env.CLOUDANT_PORT || 5984, username: process.env.CLOUDANT_USER || 'admin', password: process.env.CLOUDANT_PASSWORD || 'pass', database: process.env.CLOUDANT_DATABASE || 'repository_tests', - url: process.env.CLOUDANT_URL || 'http://localhost:8080', + url: process.env.CLOUDANT_URL || 'http://localhost:5984', }; export const CLOUDANT_FEATURES: Partial = { diff --git a/package-lock.json b/package-lock.json index 6dc12a1e1fec..587ee03a9cf9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1810,12 +1810,6 @@ "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", "dev": true }, - "async": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/async/-/async-3.1.0.tgz", - "integrity": "sha512-4vx/aaY6j/j3Lw3fbCHNWP0pPaTCew3F6F3hYyl/tHs/ndmV1q7NW9T5yuJ2XAGwdQrP+6Wu20x06U4APo/iQQ==", - "dev": true - }, "asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", @@ -1951,16 +1945,6 @@ "integrity": "sha512-IWIbu7pMqyw3EAJHzzHbWa85b6oud/yfKYg5rqB5hNE8CeMi3nX+2C2sj0HswfblST86hpVEOAb9x34NZd6P7A==", "dev": true }, - "bl": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/bl/-/bl-1.2.2.tgz", - "integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==", - "dev": true, - "requires": { - "readable-stream": "^2.3.5", - "safe-buffer": "^5.1.1" - } - }, "bluebird": { "version": "3.7.1", "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.1.tgz", @@ -2012,28 +1996,6 @@ "integrity": "sha1-M3dm2hWAEhD92VbCLpxokaudAzc=", "dev": true }, - "buffer-alloc": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/buffer-alloc/-/buffer-alloc-1.2.0.tgz", - "integrity": "sha512-CFsHQgjtW1UChdXgbyJGtnm+O/uLQeZdtbDo8mfUgYXCHSM1wgrVxXm6bSyrUuErEb+4sYVGCzASBRot7zyrow==", - "dev": true, - "requires": { - "buffer-alloc-unsafe": "^1.1.0", - "buffer-fill": "^1.0.0" - } - }, - "buffer-alloc-unsafe": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/buffer-alloc-unsafe/-/buffer-alloc-unsafe-1.1.0.tgz", - "integrity": "sha512-TEM2iMIEQdJ2yjPJoSIsldnleVaAk1oW3DBVUykyOLsEsFmEc9kn+SFFPz+gl54KQNxlDnAwCXosOS9Okx2xAg==", - "dev": true - }, - "buffer-fill": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/buffer-fill/-/buffer-fill-1.0.0.tgz", - "integrity": "sha1-+PeLdniYiO858gXNY39o5wISKyw=", - "dev": true - }, "buffer-from": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", @@ -3118,74 +3080,6 @@ "path-type": "^3.0.0" } }, - "docker-modem": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/docker-modem/-/docker-modem-1.0.9.tgz", - "integrity": "sha512-lVjqCSCIAUDZPAZIeyM125HXfNvOmYYInciphNrLrylUtKyW66meAjSPXWchKVzoIYZx69TPnAepVSSkeawoIw==", - "dev": true, - "requires": { - "JSONStream": "1.3.2", - "debug": "^3.2.6", - "readable-stream": "~1.0.26-4", - "split-ca": "^1.0.0" - }, - "dependencies": { - "JSONStream": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.2.tgz", - "integrity": "sha1-wQI3G27Dp887hHygDCC7D85Mbeo=", - "dev": true, - "requires": { - "jsonparse": "^1.2.0", - "through": ">=2.2.7 <3" - } - }, - "debug": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", - "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "isarray": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", - "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", - "dev": true - }, - "readable-stream": { - "version": "1.0.34", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", - "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", - "dev": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.1", - "isarray": "0.0.1", - "string_decoder": "~0.10.x" - } - }, - "string_decoder": { - "version": "0.10.31", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", - "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", - "dev": true - } - } - }, - "dockerode": { - "version": "2.5.8", - "resolved": "https://registry.npmjs.org/dockerode/-/dockerode-2.5.8.tgz", - "integrity": "sha512-+7iOUYBeDTScmOmQqpUYQaE7F4vvIt6+gIZNHWhqAQEI887tiPFB9OvXI/HzQYqfUNvukMK+9myLW63oTJPZpw==", - "dev": true, - "requires": { - "concat-stream": "~1.6.2", - "docker-modem": "^1.0.8", - "tar-fs": "~1.16.3" - } - }, "doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", @@ -4007,12 +3901,6 @@ "readable-stream": "^2.0.0" } }, - "fs-constants": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", - "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", - "dev": true - }, "fs-extra": { "version": "8.1.0", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", @@ -7338,12 +7226,6 @@ "through": "2" } }, - "split-ca": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/split-ca/-/split-ca-1.0.1.tgz", - "integrity": "sha1-bIOv82kvphJW4M0ZfgXp3hV2kaY=", - "dev": true - }, "split-string": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", @@ -7588,45 +7470,6 @@ "yallist": "^3.0.3" } }, - "tar-fs": { - "version": "1.16.3", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-1.16.3.tgz", - "integrity": "sha512-NvCeXpYx7OsmOh8zIOP/ebG55zZmxLE0etfWRbWok+q2Qo8x/vOR/IJT1taADXPe+jsiu9axDb3X4B+iIgNlKw==", - "dev": true, - "requires": { - "chownr": "^1.0.1", - "mkdirp": "^0.5.1", - "pump": "^1.0.0", - "tar-stream": "^1.1.2" - }, - "dependencies": { - "pump": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/pump/-/pump-1.0.3.tgz", - "integrity": "sha512-8k0JupWme55+9tCVE+FS5ULT3K6AbgqrGa58lTT49RpyfwwcGedHqaC5LlQNdEAumn/wFsu6aPwkuPMioy8kqw==", - "dev": true, - "requires": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - } - } - }, - "tar-stream": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-1.6.2.tgz", - "integrity": "sha512-rzS0heiNf8Xn7/mpdSVVSMAWAoy9bfb1WOTYC78Z0UQKeKa/CWS8FOq0lKGNa8DWKAn9gxjCvMLYc5PGXYlK2A==", - "dev": true, - "requires": { - "bl": "^1.0.0", - "buffer-alloc": "^1.2.0", - "end-of-stream": "^1.0.0", - "fs-constants": "^1.0.0", - "readable-stream": "^2.3.0", - "to-buffer": "^1.1.1", - "xtend": "^4.0.0" - } - }, "temp-dir": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/temp-dir/-/temp-dir-1.0.0.tgz", @@ -7702,12 +7545,6 @@ "os-tmpdir": "~1.0.2" } }, - "to-buffer": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/to-buffer/-/to-buffer-1.1.1.tgz", - "integrity": "sha512-lx9B5iv7msuFYE3dytT+KE5tap+rNYw+K4jVkb9R/asAb+pbBSM17jtunHplhBe6RRJdZx3Pn2Jph24O32mOVg==", - "dev": true - }, "to-object-path": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/to-object-path/-/to-object-path-0.3.0.tgz", diff --git a/package.json b/package.json index 58063d3b5905..c3dbb08a230f 100644 --- a/package.json +++ b/package.json @@ -26,11 +26,7 @@ "fs-extra": "^8.1.0", "husky": "^3.0.9", "lerna": "^3.18.4", - "typescript": "~3.7.2", - "async": "^3.1.0", - "debug": "^4.1.1", - "lodash": "^4.17.11", - "dockerode": "^2.4.3" + "typescript": "~3.7.2" }, "scripts": { "postinstall": "lerna bootstrap", @@ -66,8 +62,7 @@ "docs:prepare": "./docs/bin/build-preview-site.sh", "docs:start": "cd docs/_preview && bundle exec jekyll serve --no-w --i", "mocha": "node packages/build/bin/run-mocha \"packages/*/dist/__tests__/**/*.js\" \"extensions/*/dist/__tests__/**/*.js\" \"examples/*/dist/__tests__/**/*.js\" \"packages/cli/test/**/*.js\" \"packages/build/test/*/*.js\"", - "posttest": "npm run lint", - "docker:setup": "node ./docker.setup.js" + "posttest": "npm run lint" }, "config": { "commitizen": {