@wocker/mongodb-plugin 1.0.10 → 1.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -108,7 +108,8 @@ let MongodbService = class MongodbService {
108
108
  imageName: props.imageName,
109
109
  imageVersion: props.imageVersion,
110
110
  username: props.username,
111
- password: props.password
111
+ password: props.password,
112
+ containerPort: props.containerPort
112
113
  });
113
114
  this.config.setDatabase(database);
114
115
  this.config.save();
@@ -308,6 +309,9 @@ let MongodbService = class MongodbService {
308
309
  "--archive",
309
310
  "--gzip"
310
311
  ], false);
312
+ if (!stream) {
313
+ return;
314
+ }
311
315
  stream.on("data", (chunk) => {
312
316
  fileStream.write((0, utils_1.demuxOutput)(chunk));
313
317
  });
@@ -404,6 +408,9 @@ let MongodbService = class MongodbService {
404
408
  "--gzip",
405
409
  "--archive"
406
410
  ], false);
411
+ if (!stream) {
412
+ return;
413
+ }
407
414
  yield new Promise((resolve, reject) => {
408
415
  file.on("data", (data) => {
409
416
  stream.write(data);
@@ -431,6 +438,9 @@ let MongodbService = class MongodbService {
431
438
  "--quiet",
432
439
  "--eval", "db.getMongo().getDBNames().forEach(function(i){print(i)})"
433
440
  ], false);
441
+ if (!stream) {
442
+ return [];
443
+ }
434
444
  const res = yield new Promise((resolve, reject) => {
435
445
  let res = "";
436
446
  stream.on("data", (chunk) => {
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@wocker/mongodb-plugin",
3
- "version": "1.0.10",
3
+ "type": "commonjs",
4
+ "version": "1.0.12",
4
5
  "author": "Kris Papercut <krispcut@gmail.com>",
5
6
  "description": "Mongodb plugin for wocker",
6
7
  "license": "MIT",