@magpiecloud/mags 1.8.0 → 1.8.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/bin/mags.js CHANGED
@@ -589,6 +589,14 @@ async function runJob(args) {
589
589
  log('green', `Completed in ${status.script_duration_ms}ms`);
590
590
  break;
591
591
  } else if (status.status === 'running' && persistent) {
592
+ // If --url requested, wait until VM is actually assigned (vm_id populated)
593
+ if (enableUrl && !status.vm_id) {
594
+ process.stdout.write('.');
595
+ await sleep(1000);
596
+ attempt++;
597
+ continue;
598
+ }
599
+
592
600
  log('green', 'VM running');
593
601
 
594
602
  if (enableUrl && status.subdomain) {
@@ -597,7 +605,7 @@ async function runJob(args) {
597
605
  if (accessResp.success) {
598
606
  log('green', `URL: https://${status.subdomain}.apps.magpiecloud.com`);
599
607
  } else {
600
- log('yellow', 'Warning: Could not enable URL access');
608
+ log('yellow', `Warning: Could not enable URL access${accessResp.error ? ': ' + accessResp.error : ''}`);
601
609
  }
602
610
  }
603
611
  return;
@@ -1348,7 +1356,7 @@ async function main() {
1348
1356
  break;
1349
1357
  case '--version':
1350
1358
  case '-v':
1351
- console.log('mags v1.8.0');
1359
+ console.log('mags v1.8.1');
1352
1360
  process.exit(0);
1353
1361
  break;
1354
1362
  case 'new':
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@magpiecloud/mags",
3
- "version": "1.8.0",
3
+ "version": "1.8.1",
4
4
  "description": "Mags CLI - Execute scripts on Magpie's instant VM infrastructure",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: magpie-mags
3
- Version: 1.0.0
3
+ Version: 1.1.0
4
4
  Summary: Mags SDK - Execute scripts on Magpie's instant VM infrastructure
5
5
  Author: Magpie Cloud
6
6
  License: MIT