@browserless.io/browserless 2.17.0-beta-1 → 2.17.1

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.
package/CHANGELOG.md CHANGED
@@ -1,7 +1,19 @@
1
- # [Latest](https://github.com/browserless/chrome/compare/v2.16.1...main)
1
+ # [Latest](https://github.com/browserless/chrome/compare/v2.17.0...main)
2
2
  - Dependency updates.
3
3
 
4
- # [Latest](https://github.com/browserless/chrome/compare/v2.16.0...v2.16.1)
4
+ # [v2.17.0](https://github.com/browserless/chrome/compare/v2.16.1...v2.17.0)
5
+ - Dependency updates.
6
+ - Hide token in logs on startup.
7
+ - Fixes an issue where using `--proxy-server` now works with /function-API calls.
8
+ - Adds support for the following CORS headers via env variables (headers and their corresponding config names are below). *Please note that these are very permissive by default, but only set when `ENABLE_CORS` is `true`!*
9
+ - 'Access-Control-Allow-Credentials': CORS_ALLOW_CREDENTIALS (default '*')
10
+ - 'Access-Control-Allow-Headers': CORS_ALLOW_HEADERS (default: '*')
11
+ - 'Access-Control-Allow-Methods': CORS_ALLOW_METHODS (default: 'OPTIONS, POST, GET')
12
+ - 'Access-Control-Allow-Origin': CORS_ALLOW_ORIGIN (default: '*')
13
+ - 'Access-Control-Expose-Headers': CORS_EXPOSE_HEADERS (default: '*')
14
+ - 'Access-Control-Max-Age': CORS_MAX_AGE (default: '2592000')
15
+
16
+ # [v2.16.1](https://github.com/browserless/chrome/compare/v2.16.0...v2.16.1)
5
17
  - Dependency updates.
6
18
  - Fixes numerous SDK issues when creating and building new projects.
7
19
 
@@ -121,6 +121,14 @@ export class ChromiumCDP extends EventEmitter {
121
121
  this.blockAds ? ublockPath : null,
122
122
  extensionLaunchArgs ? extensionLaunchArgs.split('=')[1] : null,
123
123
  ].filter((_) => !!_);
124
+ // Bypass the host we bind to so things like /function can work with proxies
125
+ if (options.args?.some((arg) => arg.includes('--proxy-server'))) {
126
+ const bypassList = [
127
+ this.config.getHost(),
128
+ new URL(this.config.getExternalAddress()).hostname,
129
+ ];
130
+ options.args.push(`--proxy-bypass-list=${bypassList.join(',')}`);
131
+ }
124
132
  const finalOptions = {
125
133
  ...options,
126
134
  args: [
@@ -312,7 +312,7 @@
312
312
  "type": "string"
313
313
  },
314
314
  "partitionKey": {
315
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
315
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
316
316
  "type": "string"
317
317
  }
318
318
  },
@@ -438,14 +438,14 @@
438
438
  "length": {
439
439
  "type": "number"
440
440
  },
441
- "__@toStringTag@11909": {
441
+ "__@toStringTag@11944": {
442
442
  "type": "string",
443
443
  "const": "Uint8Array"
444
444
  }
445
445
  },
446
446
  "required": [
447
447
  "BYTES_PER_ELEMENT",
448
- "__@toStringTag@11909",
448
+ "__@toStringTag@11944",
449
449
  "buffer",
450
450
  "byteLength",
451
451
  "byteOffset",
@@ -480,13 +480,13 @@
480
480
  "byteLength": {
481
481
  "type": "number"
482
482
  },
483
- "__@toStringTag@11909": {
483
+ "__@toStringTag@11944": {
484
484
  "type": "string"
485
485
  }
486
486
  },
487
487
  "additionalProperties": false,
488
488
  "required": [
489
- "__@toStringTag@11909",
489
+ "__@toStringTag@11944",
490
490
  "byteLength"
491
491
  ]
492
492
  },
@@ -496,18 +496,18 @@
496
496
  "byteLength": {
497
497
  "type": "number"
498
498
  },
499
- "__@species@11948": {
499
+ "__@species@11983": {
500
500
  "$ref": "#/definitions/SharedArrayBuffer"
501
501
  },
502
- "__@toStringTag@11909": {
502
+ "__@toStringTag@11944": {
503
503
  "type": "string",
504
504
  "const": "SharedArrayBuffer"
505
505
  }
506
506
  },
507
507
  "additionalProperties": false,
508
508
  "required": [
509
- "__@species@11948",
510
- "__@toStringTag@11909",
509
+ "__@species@11983",
510
+ "__@toStringTag@11944",
511
511
  "byteLength"
512
512
  ]
513
513
  },
@@ -314,7 +314,7 @@
314
314
  "type": "string"
315
315
  },
316
316
  "partitionKey": {
317
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
317
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
318
318
  "type": "string"
319
319
  }
320
320
  },
@@ -583,14 +583,14 @@
583
583
  "length": {
584
584
  "type": "number"
585
585
  },
586
- "__@toStringTag@82852": {
586
+ "__@toStringTag@94848": {
587
587
  "type": "string",
588
588
  "const": "Uint8Array"
589
589
  }
590
590
  },
591
591
  "required": [
592
592
  "BYTES_PER_ELEMENT",
593
- "__@toStringTag@82852",
593
+ "__@toStringTag@94848",
594
594
  "buffer",
595
595
  "byteLength",
596
596
  "byteOffset",
@@ -625,13 +625,13 @@
625
625
  "byteLength": {
626
626
  "type": "number"
627
627
  },
628
- "__@toStringTag@82852": {
628
+ "__@toStringTag@94848": {
629
629
  "type": "string"
630
630
  }
631
631
  },
632
632
  "additionalProperties": false,
633
633
  "required": [
634
- "__@toStringTag@82852",
634
+ "__@toStringTag@94848",
635
635
  "byteLength"
636
636
  ]
637
637
  },
@@ -641,18 +641,18 @@
641
641
  "byteLength": {
642
642
  "type": "number"
643
643
  },
644
- "__@species@82891": {
644
+ "__@species@94887": {
645
645
  "$ref": "#/definitions/SharedArrayBuffer"
646
646
  },
647
- "__@toStringTag@82852": {
647
+ "__@toStringTag@94848": {
648
648
  "type": "string",
649
649
  "const": "SharedArrayBuffer"
650
650
  }
651
651
  },
652
652
  "additionalProperties": false,
653
653
  "required": [
654
- "__@species@82891",
655
- "__@toStringTag@82852",
654
+ "__@species@94887",
655
+ "__@toStringTag@94848",
656
656
  "byteLength"
657
657
  ]
658
658
  },
@@ -323,7 +323,7 @@
323
323
  "type": "string"
324
324
  },
325
325
  "partitionKey": {
326
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
326
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
327
327
  "type": "string"
328
328
  }
329
329
  },
@@ -485,14 +485,14 @@
485
485
  "length": {
486
486
  "type": "number"
487
487
  },
488
- "__@toStringTag@118478": {
488
+ "__@toStringTag@118718": {
489
489
  "type": "string",
490
490
  "const": "Uint8Array"
491
491
  }
492
492
  },
493
493
  "required": [
494
494
  "BYTES_PER_ELEMENT",
495
- "__@toStringTag@118478",
495
+ "__@toStringTag@118718",
496
496
  "buffer",
497
497
  "byteLength",
498
498
  "byteOffset",
@@ -527,13 +527,13 @@
527
527
  "byteLength": {
528
528
  "type": "number"
529
529
  },
530
- "__@toStringTag@118478": {
530
+ "__@toStringTag@118718": {
531
531
  "type": "string"
532
532
  }
533
533
  },
534
534
  "additionalProperties": false,
535
535
  "required": [
536
- "__@toStringTag@118478",
536
+ "__@toStringTag@118718",
537
537
  "byteLength"
538
538
  ]
539
539
  },
@@ -543,18 +543,18 @@
543
543
  "byteLength": {
544
544
  "type": "number"
545
545
  },
546
- "__@species@118517": {
546
+ "__@species@118757": {
547
547
  "$ref": "#/definitions/SharedArrayBuffer"
548
548
  },
549
- "__@toStringTag@118478": {
549
+ "__@toStringTag@118718": {
550
550
  "type": "string",
551
551
  "const": "SharedArrayBuffer"
552
552
  }
553
553
  },
554
554
  "additionalProperties": false,
555
555
  "required": [
556
- "__@species@118517",
557
- "__@toStringTag@118478",
556
+ "__@species@118757",
557
+ "__@toStringTag@118718",
558
558
  "byteLength"
559
559
  ]
560
560
  },
@@ -247,7 +247,7 @@
247
247
  "type": "string"
248
248
  },
249
249
  "partitionKey": {
250
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. Supported only in Chrome.",
250
+ "description": "Cookie partition key. In Chrome, it is the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
251
251
  "type": "string"
252
252
  },
253
253
  "partitionKeyOpaque": {
@@ -320,7 +320,7 @@
320
320
  "type": "string"
321
321
  },
322
322
  "partitionKey": {
323
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
323
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
324
324
  "type": "string"
325
325
  }
326
326
  },
@@ -528,14 +528,14 @@
528
528
  "length": {
529
529
  "type": "number"
530
530
  },
531
- "__@toStringTag@130556": {
531
+ "__@toStringTag@130831": {
532
532
  "type": "string",
533
533
  "const": "Uint8Array"
534
534
  }
535
535
  },
536
536
  "required": [
537
537
  "BYTES_PER_ELEMENT",
538
- "__@toStringTag@130556",
538
+ "__@toStringTag@130831",
539
539
  "buffer",
540
540
  "byteLength",
541
541
  "byteOffset",
@@ -570,13 +570,13 @@
570
570
  "byteLength": {
571
571
  "type": "number"
572
572
  },
573
- "__@toStringTag@130556": {
573
+ "__@toStringTag@130831": {
574
574
  "type": "string"
575
575
  }
576
576
  },
577
577
  "additionalProperties": false,
578
578
  "required": [
579
- "__@toStringTag@130556",
579
+ "__@toStringTag@130831",
580
580
  "byteLength"
581
581
  ]
582
582
  },
@@ -586,18 +586,18 @@
586
586
  "byteLength": {
587
587
  "type": "number"
588
588
  },
589
- "__@species@130595": {
589
+ "__@species@130870": {
590
590
  "$ref": "#/definitions/SharedArrayBuffer"
591
591
  },
592
- "__@toStringTag@130556": {
592
+ "__@toStringTag@130831": {
593
593
  "type": "string",
594
594
  "const": "SharedArrayBuffer"
595
595
  }
596
596
  },
597
597
  "additionalProperties": false,
598
598
  "required": [
599
- "__@species@130595",
600
- "__@toStringTag@130556",
599
+ "__@species@130870",
600
+ "__@toStringTag@130831",
601
601
  "byteLength"
602
602
  ]
603
603
  },
@@ -312,7 +312,7 @@
312
312
  "type": "string"
313
313
  },
314
314
  "partitionKey": {
315
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
315
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
316
316
  "type": "string"
317
317
  }
318
318
  },
@@ -438,14 +438,14 @@
438
438
  "length": {
439
439
  "type": "number"
440
440
  },
441
- "__@toStringTag@142544": {
441
+ "__@toStringTag@142854": {
442
442
  "type": "string",
443
443
  "const": "Uint8Array"
444
444
  }
445
445
  },
446
446
  "required": [
447
447
  "BYTES_PER_ELEMENT",
448
- "__@toStringTag@142544",
448
+ "__@toStringTag@142854",
449
449
  "buffer",
450
450
  "byteLength",
451
451
  "byteOffset",
@@ -480,13 +480,13 @@
480
480
  "byteLength": {
481
481
  "type": "number"
482
482
  },
483
- "__@toStringTag@142544": {
483
+ "__@toStringTag@142854": {
484
484
  "type": "string"
485
485
  }
486
486
  },
487
487
  "additionalProperties": false,
488
488
  "required": [
489
- "__@toStringTag@142544",
489
+ "__@toStringTag@142854",
490
490
  "byteLength"
491
491
  ]
492
492
  },
@@ -496,18 +496,18 @@
496
496
  "byteLength": {
497
497
  "type": "number"
498
498
  },
499
- "__@species@142583": {
499
+ "__@species@142893": {
500
500
  "$ref": "#/definitions/SharedArrayBuffer"
501
501
  },
502
- "__@toStringTag@142544": {
502
+ "__@toStringTag@142854": {
503
503
  "type": "string",
504
504
  "const": "SharedArrayBuffer"
505
505
  }
506
506
  },
507
507
  "additionalProperties": false,
508
508
  "required": [
509
- "__@species@142583",
510
- "__@toStringTag@142544",
509
+ "__@species@142893",
510
+ "__@toStringTag@142854",
511
511
  "byteLength"
512
512
  ]
513
513
  },
@@ -314,7 +314,7 @@
314
314
  "type": "string"
315
315
  },
316
316
  "partitionKey": {
317
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
317
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
318
318
  "type": "string"
319
319
  }
320
320
  },
@@ -583,14 +583,14 @@
583
583
  "length": {
584
584
  "type": "number"
585
585
  },
586
- "__@toStringTag@261161": {
586
+ "__@toStringTag@225737": {
587
587
  "type": "string",
588
588
  "const": "Uint8Array"
589
589
  }
590
590
  },
591
591
  "required": [
592
592
  "BYTES_PER_ELEMENT",
593
- "__@toStringTag@261161",
593
+ "__@toStringTag@225737",
594
594
  "buffer",
595
595
  "byteLength",
596
596
  "byteOffset",
@@ -625,13 +625,13 @@
625
625
  "byteLength": {
626
626
  "type": "number"
627
627
  },
628
- "__@toStringTag@261161": {
628
+ "__@toStringTag@225737": {
629
629
  "type": "string"
630
630
  }
631
631
  },
632
632
  "additionalProperties": false,
633
633
  "required": [
634
- "__@toStringTag@261161",
634
+ "__@toStringTag@225737",
635
635
  "byteLength"
636
636
  ]
637
637
  },
@@ -641,18 +641,18 @@
641
641
  "byteLength": {
642
642
  "type": "number"
643
643
  },
644
- "__@species@261200": {
644
+ "__@species@225776": {
645
645
  "$ref": "#/definitions/SharedArrayBuffer"
646
646
  },
647
- "__@toStringTag@261161": {
647
+ "__@toStringTag@225737": {
648
648
  "type": "string",
649
649
  "const": "SharedArrayBuffer"
650
650
  }
651
651
  },
652
652
  "additionalProperties": false,
653
653
  "required": [
654
- "__@species@261200",
655
- "__@toStringTag@261161",
654
+ "__@species@225776",
655
+ "__@toStringTag@225737",
656
656
  "byteLength"
657
657
  ]
658
658
  },
@@ -323,7 +323,7 @@
323
323
  "type": "string"
324
324
  },
325
325
  "partitionKey": {
326
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
326
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
327
327
  "type": "string"
328
328
  }
329
329
  },
@@ -485,14 +485,14 @@
485
485
  "length": {
486
486
  "type": "number"
487
487
  },
488
- "__@toStringTag@249084": {
488
+ "__@toStringTag@249601": {
489
489
  "type": "string",
490
490
  "const": "Uint8Array"
491
491
  }
492
492
  },
493
493
  "required": [
494
494
  "BYTES_PER_ELEMENT",
495
- "__@toStringTag@249084",
495
+ "__@toStringTag@249601",
496
496
  "buffer",
497
497
  "byteLength",
498
498
  "byteOffset",
@@ -527,13 +527,13 @@
527
527
  "byteLength": {
528
528
  "type": "number"
529
529
  },
530
- "__@toStringTag@249084": {
530
+ "__@toStringTag@249601": {
531
531
  "type": "string"
532
532
  }
533
533
  },
534
534
  "additionalProperties": false,
535
535
  "required": [
536
- "__@toStringTag@249084",
536
+ "__@toStringTag@249601",
537
537
  "byteLength"
538
538
  ]
539
539
  },
@@ -543,18 +543,18 @@
543
543
  "byteLength": {
544
544
  "type": "number"
545
545
  },
546
- "__@species@249123": {
546
+ "__@species@249640": {
547
547
  "$ref": "#/definitions/SharedArrayBuffer"
548
548
  },
549
- "__@toStringTag@249084": {
549
+ "__@toStringTag@249601": {
550
550
  "type": "string",
551
551
  "const": "SharedArrayBuffer"
552
552
  }
553
553
  },
554
554
  "additionalProperties": false,
555
555
  "required": [
556
- "__@species@249123",
557
- "__@toStringTag@249084",
556
+ "__@species@249640",
557
+ "__@toStringTag@249601",
558
558
  "byteLength"
559
559
  ]
560
560
  },
@@ -247,7 +247,7 @@
247
247
  "type": "string"
248
248
  },
249
249
  "partitionKey": {
250
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. Supported only in Chrome.",
250
+ "description": "Cookie partition key. In Chrome, it is the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
251
251
  "type": "string"
252
252
  },
253
253
  "partitionKeyOpaque": {
@@ -320,7 +320,7 @@
320
320
  "type": "string"
321
321
  },
322
322
  "partitionKey": {
323
- "description": "Cookie partition key. The site of the top-level URL the browser was visiting at the\nstart of the request to the endpoint that set the cookie. If not set, the cookie will\nbe set as not partitioned.",
323
+ "description": "Cookie partition key. In Chrome, it matches the top-level site the\npartitioned cookie is available in. In Firefox, it matches the\nsource origin\n(https://w3c.github.io/webdriver-bidi/#type-storage-PartitionKey).",
324
324
  "type": "string"
325
325
  }
326
326
  },
@@ -528,14 +528,14 @@
528
528
  "length": {
529
529
  "type": "number"
530
530
  },
531
- "__@toStringTag@225290": {
531
+ "__@toStringTag@261711": {
532
532
  "type": "string",
533
533
  "const": "Uint8Array"
534
534
  }
535
535
  },
536
536
  "required": [
537
537
  "BYTES_PER_ELEMENT",
538
- "__@toStringTag@225290",
538
+ "__@toStringTag@261711",
539
539
  "buffer",
540
540
  "byteLength",
541
541
  "byteOffset",
@@ -570,13 +570,13 @@
570
570
  "byteLength": {
571
571
  "type": "number"
572
572
  },
573
- "__@toStringTag@225290": {
573
+ "__@toStringTag@261711": {
574
574
  "type": "string"
575
575
  }
576
576
  },
577
577
  "additionalProperties": false,
578
578
  "required": [
579
- "__@toStringTag@225290",
579
+ "__@toStringTag@261711",
580
580
  "byteLength"
581
581
  ]
582
582
  },
@@ -586,18 +586,18 @@
586
586
  "byteLength": {
587
587
  "type": "number"
588
588
  },
589
- "__@species@225329": {
589
+ "__@species@261750": {
590
590
  "$ref": "#/definitions/SharedArrayBuffer"
591
591
  },
592
- "__@toStringTag@225290": {
592
+ "__@toStringTag@261711": {
593
593
  "type": "string",
594
594
  "const": "SharedArrayBuffer"
595
595
  }
596
596
  },
597
597
  "additionalProperties": false,
598
598
  "required": [
599
- "__@species@225329",
600
- "__@toStringTag@225290",
599
+ "__@species@261750",
600
+ "__@toStringTag@261711",
601
601
  "byteLength"
602
602
  ]
603
603
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@browserless.io/browserless",
3
- "version": "2.17.0-beta-1",
3
+ "version": "2.17.1",
4
4
  "license": "SSPL",
5
5
  "description": "The browserless platform",
6
6
  "author": "browserless.io",
@@ -51,7 +51,7 @@
51
51
  "debug": "^4.3.6",
52
52
  "del": "^7.0.0",
53
53
  "enjoi": "^9.0.1",
54
- "file-type": "^19.4.0",
54
+ "file-type": "^19.4.1",
55
55
  "get-port": "^7.1.0",
56
56
  "gradient-string": "^2.0.0",
57
57
  "http-proxy": "^1.18.1",
@@ -62,7 +62,7 @@
62
62
  "playwright-1.43": "npm:playwright-core@1.43.1",
63
63
  "playwright-1.44": "npm:playwright-core@1.44.1",
64
64
  "playwright-core": "^1.46.0",
65
- "puppeteer-core": "^23.0.2",
65
+ "puppeteer-core": "^23.1.0",
66
66
  "puppeteer-extra": "^3.3.6",
67
67
  "puppeteer-extra-plugin-stealth": "^2.11.2",
68
68
  "queue": "^7.0.0",
@@ -76,7 +76,7 @@
76
76
  "@types/http-proxy": "^1.17.15",
77
77
  "@types/micromatch": "^4.0.9",
78
78
  "@types/mocha": "^10.0.7",
79
- "@types/node": "^22.2.0",
79
+ "@types/node": "^22.3.0",
80
80
  "@types/sinon": "^17.0.3",
81
81
  "@typescript-eslint/eslint-plugin": "^7.18.0",
82
82
  "@typescript-eslint/parser": "^7.18.0",
@@ -243,10 +243,7 @@ export class Browserless extends EventEmitter {
243
243
  const hasDebugger = await this.config.hasDebugger();
244
244
  const debuggerURL =
245
245
  hasDebugger &&
246
- makeExternalURL(
247
- this.config.getExternalAddress(),
248
- `/debugger/?token=xxx`,
249
- );
246
+ makeExternalURL(this.config.getExternalAddress(), `/debugger/?token=xxx`);
250
247
  const docsLink = makeExternalURL(this.config.getExternalAddress(), '/docs');
251
248
 
252
249
  this.logger.info(printLogo(docsLink, debuggerURL));
@@ -193,6 +193,15 @@ export class ChromiumCDP extends EventEmitter {
193
193
  extensionLaunchArgs ? extensionLaunchArgs.split('=')[1] : null,
194
194
  ].filter((_) => !!_);
195
195
 
196
+ // Bypass the host we bind to so things like /function can work with proxies
197
+ if (options.args?.some((arg) => arg.includes('--proxy-server'))) {
198
+ const bypassList = [
199
+ this.config.getHost(),
200
+ new URL(this.config.getExternalAddress()).hostname,
201
+ ];
202
+ options.args.push(`--proxy-bypass-list=${bypassList.join(',')}`);
203
+ }
204
+
196
205
  const finalOptions = {
197
206
  ...options,
198
207
  args: [
package/src/server.ts CHANGED
@@ -55,9 +55,7 @@ export class HTTPServer extends EventEmitter {
55
55
  this.port = config.getPort();
56
56
 
57
57
  this.logger.info(
58
- `Server instantiated with host "${this.host}" on port "${
59
- this.port
60
- }`,
58
+ `Server instantiated with host "${this.host}" on port "${this.port}`,
61
59
  );
62
60
  }
63
61