@cloudsnorkel/cdk-github-runners 0.13.1 → 0.13.3

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.
Files changed (39) hide show
  1. package/.jsii +169 -113
  2. package/API.md +41 -0
  3. package/assets/delete-failed-runner.lambda/index.js +62 -703
  4. package/assets/idle-runner-repear.lambda/index.js +62 -703
  5. package/assets/image-builders/aws-image-builder/versioner.lambda/index.js +51 -653
  6. package/assets/setup.lambda/index.js +19 -38
  7. package/assets/status.lambda/index.js +62 -703
  8. package/assets/token-retriever.lambda/index.js +62 -703
  9. package/assets/webhook-handler.lambda/index.js +62 -703
  10. package/lib/access.js +1 -1
  11. package/lib/image-builders/api.js +1 -1
  12. package/lib/image-builders/aws-image-builder/builder.d.ts +1 -0
  13. package/lib/image-builders/aws-image-builder/builder.js +22 -2
  14. package/lib/image-builders/aws-image-builder/common.d.ts +1 -1
  15. package/lib/image-builders/aws-image-builder/common.js +2 -1
  16. package/lib/image-builders/aws-image-builder/deprecated/ami.js +1 -1
  17. package/lib/image-builders/aws-image-builder/deprecated/container.js +1 -1
  18. package/lib/image-builders/aws-image-builder/deprecated/linux-components.js +1 -1
  19. package/lib/image-builders/aws-image-builder/deprecated/windows-components.js +1 -1
  20. package/lib/image-builders/aws-image-builder/versioner.lambda.js +15 -1
  21. package/lib/image-builders/aws-image-builder/workflow.d.ts +36 -0
  22. package/lib/image-builders/aws-image-builder/workflow.js +100 -0
  23. package/lib/image-builders/codebuild-deprecated.js +1 -1
  24. package/lib/image-builders/codebuild.d.ts +1 -0
  25. package/lib/image-builders/codebuild.js +8 -2
  26. package/lib/image-builders/common.d.ts +10 -0
  27. package/lib/image-builders/common.js +1 -1
  28. package/lib/image-builders/components.d.ts +10 -0
  29. package/lib/image-builders/components.js +35 -2
  30. package/lib/image-builders/static.js +1 -1
  31. package/lib/providers/codebuild.js +13 -3
  32. package/lib/providers/common.js +3 -3
  33. package/lib/providers/ec2.js +18 -15
  34. package/lib/providers/ecs.js +1 -1
  35. package/lib/providers/fargate.js +2 -2
  36. package/lib/providers/lambda.js +2 -2
  37. package/lib/runner.js +1 -1
  38. package/lib/secrets.js +1 -1
  39. package/package.json +15 -15
@@ -205,14 +205,11 @@ var require_is_plain_object = __commonJS({
205
205
  }
206
206
  function isPlainObject(o) {
207
207
  var ctor, prot;
208
- if (isObject(o) === false)
209
- return false;
208
+ if (isObject(o) === false) return false;
210
209
  ctor = o.constructor;
211
- if (ctor === void 0)
212
- return true;
210
+ if (ctor === void 0) return true;
213
211
  prot = ctor.prototype;
214
- if (isObject(prot) === false)
215
- return false;
212
+ if (isObject(prot) === false) return false;
216
213
  if (prot.hasOwnProperty("isPrototypeOf") === false) {
217
214
  return false;
218
215
  }
@@ -572,8 +569,7 @@ var require_lib = __commonJS({
572
569
  const moduloVal = typeOpts.moduloBitLength ? Math.pow(2, typeOpts.moduloBitLength) : Math.pow(2, bitLength);
573
570
  const moduloBound = typeOpts.moduloBitLength ? Math.pow(2, typeOpts.moduloBitLength - 1) : Math.pow(2, bitLength - 1);
574
571
  return function(V, opts) {
575
- if (!opts)
576
- opts = {};
572
+ if (!opts) opts = {};
577
573
  let x = +V;
578
574
  if (opts.enforceRange) {
579
575
  if (!Number.isFinite(x)) {
@@ -587,10 +583,8 @@ var require_lib = __commonJS({
587
583
  }
588
584
  if (!isNaN(x) && opts.clamp) {
589
585
  x = evenRound(x);
590
- if (x < lowerBound)
591
- x = lowerBound;
592
- if (x > upperBound)
593
- x = upperBound;
586
+ if (x < lowerBound) x = lowerBound;
587
+ if (x > upperBound) x = upperBound;
594
588
  return x;
595
589
  }
596
590
  if (!Number.isFinite(x) || x === 0) {
@@ -641,8 +635,7 @@ var require_lib = __commonJS({
641
635
  conversions["float"] = conversions["double"];
642
636
  conversions["unrestricted float"] = conversions["unrestricted double"];
643
637
  conversions["DOMString"] = function(V, opts) {
644
- if (!opts)
645
- opts = {};
638
+ if (!opts) opts = {};
646
639
  if (opts.treatNullAsEmptyString && V === null) {
647
640
  return "";
648
641
  }
@@ -879,8 +872,7 @@ var require_tr46 = __commonJS({
879
872
  }
880
873
  }
881
874
  }
882
- if (result.error)
883
- return null;
875
+ if (result.error) return null;
884
876
  return labels.join(".");
885
877
  };
886
878
  module2.exports.toUnicode = function(domain_name, useSTD3) {
@@ -2291,8 +2283,7 @@ var require_URL = __commonJS({
2291
2283
  return obj;
2292
2284
  },
2293
2285
  setup(obj, constructorArgs, privateData) {
2294
- if (!privateData)
2295
- privateData = {};
2286
+ if (!privateData) privateData = {};
2296
2287
  privateData.wrapper = obj;
2297
2288
  obj[impl] = new Impl.implementation(constructorArgs, privateData);
2298
2289
  obj[impl][utils.wrapperSymbol] = obj;
@@ -2465,16 +2456,13 @@ var require_lib2 = __commonJS({
2465
2456
  body = null;
2466
2457
  } else if (isURLSearchParams(body)) {
2467
2458
  body = Buffer.from(body.toString());
2468
- } else if (isBlob(body))
2469
- ;
2470
- else if (Buffer.isBuffer(body))
2471
- ;
2459
+ } else if (isBlob(body)) ;
2460
+ else if (Buffer.isBuffer(body)) ;
2472
2461
  else if (Object.prototype.toString.call(body) === "[object ArrayBuffer]") {
2473
2462
  body = Buffer.from(body);
2474
2463
  } else if (ArrayBuffer.isView(body)) {
2475
2464
  body = Buffer.from(body.buffer, body.byteOffset, body.byteLength);
2476
- } else if (body instanceof Stream)
2477
- ;
2465
+ } else if (body instanceof Stream) ;
2478
2466
  else {
2479
2467
  body = Buffer.from(String(body));
2480
2468
  }
@@ -2817,8 +2805,7 @@ var require_lib2 = __commonJS({
2817
2805
  }
2818
2806
  return;
2819
2807
  }
2820
- if (init == null)
2821
- ;
2808
+ if (init == null) ;
2822
2809
  else if (typeof init === "object") {
2823
2810
  const method = init[Symbol.iterator];
2824
2811
  if (method != null) {
@@ -3200,8 +3187,7 @@ var require_lib2 = __commonJS({
3200
3187
  }
3201
3188
  }
3202
3189
  let signal = isRequest(input) ? input.signal : null;
3203
- if ("signal" in init)
3204
- signal = init.signal;
3190
+ if ("signal" in init) signal = init.signal;
3205
3191
  if (signal != null && !isAbortSignal(signal)) {
3206
3192
  throw new TypeError("Expected signal to be an instanceof AbortSignal");
3207
3193
  }
@@ -3338,8 +3324,7 @@ var require_lib2 = __commonJS({
3338
3324
  if (request.body && request.body instanceof Stream.Readable) {
3339
3325
  destroyStream(request.body, error);
3340
3326
  }
3341
- if (!response2 || !response2.body)
3342
- return;
3327
+ if (!response2 || !response2.body) return;
3343
3328
  response2.body.emit("error", error);
3344
3329
  };
3345
3330
  if (signal && signal.aborted) {
@@ -3357,8 +3342,7 @@ var require_lib2 = __commonJS({
3357
3342
  }
3358
3343
  function finalize() {
3359
3344
  req.abort();
3360
- if (signal)
3361
- signal.removeEventListener("abort", abortAndFinalize);
3345
+ if (signal) signal.removeEventListener("abort", abortAndFinalize);
3362
3346
  clearTimeout(reqTimeout);
3363
3347
  }
3364
3348
  if (request.timeout) {
@@ -3467,8 +3451,7 @@ var require_lib2 = __commonJS({
3467
3451
  }
3468
3452
  }
3469
3453
  res.once("end", function() {
3470
- if (signal)
3471
- signal.removeEventListener("abort", abortAndFinalize);
3454
+ if (signal) signal.removeEventListener("abort", abortAndFinalize);
3472
3455
  });
3473
3456
  let body = res.pipe(new PassThrough$1());
3474
3457
  const response_options = {
@@ -3593,8 +3576,7 @@ var require_wrappy = __commonJS({
3593
3576
  "use strict";
3594
3577
  module2.exports = wrappy;
3595
3578
  function wrappy(fn, cb) {
3596
- if (fn && cb)
3597
- return wrappy(fn)(cb);
3579
+ if (fn && cb) return wrappy(fn)(cb);
3598
3580
  if (typeof fn !== "function")
3599
3581
  throw new TypeError("need wrapper function");
3600
3582
  Object.keys(fn).forEach(function(k) {
@@ -3642,8 +3624,7 @@ var require_once = __commonJS({
3642
3624
  });
3643
3625
  function once(fn) {
3644
3626
  var f = function() {
3645
- if (f.called)
3646
- return f.value;
3627
+ if (f.called) return f.value;
3647
3628
  f.called = true;
3648
3629
  return f.value = fn.apply(this, arguments);
3649
3630
  };