browserstack-node-sdk 1.34.50 → 1.34.51
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/ats/src/cloudproviders/AWS.js +1 -1
- package/ats/src/cloudproviders/Azure.js +1 -1
- package/ats/src/cloudproviders/CloudProvider.js +1 -1
- package/ats/src/cloudproviders/GoogleCloudProvider.js +1 -1
- package/ats/src/cloudproviders/utils.js +1 -1
- package/ats/src/commands/configure.js +1 -1
- package/ats/src/commands/connect.js +1 -1
- package/ats/src/commands/connect_commands/grid.js +1 -1
- package/ats/src/commands/create.js +1 -1
- package/ats/src/commands/create_commands/grid.js +1 -1
- package/ats/src/commands/delete.js +1 -1
- package/ats/src/commands/delete_commands/grid.js +1 -1
- package/ats/src/commands/init.js +1 -1
- package/ats/src/commands/list.js +1 -1
- package/ats/src/commands/list_commands/grid_profiles.js +1 -1
- package/ats/src/commands/list_commands/grids.js +1 -1
- package/ats/src/commands/precheck.js +1 -1
- package/ats/src/commands/precheck_commands/setup_precheck.js +1 -1
- package/ats/src/commands/start.js +1 -1
- package/ats/src/commands/start_commands/grid.js +1 -1
- package/ats/src/commands/stop.js +1 -1
- package/ats/src/commands/stop_commands/grid.js +1 -1
- package/ats/src/config/constants.js +1 -1
- package/ats/src/config/logger.js +1 -1
- package/ats/src/index.js +1 -1
- package/ats/src/utils/AWSUtils.js +1 -1
- package/ats/src/utils/createAutoscalerStack.js +1 -1
- package/ats/src/utils/createClusterStack.js +1 -1
- package/ats/src/utils/createHubHaStack.js +1 -1
- package/ats/src/utils/createk8sClient.js +1 -1
- package/ats/src/utils/deleteEFSMountTargets.js +1 -1
- package/ats/src/utils/deleteStack.js +1 -1
- package/ats/src/utils/describeStack.js +1 -1
- package/ats/src/utils/gridComponents.js +1 -1
- package/ats/src/utils/hstUtils.js +1 -1
- package/ats/src/utils/instrumentationUtils.js +1 -1
- package/ats/src/utils/userInput.js +1 -1
- package/ats/src/utils/utilityMethods.js +1 -1
- package/ats/src/utils/webSocketUtils.js +1 -1
- package/package.json +3 -3
- package/src/ai-sdk-node/bundle.js +1 -1
- package/src/bin/codeceptjs/BrowserStackPlugin.js +1 -1
- package/src/bin/codeceptjs/command.js +1 -1
- package/src/bin/codeceptjs/helper.js +1 -1
- package/src/bin/codeceptjs/o11yHelper.js +1 -1
- package/src/bin/cucumber-js/command.js +1 -1
- package/src/bin/cucumber-js/formatter/custom_formatter.js +1 -1
- package/src/bin/cucumber-js/formatter/custom_formatter_old_versions.js +1 -1
- package/src/bin/cucumber-js/test-observability.js +1 -1
- package/src/bin/cucumber-js/test.setup.js +1 -1
- package/src/bin/cucumber-js/test_old.setup.js +1 -1
- package/src/bin/cucumber-js/timeout.setup.js +1 -1
- package/src/bin/integrations/command.js +1 -1
- package/src/bin/integrations/constants.js +1 -1
- package/src/bin/jest/command.js +1 -1
- package/src/bin/jest/customImplements/customCircus.js +1 -1
- package/src/bin/jest/customImplements/customEnvironment.js +1 -1
- package/src/bin/jest/customImplements/customJestAdapterInit.js +1 -1
- package/src/bin/jest/customImplements/customTestRunnerTemplate.js +1 -1
- package/src/bin/jest/jest.setup.js +1 -1
- package/src/bin/jest/test-observability/data-hooks.js +1 -1
- package/src/bin/jest/test-observability/helper.js +1 -1
- package/src/bin/jest/test-observability/obsReporter.js +1 -1
- package/src/bin/jest/test-observability/test-details.js +1 -1
- package/src/bin/jest/test_before.setup.js +1 -1
- package/src/bin/launcher/launcher.js +1 -1
- package/src/bin/mocha/accessibility-automation/helper.js +1 -1
- package/src/bin/mocha/bstack-reporter/customReporter.js +1 -1
- package/src/bin/mocha/command.js +1 -1
- package/src/bin/mocha/test-observability/builderPatch.js +1 -1
- package/src/bin/mocha/test-observability/data-hooks.js +1 -1
- package/src/bin/mocha/test-observability/mochaUtils.js +1 -1
- package/src/bin/mocha/test.setup.js +1 -1
- package/src/bin/nightwatch/command.js +1 -1
- package/src/bin/playwright/accessibility-helper.js +1 -1
- package/src/bin/playwright/command.js +1 -1
- package/src/bin/playwright/globalSetup.js +1 -1
- package/src/bin/playwright/mock-process.js +1 -1
- package/src/bin/playwright/modifyPlaywrightConf.js +1 -1
- package/src/bin/playwright/patches.js +1 -1
- package/src/bin/playwright/reporter/pwUtils.js +1 -1
- package/src/bin/playwright/reporter/reporter.js +1 -1
- package/src/bin/playwright/reporter/test-details.js +1 -1
- package/src/bin/playwright/sessionDetails.js +1 -1
- package/src/bin/runner.js +1 -1
- package/src/bin/setup.js +1 -1
- package/src/bin/test-runner/index.js +1 -1
- package/src/bin/test-runner/runTest.js +1 -1
- package/src/bin/test-runner/testWorker.js +1 -1
- package/src/bin/utils/constants.js +1 -1
- package/src/bin/utils/log4jsAppender.js +1 -1
- package/src/bin/utils/logPatcher.js +1 -1
- package/src/bin/utils/logReportingAPI.js +1 -1
- package/src/bin/vanilla-js/command.js +1 -1
- package/src/browserStackSdk.js +1 -1
- package/src/helpers/BrowserStackSetup.js +1 -1
- package/src/helpers/accessibility-automation/constants.js +1 -1
- package/src/helpers/accessibility-automation/helper.js +1 -1
- package/src/helpers/accessibility-automation/scripts.js +1 -1
- package/src/helpers/ai-sdk/aiSdkWrapper.js +1 -1
- package/src/helpers/ai-sdk/autoHealHelper.js +1 -1
- package/src/helpers/ats/constants.js +1 -1
- package/src/helpers/ats/helper.js +1 -1
- package/src/helpers/capsMapping.js +1 -1
- package/src/helpers/central-scanner/constants.js +1 -1
- package/src/helpers/central-scanner/helpers.js +1 -1
- package/src/helpers/globals.js +1 -1
- package/src/helpers/helper.js +1 -1
- package/src/helpers/logger.js +1 -1
- package/src/helpers/metadata.js +1 -1
- package/src/helpers/patchHelper.js +1 -1
- package/src/helpers/patchHelpers.js +1 -1
- package/src/helpers/percy/Percy.js +1 -1
- package/src/helpers/percy/PercyBinary.js +1 -1
- package/src/helpers/percy/PercyCaptureMap.js +1 -1
- package/src/helpers/percy/PercyCaptureModes.js +1 -1
- package/src/helpers/percy/PercySDK.js +1 -1
- package/src/helpers/percy/index.js +1 -1
- package/src/helpers/percy/utils.js +1 -1
- package/src/helpers/performance/constants.js +1 -1
- package/src/helpers/performance/performance-tester.js +1 -1
- package/src/helpers/processHelper.js +1 -1
- package/src/helpers/request-spy.js +1 -1
- package/src/helpers/setKeepAlive.js +1 -1
- package/src/helpers/test-observability/constants.js +1 -1
- package/src/helpers/test-observability/error-handler.js +1 -1
- package/src/helpers/test-observability/requestQueueHandler.js +1 -1
- package/src/helpers/test-observability/sessionHandler.js +1 -1
- package/src/helpers/test-observability/utils.js +1 -1
- package/src/helpers/testhub/constants.js +1 -1
- package/src/helpers/testhub/testhubHandler.js +1 -1
- package/src/helpers/testhub/utils.js +1 -1
- package/src/helpers/timeoutPromise.js +1 -1
- package/src/helpers/utilities.js +1 -1
- package/src/helpers/w3cMapping.js +1 -1
- package/src/hubAllocationMethods.js +1 -1
- package/src/index.js +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a15_0x40272c=a15_0x343a;(function(_0x50703e,_0x48076a){const _0x2c0772=a15_0x343a,_0xe59747=_0x50703e();while(!![]){try{const _0x512e6b=-parseInt(_0x2c0772(0x13f))/0x1*(-parseInt(_0x2c0772(0x160))/0x2)+-parseInt(_0x2c0772(0x143))/0x3*(parseInt(_0x2c0772(0x15c))/0x4)+parseInt(_0x2c0772(0x150))/0x5+-parseInt(_0x2c0772(0x15d))/0x6+-parseInt(_0x2c0772(0x162))/0x7+parseInt(_0x2c0772(0x136))/0x8+parseInt(_0x2c0772(0x161))/0x9;if(_0x512e6b===_0x48076a)break;else _0xe59747['push'](_0xe59747['shift']());}catch(_0x5e53c3){_0xe59747['push'](_0xe59747['shift']());}}}(a15_0x3d7c,0xa546d));const fs=require('fs'),got=require('got'),{table}=require(a15_0x40272c(0x123)),{v4:uuidv4}=require(a15_0x40272c(0x14e)),{AG_API_URL,HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE,messageTypes,global_registry}=require(a15_0x40272c(0x135)),{getCredentialsPath,getAuthHeader}=require(a15_0x40272c(0x139)),{sendInstrumentationEvent}=require('../../utils/instrumentationUtils');function a15_0x3d7c(){const _0x20d9cc=['builder','uuid','maHze','2502440UnzqhB','handler','UrWRB','Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Response\x20from\x20server:\x20','unauthorised','list','grids','boolean','username','running','yrSGD','status','1539356mrqYmU','6828492LdCuUC','FmlXN','grid-id','134XFWeZg','26587818yylcZJ','5576893kAWgzk','server-error','unknown-error','lyhvC','Failed\x20to\x20list\x20resources!\x20Error:\x20','eCqIW','DRjCj','fXaYe','Browserstack','bstackAccesskey','https://','ERROR','WqBTk','error','VMwtY','VkiDf','Credentials\x20not\x20found!\x20Ensure\x20init\x20command\x20is\x20run\x20before\x20running\x20this\x20command.','push','EEuST','CRqLO','table','DVJoS','zQhey','zLMGR','List\x20down\x20grids\x20configured\x20by\x20a\x20particular\x20user','exit','UCfdU','ecWAO','clusterName','password','parse','hodCo','forEach','bstackUsername','epilogue','init-not-called','stack','requestId','../../config/constants','2051520SgmPay','options','cluster-name','../../utils/utilityMethods','list-grids-called','help','/packages/cli/get-all-grids','eJzaF','command','823ZyumcO','ZOiDS','jBKpu','aiGyE','9RjYTjG','allGrids','log','rMlzk','/packages/cli/get-grids','all-grids','queued','PFlqn','KcpbO','body'];a15_0x3d7c=function(){return _0x20d9cc;};return a15_0x3d7c();}function a15_0x343a(_0x4f12f9,_0x217253){const _0x3d7c03=a15_0x3d7c();return a15_0x343a=function(_0x343a08,_0x1be597){_0x343a08=_0x343a08-0x122;let _0x2dc1d7=_0x3d7c03[_0x343a08];return _0x2dc1d7;},a15_0x343a(_0x4f12f9,_0x217253);}exports[a15_0x40272c(0x13e)]=a15_0x40272c(0x156),exports['desc']=a15_0x40272c(0x127),exports[a15_0x40272c(0x14d)]=function(_0x576bac){const _0x96b61c=a15_0x40272c,_0x2a1714={};_0x2a1714[_0x96b61c(0x14f)]='Use\x20this\x20option\x20to\x20list\x20all\x20the\x20grids\x20for\x20your\x20group.',_0x2a1714[_0x96b61c(0x14a)]=_0x96b61c(0x157),_0x2a1714[_0x96b61c(0x140)]=_0x96b61c(0x13b);const _0x78f335=_0x2a1714,_0x28eea8={};_0x28eea8['description']=_0x78f335[_0x96b61c(0x14f)],_0x28eea8['type']=_0x78f335[_0x96b61c(0x14a)];const _0x4fb78c={};return _0x4fb78c[_0x96b61c(0x148)]=_0x28eea8,_0x576bac['usage'](HELP_HEADER_MESSAGE[_0x96b61c(0x155)]['grid'])[_0x96b61c(0x131)](HELP_FOOTER_MESSAGE)[_0x96b61c(0x137)](_0x4fb78c)[_0x96b61c(0x13b)](_0x78f335['ZOiDS'])['argv'];},exports[a15_0x40272c(0x151)]=async function(_0x2ad418){const _0x3d94b4=a15_0x40272c,_0x4d65d3={'EEuST':function(_0x1a92db){return _0x1a92db();},'yrSGD':_0x3d94b4(0x172),'zLMGR':function(_0x31c533,_0x38c38a,_0x256c4f,_0xbfa34e,_0x67f86b,_0x176337,_0x511b2d){return _0x31c533(_0x38c38a,_0x256c4f,_0xbfa34e,_0x67f86b,_0x176337,_0x511b2d);},'zQhey':_0x3d94b4(0x13a),'FmlXN':_0x3d94b4(0x132),'hodCo':'GET','DRjCj':function(_0x97f1ae,_0x51fe78,_0xb1ab3e){return _0x97f1ae(_0x51fe78,_0xb1ab3e);},'VMwtY':function(_0x19cd05,_0x40477a,_0x2687af){return _0x19cd05(_0x40477a,_0x2687af);},'WqBTk':function(_0x45f3ab,_0x44286b){return _0x45f3ab!==_0x44286b;},'bqwKE':function(_0x39fe16,_0x197441){return _0x39fe16!==_0x197441;},'CRqLO':function(_0x269d6c,_0x4c188c){return _0x269d6c===_0x4c188c;},'lyhvC':'\x0aFound\x20the\x20following\x20grids:\x0a','ecWAO':_0x3d94b4(0x15f),'KcpbO':'grid-name','wNaAZ':_0x3d94b4(0x15b),'tJUbn':_0x3d94b4(0x159),'eCqIW':_0x3d94b4(0x149),'UrWRB':_0x3d94b4(0x138),'jBKpu':function(_0x4ed4cf,_0x3780c9){return _0x4ed4cf(_0x3780c9);},'aiGyE':function(_0x3cb2ce,_0x107532){return _0x3cb2ce===_0x107532;},'eJzaF':'Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Unauthorized\x20request!','fXaYe':function(_0x4a5aa6,_0x34ef61,_0x115734,_0x5ea065,_0x3f508f,_0x3d6044,_0x302f53){return _0x4a5aa6(_0x34ef61,_0x115734,_0x5ea065,_0x3f508f,_0x3d6044,_0x302f53);},'VkiDf':_0x3d94b4(0x154),'UCfdU':function(_0x543528,_0x565532,_0xf8afdb,_0x1abdd2,_0xffbea4,_0x141901,_0x31c57f){return _0x543528(_0x565532,_0xf8afdb,_0x1abdd2,_0xffbea4,_0x141901,_0x31c57f);},'rMlzk':_0x3d94b4(0x163),'DVJoS':_0x3d94b4(0x164)};try{global_registry[_0x3d94b4(0x134)]=_0x4d65d3[_0x3d94b4(0x174)](uuidv4);!fs['existsSync'](_0x4d65d3['EEuST'](getCredentialsPath))&&(console[_0x3d94b4(0x16f)](_0x4d65d3[_0x3d94b4(0x15a)]),await _0x4d65d3[_0x3d94b4(0x126)](sendInstrumentationEvent,_0x2ad418,_0x4d65d3['zQhey'],messageTypes[_0x3d94b4(0x16d)],_0x4d65d3[_0x3d94b4(0x15e)],null,_0x2ad418),process[_0x3d94b4(0x128)](0x1));const _0x37aed0=JSON[_0x3d94b4(0x12d)](fs['readFileSync'](_0x4d65d3[_0x3d94b4(0x174)](getCredentialsPath)));let _0x32b662=_0x3d94b4(0x16c)+AG_API_URL+_0x3d94b4(0x147);_0x2ad418[_0x3d94b4(0x144)]&&(_0x32b662=_0x3d94b4(0x16c)+AG_API_URL+_0x3d94b4(0x13c));const _0x534fa7={'method':_0x4d65d3[_0x3d94b4(0x12e)],'headers':_0x4d65d3[_0x3d94b4(0x168)](getAuthHeader,_0x37aed0[_0x3d94b4(0x16a)]['username'],_0x37aed0[_0x3d94b4(0x16a)][_0x3d94b4(0x12c)]),'throwHttpErrors':![]};global_registry[_0x3d94b4(0x130)]=_0x37aed0['Browserstack'][_0x3d94b4(0x158)],global_registry[_0x3d94b4(0x16b)]=_0x37aed0[_0x3d94b4(0x16a)]['password'],_0x4d65d3[_0x3d94b4(0x126)](sendInstrumentationEvent,_0x2ad418,_0x4d65d3[_0x3d94b4(0x125)],messageTypes['INFO'],null,null,_0x2ad418);const _0x3a3ad6=await _0x4d65d3[_0x3d94b4(0x170)](got,_0x32b662,_0x534fa7);if(_0x4d65d3[_0x3d94b4(0x16e)](_0x3a3ad6,null)&&_0x4d65d3['bqwKE'](_0x3a3ad6,undefined)&&_0x4d65d3[_0x3d94b4(0x122)](_0x3a3ad6['statusCode'],0xc8)){const _0x3e51c5=JSON[_0x3d94b4(0x12d)](_0x3a3ad6[_0x3d94b4(0x14c)]);console[_0x3d94b4(0x145)](_0x4d65d3[_0x3d94b4(0x165)]);const _0x58e8cd=[];_0x58e8cd['push']([_0x4d65d3[_0x3d94b4(0x12a)],_0x4d65d3[_0x3d94b4(0x14b)],_0x4d65d3['wNaAZ'],_0x4d65d3['tJUbn'],_0x4d65d3[_0x3d94b4(0x167)],_0x4d65d3[_0x3d94b4(0x152)]]),_0x3e51c5[_0x3d94b4(0x12f)](_0x532984=>{const _0x460a18=_0x3d94b4;_0x58e8cd[_0x460a18(0x173)]([_0x532984['id'],_0x532984['name'],_0x532984['status'],_0x532984[_0x460a18(0x159)],_0x532984[_0x460a18(0x149)],_0x532984[_0x460a18(0x12b)]]);}),console[_0x3d94b4(0x145)](_0x4d65d3[_0x3d94b4(0x141)](table,_0x58e8cd)),process[_0x3d94b4(0x128)](0x0);}_0x4d65d3[_0x3d94b4(0x142)](_0x3a3ad6['statusCode'],0x191)&&(console[_0x3d94b4(0x16f)](_0x4d65d3[_0x3d94b4(0x13d)]),await _0x4d65d3[_0x3d94b4(0x169)](sendInstrumentationEvent,_0x2ad418,_0x4d65d3[_0x3d94b4(0x125)],messageTypes[_0x3d94b4(0x16d)],_0x4d65d3[_0x3d94b4(0x171)],null,_0x2ad418),process['exit'](0x1)),console[_0x3d94b4(0x16f)](_0x3d94b4(0x153)+JSON['stringify'](_0x3a3ad6)),await _0x4d65d3[_0x3d94b4(0x129)](sendInstrumentationEvent,_0x2ad418,_0x4d65d3[_0x3d94b4(0x125)],messageTypes[_0x3d94b4(0x16d)],_0x4d65d3[_0x3d94b4(0x146)],_0x3a3ad6,_0x2ad418),process[_0x3d94b4(0x128)](0x1);}catch(_0x36fc96){console[_0x3d94b4(0x16f)](_0x3d94b4(0x166)+_0x36fc96[_0x3d94b4(0x133)]),await _0x4d65d3[_0x3d94b4(0x129)](sendInstrumentationEvent,_0x2ad418,_0x4d65d3['zQhey'],messageTypes['ERROR'],_0x4d65d3[_0x3d94b4(0x124)],_0x36fc96,_0x2ad418),process[_0x3d94b4(0x128)](0x1);}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a16_0x5670(_0x2ff304,_0x3ffaeb){const _0xffe3ee=a16_0xffe3();return a16_0x5670=function(_0x56702b,_0x230d5e){_0x56702b=_0x56702b-0x1b0;let _0x2947ed=_0xffe3ee[_0x56702b];return _0x2947ed;},a16_0x5670(_0x2ff304,_0x3ffaeb);}const a16_0xc7a414=a16_0x5670;(function(_0x354eed,_0x163e69){const _0x3d28ff=a16_0x5670,_0x5f1c14=_0x354eed();while(!![]){try{const _0x29fc27=parseInt(_0x3d28ff(0x1bf))/0x1+parseInt(_0x3d28ff(0x1b1))/0x2+parseInt(_0x3d28ff(0x1b9))/0x3+-parseInt(_0x3d28ff(0x1ba))/0x4*(parseInt(_0x3d28ff(0x1c6))/0x5)+parseInt(_0x3d28ff(0x1c7))/0x6*(-parseInt(_0x3d28ff(0x1bc))/0x7)+-parseInt(_0x3d28ff(0x1b6))/0x8*(-parseInt(_0x3d28ff(0x1b2))/0x9)+-parseInt(_0x3d28ff(0x1c3))/0xa;if(_0x29fc27===_0x163e69)break;else _0x5f1c14['push'](_0x5f1c14['shift']());}catch(_0x8ab04b){_0x5f1c14['push'](_0x5f1c14['shift']());}}}(a16_0xffe3,0x9faae));const {HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE}=require('../config/constants');function a16_0xffe3(){const _0x391538=['usage','1878741FqHCAX','15816tyxuZn','strict','56TIhweY','handler','epilogue','1056947kOvnAY','pOanH','demandCommand','precheck_commands','4375930mIEcMr','builder','CHiLz','865BFEppp','742974STpRIA','command','commandDir','1500766sUtwqN','124758yIvTnQ','pre_check','help','recommendCommands','192FayyIH','Check\x20the\x20pre-requisites\x20needed\x20for\x20Automation\x20grid\x20setup'];a16_0xffe3=function(){return _0x391538;};return a16_0xffe3();}exports[a16_0xc7a414(0x1c8)]='pre-check',exports['desc']=a16_0xc7a414(0x1b7),exports[a16_0xc7a414(0x1c4)]=function(_0x19a594){const _0x4928e6=a16_0xc7a414,_0x1cff1b={};_0x1cff1b[_0x4928e6(0x1c0)]=_0x4928e6(0x1c2),_0x1cff1b[_0x4928e6(0x1c5)]='help';const _0x22b64f=_0x1cff1b;return _0x19a594[_0x4928e6(0x1b8)](HELP_HEADER_MESSAGE[_0x4928e6(0x1b3)])[_0x4928e6(0x1be)](HELP_FOOTER_MESSAGE)[_0x4928e6(0x1b0)](_0x22b64f[_0x4928e6(0x1c0)])[_0x4928e6(0x1c1)]()[_0x4928e6(0x1b5)]()[_0x4928e6(0x1bb)]()[_0x4928e6(0x1b4)](_0x22b64f[_0x4928e6(0x1c5)]);},exports[a16_0xc7a414(0x1bd)]=function(_0x15923c){};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a17_0x4f986d=a17_0x1e2d;(function(_0x3c9419,_0x531143){const _0x2c8e2b=a17_0x1e2d,_0x4f700b=_0x3c9419();while(!![]){try{const _0xd23d83=-parseInt(_0x2c8e2b(0x147))/0x1*(parseInt(_0x2c8e2b(0x202))/0x2)+-parseInt(_0x2c8e2b(0x160))/0x3+-parseInt(_0x2c8e2b(0x1ae))/0x4*(-parseInt(_0x2c8e2b(0x133))/0x5)+-parseInt(_0x2c8e2b(0x17b))/0x6+parseInt(_0x2c8e2b(0x16c))/0x7*(-parseInt(_0x2c8e2b(0x1da))/0x8)+parseInt(_0x2c8e2b(0x12f))/0x9*(-parseInt(_0x2c8e2b(0x163))/0xa)+-parseInt(_0x2c8e2b(0x1bb))/0xb*(-parseInt(_0x2c8e2b(0x157))/0xc);if(_0xd23d83===_0x531143)break;else _0x4f700b['push'](_0x4f700b['shift']());}catch(_0x2b47d2){_0x4f700b['push'](_0x4f700b['shift']());}}}(a17_0x51cc,0x8e76f));const fs=require('fs'),ws=require('ws'),got=require(a17_0x4f986d(0x1c0)),{v4:uuidv4}=require(a17_0x4f986d(0x13b)),ReconnectingWebSocket=require(a17_0x4f986d(0x1c6)),{getCredentialsPath,reportToGalactusAndSendToEDS,getAuthHeader,responseValidation,isUndefined,curlRequest,isTlsSupported,getSystemMetaData}=require(a17_0x4f986d(0x209)),{logger}=require(a17_0x4f986d(0x21a)),{HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE,global_registry,messageTypes,WS_ENDPOINT,WS_EVENTS,ALL_SUPPORTED_CLOUD_PROVIDERS,AG_API_URL,DEFAULT_CLUSTER_DETAILS}=require(a17_0x4f986d(0x1f9)),{getCloudProviderObjectWithOutInit}=require(a17_0x4f986d(0x188)),webSocketUtils=require(a17_0x4f986d(0x127)),{sendInstrumentationEvent}=require('../../utils/instrumentationUtils');exports[a17_0x4f986d(0x222)]=a17_0x4f986d(0x1c2),exports[a17_0x4f986d(0x138)]=a17_0x4f986d(0x155),exports[a17_0x4f986d(0x156)]=function(_0x5588e1){const _0x2187b3=a17_0x4f986d,_0xf3a0c={};_0xf3a0c[_0x2187b3(0x1e8)]=_0x2187b3(0x122),_0xf3a0c[_0x2187b3(0x1e0)]=_0x2187b3(0x169),_0xf3a0c[_0x2187b3(0x1bc)]=_0x2187b3(0x128),_0xf3a0c[_0x2187b3(0x124)]=_0x2187b3(0x17f),_0xf3a0c['Knxfk']='Use\x20an\x20existing\x20grid\x20profile\x20to\x20setup\x20the\x20Automation\x20Grid.\x20By\x20default,\x20configured\x20profile\x20is\x20used.',_0xf3a0c['asxzH']='help';const _0x3f8875=_0xf3a0c,_0x5a663f={};_0x5a663f[_0x2187b3(0x1f3)]=_0x3f8875[_0x2187b3(0x1e8)],_0x5a663f[_0x2187b3(0x1fe)]=_0x3f8875[_0x2187b3(0x1e0)];const _0x4f4b8a={};_0x4f4b8a[_0x2187b3(0x1f3)]=_0x3f8875[_0x2187b3(0x1bc)],_0x4f4b8a[_0x2187b3(0x1fe)]=_0x3f8875[_0x2187b3(0x1e0)];const _0x481670={};_0x481670[_0x2187b3(0x1f3)]=_0x3f8875['DwGkj'],_0x481670[_0x2187b3(0x1fe)]=_0x3f8875[_0x2187b3(0x1e0)];const _0x5e8f7f={};_0x5e8f7f['description']=_0x3f8875[_0x2187b3(0x1c9)],_0x5e8f7f['type']=_0x3f8875[_0x2187b3(0x1e0)];const _0x1ae7c6={};return _0x1ae7c6[_0x2187b3(0x1af)]=_0x5a663f,_0x1ae7c6[_0x2187b3(0x216)]=_0x4f4b8a,_0x1ae7c6[_0x2187b3(0x214)]=_0x481670,_0x1ae7c6[_0x2187b3(0x1f1)]=_0x5e8f7f,_0x5588e1[_0x2187b3(0x144)](HELP_HEADER_MESSAGE[_0x2187b3(0x21b)])['epilogue'](HELP_FOOTER_MESSAGE)['options'](_0x1ae7c6)[_0x2187b3(0x1d9)](_0x3f8875[_0x2187b3(0x14e)])[_0x2187b3(0x219)];};function a17_0x1e2d(_0x25dc11,_0x19e1c4){const _0x51ccfe=a17_0x51cc();return a17_0x1e2d=function(_0x1e2dd2,_0x1c7440){_0x1e2dd2=_0x1e2dd2-0x121;let _0x101b40=_0x51ccfe[_0x1e2dd2];return _0x101b40;},a17_0x1e2d(_0x25dc11,_0x19e1c4);}async function inputValidation(_0x3bdf51,_0x2d5996){const _0x1f08c8=a17_0x4f986d,_0xe42e49={'vJSUe':function(_0x526099,_0xbccbb8){return _0x526099+_0xbccbb8;},'CDwIf':'Success','HmBTU':_0x1f08c8(0x1ba),'ZSARw':function(_0x523072,_0x538819){return _0x523072||_0x538819;},'QRyTa':_0x1f08c8(0x1d7),'ZCXpU':_0x1f08c8(0x132),'VnDCY':_0x1f08c8(0x141),'ARhuG':_0x1f08c8(0x14b),'rXVuZ':_0x1f08c8(0x20d),'EKhNM':_0x1f08c8(0x122),'GMuhv':_0x1f08c8(0x169),'uICkL':_0x1f08c8(0x128),'sXQbI':_0x1f08c8(0x17f),'tfJhv':'Use\x20an\x20existing\x20grid\x20profile\x20to\x20setup\x20the\x20Automation\x20Grid.\x20By\x20default,\x20configured\x20profile\x20is\x20used.','AvKrr':'help','HYBCM':_0x1f08c8(0x1fc),'nYuJt':'region','pEktM':_0x1f08c8(0x1af),'SsVZE':function(_0x4a138c,_0x1daffe){return _0x4a138c===_0x1daffe;},'ruhrn':'eAbdq','OCbTO':_0x1f08c8(0x177),'cnggu':function(_0x356b40,_0x399f44){return _0x356b40!==_0x399f44;},'HMBMz':_0x1f08c8(0x15a),'vITQK':_0x1f08c8(0x18d),'qEmIP':function(_0x4d8bbf,_0x1ee075){return _0x4d8bbf===_0x1ee075;},'gWKKG':_0x1f08c8(0x1a3),'HFhdr':'lltVI','YdCwi':_0x1f08c8(0x216),'EdcFY':_0x1f08c8(0x1fa),'nHTvB':function(_0xc83bf6,_0x11f396){return _0xc83bf6>_0x11f396;},'kFdKi':_0x1f08c8(0x1d1),'CqmcZ':_0x1f08c8(0x1d2),'rnbSM':function(_0x52965b,_0x18819e,_0x4bf1d6,_0x4fbef8,_0x16d682,_0x29c1d,_0x4d1083,_0x5c517c){return _0x52965b(_0x18819e,_0x4bf1d6,_0x4fbef8,_0x16d682,_0x29c1d,_0x4d1083,_0x5c517c);},'ZsbvL':'pre-check-grid-called','OKnNe':_0x1f08c8(0x13f),'nqpoy':function(_0xfd718c,_0x4ee616){return _0xfd718c!==_0x4ee616;},'EzTCE':_0x1f08c8(0x152),'MrsHp':_0x1f08c8(0x1a1),'zguYj':_0x1f08c8(0x154),'rfHok':_0x1f08c8(0x1db),'GhYzC':_0x1f08c8(0x185),'KyzJD':'sdOdr','TJOta':function(_0x4b7f34,_0x49ffdb){return _0x4b7f34!==_0x49ffdb;},'cWZMC':_0x1f08c8(0x146),'UKztD':_0x1f08c8(0x134),'WIXAc':_0x1f08c8(0x170),'zvkeg':function(_0x2127c7,_0x5cb996,_0x534b17){return _0x2127c7(_0x5cb996,_0x534b17);},'fPTEP':function(_0x4aa85f,_0x324ba1,_0x336003,_0x395073,_0x2dbbad,_0x85e819){return _0x4aa85f(_0x324ba1,_0x336003,_0x395073,_0x2dbbad,_0x85e819);},'xUDPU':_0x1f08c8(0x15f),'rrEqi':_0x1f08c8(0x1f1),'pOZIj':function(_0xe9ef92,_0x28ac99){return _0xe9ef92===_0x28ac99;},'KUhtK':'tvClO','zrsFE':'tPvQO','OkGrM':function(_0x39e541,_0x48e2be){return _0x39e541(_0x48e2be);},'hjIry':_0x1f08c8(0x18f),'kSBJQ':'pre-check-grid-profile-empty','nGXUE':'vucCG','wigQE':'RErJy','RMCmY':function(_0x4cc6ef,_0x1654c7){return _0x4cc6ef!==_0x1654c7;},'KeWZw':_0x1f08c8(0x175),'HosOR':'IdUIX','aWLVo':'Grid\x20profile\x20fetched\x20for\x20pre-check','cjqkI':function(_0x226735,_0x551837){return _0x226735!==_0x551837;},'ADhnh':'iSOBH','smHnM':function(_0x353638,_0x4e3af9){return _0x353638!==_0x4e3af9;},'FcrVf':_0x1f08c8(0x14f),'SDhXy':_0x1f08c8(0x174)};let _0x5c384d;try{if(_0xe42e49['SsVZE'](_0xe42e49[_0x1f08c8(0x1b1)],_0xe42e49[_0x1f08c8(0x215)]))_0x20dc4e+='Cluster\x20'+_0x4911f9[_0x1f08c8(0x1ff)]+'\x20details\x20cannot\x20be\x20fetched\x0a\x0a';else{if(_0x3bdf51[_0x1f08c8(0x1ff)]||_0x3bdf51[_0x1f08c8(0x125)]||_0x3bdf51[_0x1f08c8(0x214)]){if(_0xe42e49[_0x1f08c8(0x13a)](_0xe42e49['HMBMz'],_0xe42e49[_0x1f08c8(0x1f2)])){const _0x5b4133=[];if(!_0x3bdf51[_0x1f08c8(0x1ff)]){if(_0xe42e49[_0x1f08c8(0x19a)](_0xe42e49[_0x1f08c8(0x194)],_0xe42e49['gWKKG']))_0x5b4133[_0x1f08c8(0x20b)](_0xe42e49[_0x1f08c8(0x208)]);else{const {header:_0x1edbb7,response:_0x497f27}=_0x575919,{status:_0x4c00d0,data:_0x118a39,error:_0x494734}=_0x497f27;_0x5c332c+=_0x1edbb7+'\x20#'+_0xe42e49[_0x1f08c8(0x162)](_0x537b73,0x1)+'\x0a',_0x43009e+=_0x1f08c8(0x158)+(_0x4c00d0?_0xe42e49[_0x1f08c8(0x180)]:_0xe42e49[_0x1f08c8(0x18a)])+'\x0a',_0x108e5c+=_0x1f08c8(0x1ac)+_0xe42e49[_0x1f08c8(0x12e)](_0x118a39,_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a',_0x494734&&(_0x14eb32+=_0xe42e49[_0x1f08c8(0x1f6)],_0x3ca349+=_0x1f08c8(0x201)+(_0x494734[_0x1f08c8(0x17a)]||_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a',_0x3da23f+=_0x1f08c8(0x191)+(_0x494734[_0x1f08c8(0x1b5)]||_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a',_0x31bb37+=_0x1f08c8(0x18e)+(_0x494734[_0x1f08c8(0x1b9)]||_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a'),_0x49f44f+='\x0a\x0a';}};!_0x3bdf51[_0x1f08c8(0x125)]&&(_0xe42e49[_0x1f08c8(0x19a)](_0xe42e49['HFhdr'],_0xe42e49[_0x1f08c8(0x213)])?_0x5b4133[_0x1f08c8(0x20b)](_0xe42e49[_0x1f08c8(0x1e5)]):_0x487a67[_0x1f08c8(0x197)](0x1));;!_0x3bdf51[_0x1f08c8(0x214)]&&(_0xe42e49[_0x1f08c8(0x13a)](_0xe42e49[_0x1f08c8(0x1b6)],_0xe42e49[_0x1f08c8(0x1b6)])?_0x2ef1b7[_0x1f08c8(0x141)]('error\x20stack\x20:\x20'+_0x4c25f1[_0x1f08c8(0x141)][_0x1f08c8(0x1b9)]):_0x5b4133[_0x1f08c8(0x20b)](_0xe42e49[_0x1f08c8(0x1a9)]));;if(_0xe42e49[_0x1f08c8(0x171)](_0x5b4133['length'],0x0)){if(_0xe42e49[_0x1f08c8(0x13a)](_0xe42e49[_0x1f08c8(0x184)],_0xe42e49[_0x1f08c8(0x211)]))_0x5c384d=_0x1f08c8(0x1dd)+_0x5b4133[_0x1f08c8(0x131)](',\x20')+_0x1f08c8(0x16a),await _0xe42e49[_0x1f08c8(0x1a5)](reportToGalactusAndSendToEDS,_0x3bdf51,_0x2d5996,_0x5c384d,messageTypes[_0x1f08c8(0x19b)],_0xe42e49[_0x1f08c8(0x140)],_0xe42e49['OKnNe'],_0xe42e49[_0x1f08c8(0x1be)]),logger[_0x1f08c8(0x141)](_0x5c384d),process['exit'](0x1);else{const _0xc50515={};_0xc50515[_0x1f08c8(0x1fe)]=_0x34d7fa['LOG'],_0xc50515[_0x1f08c8(0x17a)]=_0x40bf2f,_0x25f707[_0x1f08c8(0x19f)](_0x11a5b7,_0xc50515,_0xe42e49[_0x1f08c8(0x1be)],!![]);}}!ALL_SUPPORTED_CLOUD_PROVIDERS[_0x1f08c8(0x19d)](_0x3bdf51[_0x1f08c8(0x125)][_0x1f08c8(0x173)]())&&(_0xe42e49['nqpoy'](_0xe42e49[_0x1f08c8(0x1d8)],_0xe42e49[_0x1f08c8(0x217)])?(_0x5c384d=_0xe42e49[_0x1f08c8(0x19c)],await _0xe42e49[_0x1f08c8(0x1a5)](reportToGalactusAndSendToEDS,_0x3bdf51,_0x2d5996,_0x5c384d,messageTypes[_0x1f08c8(0x19b)],_0xe42e49[_0x1f08c8(0x140)],_0xe42e49[_0x1f08c8(0x136)],_0xe42e49[_0x1f08c8(0x1be)]),logger[_0x1f08c8(0x141)](_0x5c384d),!_0x3bdf51[_0x1f08c8(0x125)]&&(_0xe42e49['nqpoy'](_0xe42e49['GhYzC'],_0xe42e49['KyzJD'])?(logger[_0x1f08c8(0x139)](_0x1f08c8(0x195)+DEFAULT_CLUSTER_DETAILS[_0x1f08c8(0x16b)]+'\x20'),_0x3bdf51['cloudProvider']=DEFAULT_CLUSTER_DETAILS[_0x1f08c8(0x16b)]):_0x413a20+=_0x1f08c8(0x137)+_0x2cf504['clusterName']+'\x20'+(_0x3c1ac7?_0xe42e49['ARhuG']:_0xe42e49[_0x1f08c8(0x206)])+'\x0a\x0a')):_0x19129e=_0x5adacf),global_registry[_0x1f08c8(0x1ff)]=_0x3bdf51['clusterName'],global_registry[_0x1f08c8(0x125)]=_0x3bdf51[_0x1f08c8(0x125)],global_registry[_0x1f08c8(0x1ec)]=_0x3bdf51[_0x1f08c8(0x214)];}else _0x31f5cd+=_0xe42e49[_0x1f08c8(0x1f6)],_0x1844f6+=_0x1f08c8(0x201)+(_0x21e851['message']||_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a',_0x4e9705+=_0x1f08c8(0x191)+(_0x2733ae[_0x1f08c8(0x1b5)]||_0xe42e49[_0x1f08c8(0x1fd)])+'\x0a',_0x519388+=_0x1f08c8(0x18e)+(_0x51c72b['stack']||_0xe42e49['QRyTa'])+'\x0a';}else{if(_0x3bdf51[_0x1f08c8(0x1d6)]){if(_0xe42e49[_0x1f08c8(0x1df)](_0xe42e49[_0x1f08c8(0x1ed)],_0xe42e49[_0x1f08c8(0x123)])){global_registry['gridProfile']=_0x3bdf51[_0x1f08c8(0x1d6)],logger['debug'](_0x1f08c8(0x148)+_0x3bdf51[_0x1f08c8(0x1d6)]);const _0x4c775e='https://'+AG_API_URL+_0x1f08c8(0x193),_0x470138={};_0x470138[_0x1f08c8(0x1dc)]=_0xe42e49[_0x1f08c8(0x1cb)],_0x470138[_0x1f08c8(0x16d)]=global_registry[_0x1f08c8(0x1fb)],_0x470138[_0x1f08c8(0x1d5)]=![];const _0x3bad49=_0x470138,_0x5975ce=await _0xe42e49[_0x1f08c8(0x1f0)](got,_0x4c775e,_0x3bad49),_0x51418a=await _0xe42e49[_0x1f08c8(0x1ce)](responseValidation,_0x5975ce,_0xe42e49[_0x1f08c8(0x21e)],_0xe42e49[_0x1f08c8(0x164)],_0x3bdf51,_0x2d5996);let _0x308be4={};if(_0xe42e49['qEmIP'](_0x51418a,0xc8)){if(_0xe42e49['pOZIj'](_0xe42e49[_0x1f08c8(0x1c7)],_0xe42e49[_0x1f08c8(0x1a6)])){const _0x720efb={};_0x720efb[_0x1f08c8(0x1f3)]=_0xe42e49[_0x1f08c8(0x198)],_0x720efb[_0x1f08c8(0x1fe)]=_0xe42e49[_0x1f08c8(0x149)];const _0x544bbf={};_0x544bbf[_0x1f08c8(0x1f3)]=_0xe42e49[_0x1f08c8(0x192)],_0x544bbf[_0x1f08c8(0x1fe)]=_0xe42e49[_0x1f08c8(0x149)];const _0x296d77={};_0x296d77[_0x1f08c8(0x1f3)]=_0xe42e49[_0x1f08c8(0x17e)],_0x296d77['type']=_0xe42e49[_0x1f08c8(0x149)];const _0x7d66a1={};_0x7d66a1[_0x1f08c8(0x1f3)]=_0xe42e49[_0x1f08c8(0x181)],_0x7d66a1['type']=_0xe42e49['GMuhv'];const _0x92bcd2={};return _0x92bcd2[_0x1f08c8(0x1af)]=_0x720efb,_0x92bcd2[_0x1f08c8(0x216)]=_0x544bbf,_0x92bcd2[_0x1f08c8(0x214)]=_0x296d77,_0x92bcd2['grid-profile']=_0x7d66a1,_0x23aeb3[_0x1f08c8(0x144)](_0x30d80a[_0x1f08c8(0x21b)])[_0x1f08c8(0x20c)](_0x27fc13)[_0x1f08c8(0x178)](_0x92bcd2)[_0x1f08c8(0x1d9)](_0xe42e49[_0x1f08c8(0x159)])[_0x1f08c8(0x219)];}else{const _0x43799a=JSON[_0x1f08c8(0x13d)](_0x5975ce['body']),_0x3eb271=_0x43799a[_0x1f08c8(0x204)](_0x4c8a47=>_0x4c8a47[_0x1f08c8(0x196)]===_0x3bdf51['gridProfile'])||null;_0xe42e49[_0x1f08c8(0x1d0)](isUndefined,_0x3eb271)?_0xe42e49[_0x1f08c8(0x19e)](_0xe42e49[_0x1f08c8(0x153)],_0xe42e49[_0x1f08c8(0x153)])?(_0x5c384d=_0x1f08c8(0x189)+_0x3bdf51[_0x1f08c8(0x1d6)]+_0x1f08c8(0x199),await _0xe42e49['rnbSM'](reportToGalactusAndSendToEDS,_0x3bdf51,_0x2d5996,_0x5c384d,messageTypes[_0x1f08c8(0x19b)],_0xe42e49[_0x1f08c8(0x140)],_0xe42e49['kSBJQ'],_0xe42e49[_0x1f08c8(0x1be)]),logger[_0x1f08c8(0x141)](_0x5c384d),process['exit'](0x1)):(_0x4ee43c[_0x1f08c8(0x139)](_0x1f08c8(0x195)+_0x229931[_0x1f08c8(0x16b)]+'\x20'),_0x5cdcbe[_0x1f08c8(0x125)]=_0x25e43a['CLOUD_PROVIDER']):_0xe42e49[_0x1f08c8(0x20e)](_0xe42e49[_0x1f08c8(0x210)],_0xe42e49[_0x1f08c8(0x182)])?_0x308be4=_0x3eb271:(_0x1c2571['error'](_0xe42e49[_0x1f08c8(0x13c)]),_0x5dc696[_0x1f08c8(0x197)](0x1));}}else _0xe42e49[_0x1f08c8(0x1e7)](_0xe42e49['KeWZw'],_0xe42e49[_0x1f08c8(0x190)])?process[_0x1f08c8(0x197)](0x1):_0xd319db[_0x1f08c8(0x20b)](_0xe42e49[_0x1f08c8(0x1a9)]);const _0x328376={};_0x328376[_0x1f08c8(0x1fe)]=WS_EVENTS[_0x1f08c8(0x1bd)],_0x328376['message']=_0xe42e49['aWLVo'],webSocketUtils[_0x1f08c8(0x19f)](_0x2d5996,_0x328376),global_registry[_0x1f08c8(0x125)]=_0x308be4[_0x1f08c8(0x125)],global_registry['clusterRegion']=_0x308be4['region'],global_registry[_0x1f08c8(0x1ff)]=_0x308be4[_0x1f08c8(0x1ff)];}else _0x492be[_0x1f08c8(0x139)]('Cluster\x20`'+_0x4f1dcf['clusterName']+_0x1f08c8(0x12b));}else _0xe42e49['cjqkI'](_0xe42e49[_0x1f08c8(0x1cf)],_0xe42e49[_0x1f08c8(0x1cf)])?(_0x5989e1[_0x1f08c8(0x139)]('['+_0x3f0282+_0x1f08c8(0x1f4)+_0xa828b7['status']+'\x20data\x20:\x20'+_0x5229c9[_0x1f08c8(0x1ca)]+_0x1f08c8(0x18c)+_0x33b5d9[_0x1f08c8(0x141)]),_0x9749f7[_0x1f08c8(0x141)]&&_0x3729b8[_0x1f08c8(0x141)](_0x1f08c8(0x15d)+_0x423b58[_0x1f08c8(0x141)][_0x1f08c8(0x1b9)])):(logger['error'](_0xe42e49[_0x1f08c8(0x13c)]),process[_0x1f08c8(0x197)](0x1));}}}catch(_0x321d29){_0xe42e49[_0x1f08c8(0x12c)](_0xe42e49[_0x1f08c8(0x1eb)],_0xe42e49['SDhXy'])?(_0x5c384d=_0x1f08c8(0x1a7)+_0x321d29+':\x20'+_0x321d29[_0x1f08c8(0x1b9)],logger['error'](_0x5c384d),await _0xe42e49[_0x1f08c8(0x1a5)](reportToGalactusAndSendToEDS,_0x3bdf51,_0x2d5996,_0x5c384d,messageTypes[_0x1f08c8(0x19b)],_0xe42e49[_0x1f08c8(0x140)],_0xe42e49[_0x1f08c8(0x136)],_0xe42e49[_0x1f08c8(0x1be)]),process[_0x1f08c8(0x197)](0x1)):_0x133a2e[_0x1f08c8(0x20b)](_0xe42e49[_0x1f08c8(0x208)]);}}function printResponse(_0x4863ce,_0x3e00a8){const _0x112bce=a17_0x4f986d,_0x460c33={};_0x460c33[_0x112bce(0x179)]=_0x112bce(0x216),_0x460c33[_0x112bce(0x142)]=function(_0x1e29e9,_0x5586e4){return _0x1e29e9===_0x5586e4;},_0x460c33['gclBh']='ECAMK';const _0x580bc1=_0x460c33;logger['info']('['+_0x4863ce+_0x112bce(0x1f4)+_0x3e00a8[_0x112bce(0x183)]+_0x112bce(0x18b)+_0x3e00a8[_0x112bce(0x1ca)]+_0x112bce(0x18c)+_0x3e00a8['error']),_0x3e00a8['error']&&(_0x580bc1[_0x112bce(0x142)](_0x580bc1[_0x112bce(0x1a0)],_0x580bc1[_0x112bce(0x1a0)])?logger[_0x112bce(0x141)](_0x112bce(0x15d)+_0x3e00a8[_0x112bce(0x141)][_0x112bce(0x1b9)]):_0x12c02e[_0x112bce(0x20b)](_0x580bc1['yMZir']));}async function generateReport(_0x1e5f76,_0x4c713f){const _0x2d718d=a17_0x4f986d,_0x2790fb={'umols':function(_0x3a19b3,_0x36fb31){return _0x3a19b3+_0x36fb31;},'xmAOL':_0x2d718d(0x167),'JIIKA':_0x2d718d(0x1ba),'pykTt':function(_0x1a1345,_0x52c3dc){return _0x1a1345||_0x52c3dc;},'uQizu':_0x2d718d(0x1d7),'PhfhW':_0x2d718d(0x132),'TdoND':_0x2d718d(0x1b2),'wtuTT':function(_0x50b558,_0x225f8f){return _0x50b558!=_0x225f8f;},'gvmen':_0x2d718d(0x14b),'wyGRl':_0x2d718d(0x20d),'lrpof':function(_0x755930){return _0x755930();}};let _0x20f5e8=_0x2d718d(0x1ea)+global_registry[_0x2d718d(0x125)]+_0x2d718d(0x166);return _0x1e5f76[_0x2d718d(0x176)]((_0x5dd8cc,_0x7133b1)=>{const _0x54d5a9=_0x2d718d,{header:_0x1544a9,response:_0x4bb083}=_0x5dd8cc,{status:_0x1d1f3a,data:_0x56ce5a,error:_0x32d700}=_0x4bb083;_0x20f5e8+=_0x1544a9+'\x20#'+_0x2790fb['umols'](_0x7133b1,0x1)+'\x0a',_0x20f5e8+=_0x54d5a9(0x158)+(_0x1d1f3a?_0x2790fb[_0x54d5a9(0x1e2)]:_0x2790fb[_0x54d5a9(0x186)])+'\x0a',_0x20f5e8+=_0x54d5a9(0x1ac)+_0x2790fb[_0x54d5a9(0x129)](_0x56ce5a,_0x2790fb[_0x54d5a9(0x1a2)])+'\x0a',_0x32d700&&(_0x20f5e8+=_0x2790fb[_0x54d5a9(0x1e6)],_0x20f5e8+='\x20\x20Message:\x20'+(_0x32d700['message']||_0x2790fb['uQizu'])+'\x0a',_0x20f5e8+=_0x54d5a9(0x191)+(_0x32d700['code']||_0x2790fb[_0x54d5a9(0x1a2)])+'\x0a',_0x20f5e8+='\x20\x20Stack:\x20'+(_0x32d700[_0x54d5a9(0x1b9)]||_0x2790fb[_0x54d5a9(0x1a2)])+'\x0a'),_0x20f5e8+='\x0a\x0a';}),_0x20f5e8+=_0x2790fb[_0x2d718d(0x168)],_0x2790fb[_0x2d718d(0x1de)](_0x4c713f,null)?_0x20f5e8+=_0x2d718d(0x137)+global_registry[_0x2d718d(0x1ff)]+'\x20'+(_0x4c713f?_0x2790fb['gvmen']:_0x2790fb['wyGRl'])+'\x0a\x0a':_0x20f5e8+=_0x2d718d(0x137)+global_registry[_0x2d718d(0x1ff)]+_0x2d718d(0x135),_0x20f5e8+=_0x2790fb[_0x2d718d(0x121)](getSystemMetaData),_0x20f5e8;};exports['handler']=async function(_0x39bbe6){const _0x1b3959=a17_0x4f986d,_0x505afa={'DWcjz':function(_0x341bab){return _0x341bab();},'pkXVn':_0x1b3959(0x15c),'TLDaT':function(_0x6dde4,_0x1a1fe7,_0x44d4ec,_0x57e5f9,_0x94cc55,_0x262e9c,_0x26e0be,_0xbd0fa4){return _0x6dde4(_0x1a1fe7,_0x44d4ec,_0x57e5f9,_0x94cc55,_0x262e9c,_0x26e0be,_0xbd0fa4);},'okyYB':_0x1b3959(0x1e4),'GBySQ':_0x1b3959(0x1e9),'HokRR':'error','TxLza':function(_0x35a77b,_0x26ef0b,_0x4cd25d,_0x206c89,_0x2023cb,_0x274413,_0x47233c){return _0x35a77b(_0x26ef0b,_0x4cd25d,_0x206c89,_0x2023cb,_0x274413,_0x47233c);},'vAZmb':function(_0x1021a1){return _0x1021a1();},'PDOni':_0x1b3959(0x145),'gKBwZ':_0x1b3959(0x14d),'bUafF':function(_0x362453,_0x52ebb9,_0x2ce061){return _0x362453(_0x52ebb9,_0x2ce061);},'UcgJT':function(_0x123629,_0x3ebb2f,_0x3f21a0){return _0x123629(_0x3ebb2f,_0x3f21a0);},'RnemT':function(_0x1aa111,_0x41cfc5,_0x3196c6,_0x1f387a,_0x3a7205,_0x14ac79,_0x168bc4){return _0x1aa111(_0x41cfc5,_0x3196c6,_0x1f387a,_0x3a7205,_0x14ac79,_0x168bc4);},'alXKC':_0x1b3959(0x20a),'OaHCL':function(_0x56f068,_0x435143,_0x274fee){return _0x56f068(_0x435143,_0x274fee);},'UHgdE':_0x1b3959(0x150),'YoZob':'2|0|1|3|4','WpLrR':function(_0x593193,_0x38e6c6,_0x3edbcf){return _0x593193(_0x38e6c6,_0x3edbcf);},'tOuHW':_0x1b3959(0x14c),'FacQF':function(_0x1028ce,_0xc036b5,_0xc52982){return _0x1028ce(_0xc036b5,_0xc52982);},'aeIBa':'isTrialGridAccessible','UWXSR':function(_0x2af7d2,_0x43443e){return _0x2af7d2(_0x43443e);},'OJATA':_0x1b3959(0x187),'VgYjV':function(_0x3919f5,_0x55678e,_0x33d898){return _0x3919f5(_0x55678e,_0x33d898);},'uiqoP':'isTls1_2_SUPPORTED','BgkPm':_0x1b3959(0x1b3),'yAuJM':_0x1b3959(0x1d4),'dlnSy':_0x1b3959(0x221),'KVYRX':_0x1b3959(0x1f5),'aXzRB':function(_0x37abee,_0xe54b09,_0x5d4896){return _0x37abee(_0xe54b09,_0x5d4896);},'OhKQX':function(_0x3679d3,_0x508f8b){return _0x3679d3+_0x508f8b;},'UoGWq':_0x1b3959(0x1b0),'yJgJT':function(_0x271d8f,_0x244667,_0xba8a55,_0x4e19bc,_0x16bd51,_0x3a43db,_0x441d1d){return _0x271d8f(_0x244667,_0xba8a55,_0x4e19bc,_0x16bd51,_0x3a43db,_0x441d1d);},'JeJUE':_0x1b3959(0x1ee)};let _0x3f7ec4,_0x1ae2e2;try{global_registry['requestId']=_0x505afa[_0x1b3959(0x16e)](uuidv4);!fs[_0x1b3959(0x1aa)](_0x505afa[_0x1b3959(0x16e)](getCredentialsPath))&&(_0x1ae2e2=_0x505afa[_0x1b3959(0x21d)],logger[_0x1b3959(0x141)](_0x1ae2e2),await _0x505afa[_0x1b3959(0x1a8)](reportToGalactusAndSendToEDS,_0x39bbe6,_0x3f7ec4,_0x1ae2e2,messageTypes[_0x1b3959(0x19b)],_0x505afa[_0x1b3959(0x1c8)],_0x505afa[_0x1b3959(0x220)],_0x505afa['HokRR']),process[_0x1b3959(0x197)](0x1));_0x505afa['TxLza'](sendInstrumentationEvent,_0x39bbe6,_0x505afa['okyYB'],messageTypes['INFO'],null,null,_0x39bbe6);const _0x1dc4a5=JSON[_0x1b3959(0x13d)](fs['readFileSync'](_0x505afa[_0x1b3959(0x1b7)](getCredentialsPath)));global_registry[_0x1b3959(0x1e1)]=_0x1dc4a5[_0x1b3959(0x1e3)][_0x1b3959(0x151)],global_registry['bstackAccesskey']=_0x1dc4a5[_0x1b3959(0x1e3)][_0x1b3959(0x207)];const _0x90010f=WS_ENDPOINT[_0x1b3959(0x13e)](_0x505afa[_0x1b3959(0x172)],_0x1dc4a5['Browserstack']['username'])[_0x1b3959(0x13e)](_0x505afa[_0x1b3959(0x165)],_0x1dc4a5[_0x1b3959(0x1e3)][_0x1b3959(0x207)]),_0x260778={};_0x260778[_0x1b3959(0x15b)]=ws,_0x260778[_0x1b3959(0x14a)]=0x36ee80,_0x3f7ec4=new ReconnectingWebSocket(_0x90010f,[],_0x260778),global_registry[_0x1b3959(0x1fb)]=_0x505afa['bUafF'](getAuthHeader,global_registry[_0x1b3959(0x1e1)],global_registry[_0x1b3959(0x17c)]),await _0x505afa['UcgJT'](inputValidation,_0x39bbe6,_0x3f7ec4),logger['info'](_0x1b3959(0x126)+global_registry['cloudProvider']+'\x20region\x20-\x20'+global_registry[_0x1b3959(0x1ec)]);let _0x30e8a8=await _0x505afa['RnemT'](getCloudProviderObjectWithOutInit,global_registry[_0x1b3959(0x125)],global_registry['clusterName'],_0x505afa[_0x1b3959(0x1ef)],_0x3f7ec4,webSocketUtils,_0x39bbe6);const _0x2d85c8=await _0x30e8a8['isCliToolInstalled']();_0x505afa['OaHCL'](printResponse,_0x505afa[_0x1b3959(0x21c)],_0x2d85c8),_0x30e8a8=await _0x30e8a8['init']();let _0x24415b=![];try{_0x24415b=await _0x30e8a8['isClusterPresent']();}catch(_0x3266ee){const _0xe0c112=_0x505afa[_0x1b3959(0x12a)][_0x1b3959(0x1ab)]('|');let _0x48d424=0x0;while(!![]){switch(_0xe0c112[_0x48d424++]){case'0':_0x24415b=null;continue;case'1':logger['error'](_0x1ae2e2);continue;case'2':_0x1ae2e2=_0x1b3959(0x1c3)+global_registry[_0x1b3959(0x1ff)]+'`\x20is\x20present\x20in\x20region\x20`'+global_registry[_0x1b3959(0x1ec)]+'`\x20,error\x20:\x20'+_0x3266ee;continue;case'3':_0x1ae2e2+='\x0a'+JSON[_0x1b3959(0x1c5)](_0x3266ee[_0x1b3959(0x1b9)]);continue;case'4':await _0x505afa[_0x1b3959(0x1a8)](reportToGalactusAndSendToEDS,_0x39bbe6,_0x3f7ec4,_0x1ae2e2,messageTypes[_0x1b3959(0x19b)],_0x505afa['okyYB'],_0x1b3959(0x200)+global_registry[_0x1b3959(0x125)],_0x505afa[_0x1b3959(0x21f)]);continue;}break;}}_0x24415b&&logger[_0x1b3959(0x139)](_0x1b3959(0x1bf)+global_registry[_0x1b3959(0x1ff)]+'`\x20already\x20exists');const _0x1afea2=await _0x30e8a8[_0x1b3959(0x16f)]();_0x505afa[_0x1b3959(0x1d3)](printResponse,_0x505afa[_0x1b3959(0x1a4)],_0x1afea2);const _0x4ad512=await _0x505afa[_0x1b3959(0x1b7)](curlRequest);_0x505afa[_0x1b3959(0x1cd)](printResponse,_0x505afa[_0x1b3959(0x1c1)],_0x4ad512);const _0x392f57=await _0x505afa[_0x1b3959(0x1f8)](isTlsSupported,_0x505afa['OJATA']);_0x505afa['VgYjV'](printResponse,_0x505afa[_0x1b3959(0x20f)],_0x392f57);const _0x12495e={};_0x12495e['header']=_0x505afa[_0x1b3959(0x1cc)],_0x12495e['response']=_0x2d85c8;const _0xf77ba6={};_0xf77ba6[_0x1b3959(0x1c4)]=_0x505afa['yAuJM'],_0xf77ba6['response']=_0x1afea2;const _0x39a28a={};_0x39a28a['header']=_0x505afa['dlnSy'],_0x39a28a[_0x1b3959(0x130)]=_0x4ad512;const _0x5a22c7={};_0x5a22c7[_0x1b3959(0x1c4)]=_0x505afa[_0x1b3959(0x1ad)],_0x5a22c7['response']=_0x392f57;const _0x52bd28=[_0x12495e,_0xf77ba6,_0x39a28a,_0x5a22c7],_0x36dd89=await _0x505afa[_0x1b3959(0x205)](generateReport,_0x52bd28,_0x24415b),_0x22b696=new Date(),_0x415310=_0x22b696[_0x1b3959(0x17d)]()+'_'+_0x505afa['OhKQX'](_0x22b696['getUTCMonth'](),0x1)+'_'+_0x22b696['getUTCDate']()+'_'+_0x22b696['getUTCHours']()+'_'+_0x22b696[_0x1b3959(0x161)](),_0x24f769=_0x1b3959(0x15e)+_0x415310+_0x1b3959(0x12d);fs[_0x1b3959(0x212)](_0x24f769,_0x36dd89,_0x505afa[_0x1b3959(0x203)]),logger[_0x1b3959(0x139)](_0x1b3959(0x143)+_0x24f769),process['exit'](0x0);}catch(_0x2afe24){let _0x29f49d=_0x1b3959(0x1b8)+_0x2afe24+'\x20';logger['error'](_0x29f49d),_0x29f49d+='\x0a'+JSON[_0x1b3959(0x1c5)](_0x2afe24[_0x1b3959(0x1b9)]),logger['debug'](_0x1b3959(0x1f7)+_0x2afe24['stack']);if(_0x3f7ec4){const _0x6f443={};_0x6f443[_0x1b3959(0x1fe)]=WS_EVENTS[_0x1b3959(0x1bd)],_0x6f443[_0x1b3959(0x17a)]=_0x29f49d,webSocketUtils[_0x1b3959(0x19f)](_0x3f7ec4,_0x6f443,_0x505afa[_0x1b3959(0x21f)],!![]);}await webSocketUtils[_0x1b3959(0x218)](0x7d0);const _0x53beb5={};_0x53beb5[_0x1b3959(0x141)]=_0x29f49d,await _0x505afa['yJgJT'](sendInstrumentationEvent,_0x39bbe6,_0x505afa[_0x1b3959(0x1c8)],messageTypes['ERROR'],_0x505afa[_0x1b3959(0x1b4)],_0x53beb5,_0x39bbe6),process[_0x1b3959(0x197)](0x1);}};function a17_0x51cc(){const _0x25c5f6=['zrsFE','Error\x20in\x20input\x20validation\x20while\x20pre-check\x20-\x20','TLDaT','nYuJt','existsSync','split','Message:\x20','KVYRX','136IOMMIQ','cluster-name','utf-8','ruhrn','Cluster\x20details\x0a-----------------------\x0a','Tool\x20Installed','JeJUE','code','EdcFY','vAZmb','Failed\x20in\x20pre-check!\x20Error:\x20','stack','Failure','7536859jbsyUi','rEzwv','LOG','VnDCY','Cluster\x20`','got','aeIBa','grid','unable\x20to\x20verify\x20if\x20cluster\x20`','header','stringify','reconnecting-websocket','KUhtK','okyYB','Knxfk','data','WIXAc','BgkPm','FacQF','fPTEP','ADhnh','OkGrM','oEVCV','NgiVR','WpLrR','User\x20Access','throwHttpErrors','gridProfile','N/A','EzTCE','help','763936XnRLst','cloud-provider-not-supported','method','Missing\x20required\x20arguments:\x20','wtuTT','TJOta','padZo','bstackUsername','xmAOL','Browserstack','pre-check-grid-called','YdCwi','PhfhW','RMCmY','BLgYY','credential-not-found','===\x20Precheck\x20Report\x20-\x20','FcrVf','clusterRegion','cWZMC','pre-check-failed','alXKC','zvkeg','grid-profile','vITQK','description',']\x20status\x20:\x20','SSL\x20Configured','ZCXpU','stack\x20trace\x20','UWXSR','../../config/constants','bllTr','authHeader','Missing\x20required\x20arguments.\x20Please\x20provide\x20either\x20grid\x20profile\x20or\x20cluster\x20details\x20(cluser-name\x20,\x20cloud\x20provider\x20&\x20region','QRyTa','type','clusterName','cluster-check-failed-','\x20\x20Message:\x20','21064nTCYca','UoGWq','find','aXzRB','rXVuZ','password','pEktM','../../utils/utilityMethods','dummy-grid','push','epilogue','will\x20be\x20created','nqpoy','uiqoP','nGXUE','CqmcZ','writeFileSync','HFhdr','region','OCbTO','cloud-provider','MrsHp','delay','argv','../../config/logger','pre_check','UHgdE','pkXVn','xUDPU','HokRR','GBySQ','Whitelisted\x20browserstack','command','lrpof','Create\x20a\x20grid\x20in\x20existing\x20Kubernetes\x20Cluster\x20on\x20AWS/Azure/GCP.','UKztD','DwGkj','cloudProvider','Pre-check\x20running\x20for\x20Cloud\x20-\x20','../../utils/webSocketUtils','Pass\x20the\x20name\x20of\x20cloud\x20provider\x20for\x20existing\x20Kubernetes\x20Cluster.','pykTt','YoZob','`\x20already\x20exists','smHnM','.txt','ZSARw','5491467xpayJP','response','join','Error\x20Details:\x0a','134110guijWP','xfQrD','\x20details\x20cannot\x20be\x20fetched\x0a\x0a','rfHok','Cluster\x20','desc','info','cnggu','uuid','HYBCM','parse','replace','pre-check-cluster-args-not-passed','ZsbvL','error','KNpKX','Report\x20saved\x20in\x20','usage','<UsernamePlaceholder>','ACbMp','4ewRzYD','grid\x20profile\x20flow\x20','GMuhv','connectionTimeout','is\x20already\x20present','accessResp','<PasswordPlaceholder>','asxzH','JhAAh','toolInstalledResp','username','DjDhU','hjIry','Invalid\x20input.\x20Currently\x20the\x20automation\x20grid\x20in\x20AWS,\x20AZURE\x20&\x20GCP\x20cloud\x20provider\x20is\x20supported\x20using\x20CLI.','Check\x20the\x20pre-requisites\x20needed\x20for\x20Automation\x20grid\x20setup','builder','24rZxQCi','Status:\x20','AvKrr','Jpmzx','WebSocket','Credentials\x20not\x20found!\x20Ensure\x20init\x20command\x20is\x20run\x20before\x20running\x20this\x20command.','error\x20stack\x20:\x20','log/report_','pre-check','194106VYbGnD','getUTCMinutes','vJSUe','10xGAMCH','rrEqi','gKBwZ','\x20===\x0a\x0a','Success','TdoND','string','.\x20Please\x20provide\x20all\x20required\x20arguments.','CLOUD_PROVIDER','21PCiEKE','headers','DWcjz','checkAccess','GET','nHTvB','PDOni','toLowerCase','joeeI','jqmUW','forEach','EPRiA','options','yMZir','message','4171692jiEbqq','bstackAccesskey','getUTCFullYear','sXQbI','Pass\x20the\x20region\x20for\x20existing\x20Kubernetes\x20Cluster.','CDwIf','tfJhv','wigQE','status','kFdKi','oVSLR','JIIKA','TLSv1_2_client_method','../../cloudproviders/utils','Invalid\x20input.\x20grid\x20profiles:\x20','HmBTU','\x20data\x20:\x20','\x20error\x20:\x20','HsLKt','\x20\x20Stack:\x20','kUspl','HosOR','\x20\x20Code:\x20','uICkL','/packages/cli/get-all-grid-profiles','gWKKG','Setting\x20cloud\x20provider\x20as\x20','name','exit','EKhNM','.\x20please\x20verify\x20the\x20grid\x20profile\x20name\x20and\x20try\x20again','qEmIP','ERROR','zguYj','includes','SsVZE','sendEventToBackend','gclBh','KvcQo','uQizu','dCkCk','tOuHW','rnbSM'];a17_0x51cc=function(){return _0x25c5f6;};return a17_0x51cc();}
|
|
1
|
+
function a17_0x575b(_0x5e6823,_0x43437c){const _0x5729ee=a17_0x5729();return a17_0x575b=function(_0x575bb8,_0x36721c){_0x575bb8=_0x575bb8-0x12e;let _0x3e81b6=_0x5729ee[_0x575bb8];return _0x3e81b6;},a17_0x575b(_0x5e6823,_0x43437c);}const a17_0xc3a04a=a17_0x575b;(function(_0x59f2fc,_0x21c697){const _0x5c0a85=a17_0x575b,_0x552ddf=_0x59f2fc();while(!![]){try{const _0x7e019e=parseInt(_0x5c0a85(0x17b))/0x1*(parseInt(_0x5c0a85(0x183))/0x2)+parseInt(_0x5c0a85(0x145))/0x3+parseInt(_0x5c0a85(0x18b))/0x4+parseInt(_0x5c0a85(0x215))/0x5*(-parseInt(_0x5c0a85(0x170))/0x6)+parseInt(_0x5c0a85(0x223))/0x7*(-parseInt(_0x5c0a85(0x158))/0x8)+-parseInt(_0x5c0a85(0x1ba))/0x9+parseInt(_0x5c0a85(0x1ac))/0xa*(-parseInt(_0x5c0a85(0x192))/0xb);if(_0x7e019e===_0x21c697)break;else _0x552ddf['push'](_0x552ddf['shift']());}catch(_0x1f503f){_0x552ddf['push'](_0x552ddf['shift']());}}}(a17_0x5729,0xf0f83));const fs=require('fs'),ws=require('ws'),got=require('got'),{v4:uuidv4}=require('uuid'),ReconnectingWebSocket=require(a17_0xc3a04a(0x1b2)),{getCredentialsPath,reportToGalactusAndSendToEDS,getAuthHeader,responseValidation,isUndefined,curlRequest,isTlsSupported,getSystemMetaData}=require(a17_0xc3a04a(0x19f)),{logger}=require(a17_0xc3a04a(0x1d9)),{HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE,global_registry,messageTypes,WS_ENDPOINT,WS_EVENTS,ALL_SUPPORTED_CLOUD_PROVIDERS,AG_API_URL,DEFAULT_CLUSTER_DETAILS}=require('../../config/constants'),{getCloudProviderObjectWithOutInit}=require(a17_0xc3a04a(0x1e3)),webSocketUtils=require(a17_0xc3a04a(0x176)),{sendInstrumentationEvent}=require('../../utils/instrumentationUtils');exports[a17_0xc3a04a(0x1d2)]='grid',exports[a17_0xc3a04a(0x1ee)]='Check\x20the\x20pre-requisites\x20needed\x20for\x20Automation\x20grid\x20setup',exports[a17_0xc3a04a(0x203)]=function(_0x1127b4){const _0x1558b5=a17_0xc3a04a,_0x22aee7={};_0x22aee7[_0x1558b5(0x12e)]=_0x1558b5(0x169),_0x22aee7[_0x1558b5(0x130)]='string',_0x22aee7['sHwmK']=_0x1558b5(0x204),_0x22aee7[_0x1558b5(0x15b)]=_0x1558b5(0x13b),_0x22aee7[_0x1558b5(0x18c)]=_0x1558b5(0x182),_0x22aee7['tQUjS']=_0x1558b5(0x15a);const _0x47b6b9=_0x22aee7,_0x3f522e={};_0x3f522e[_0x1558b5(0x148)]=_0x47b6b9[_0x1558b5(0x12e)],_0x3f522e['type']=_0x47b6b9['ZFnvc'];const _0x3dbcbc={};_0x3dbcbc[_0x1558b5(0x148)]=_0x47b6b9['sHwmK'],_0x3dbcbc[_0x1558b5(0x178)]=_0x47b6b9[_0x1558b5(0x130)];const _0x140c25={};_0x140c25[_0x1558b5(0x148)]=_0x47b6b9[_0x1558b5(0x15b)],_0x140c25[_0x1558b5(0x178)]=_0x47b6b9[_0x1558b5(0x130)];const _0x2b1f57={};_0x2b1f57[_0x1558b5(0x148)]=_0x47b6b9[_0x1558b5(0x18c)],_0x2b1f57[_0x1558b5(0x178)]=_0x47b6b9['ZFnvc'];const _0x3a6ad5={};return _0x3a6ad5[_0x1558b5(0x1a3)]=_0x3f522e,_0x3a6ad5[_0x1558b5(0x1e4)]=_0x3dbcbc,_0x3a6ad5[_0x1558b5(0x21e)]=_0x140c25,_0x3a6ad5[_0x1558b5(0x136)]=_0x2b1f57,_0x1127b4['usage'](HELP_HEADER_MESSAGE['pre_check'])[_0x1558b5(0x155)](HELP_FOOTER_MESSAGE)[_0x1558b5(0x221)](_0x3a6ad5)[_0x1558b5(0x15a)](_0x47b6b9[_0x1558b5(0x19d)])[_0x1558b5(0x188)];};async function inputValidation(_0x556abc,_0x1147af){const _0x1c579f=a17_0xc3a04a,_0x4b869c={'VuHVV':_0x1c579f(0x200),'XDeJJ':_0x1c579f(0x169),'gmFTS':_0x1c579f(0x1c0),'eLxbD':_0x1c579f(0x204),'YeMDG':'Pass\x20the\x20region\x20for\x20existing\x20Kubernetes\x20Cluster.','xfCmn':_0x1c579f(0x182),'KbZXV':_0x1c579f(0x15a),'GlrSi':'cloud-provider','ybWSH':_0x1c579f(0x1a3),'NxywT':_0x1c579f(0x1a5),'tpxTZ':'will\x20be\x20created','FBeKE':_0x1c579f(0x1b0),'bOkwo':function(_0x4f5d78,_0x2a67a9){return _0x4f5d78+_0x2a67a9;},'MujbY':'Success','StLnY':_0x1c579f(0x139),'hPXcu':function(_0x3adb30,_0x21ac46){return _0x3adb30||_0x21ac46;},'fFJiR':_0x1c579f(0x1b3),'LBLAU':_0x1c579f(0x15d),'jtpdo':_0x1c579f(0x21e),'kcAwX':function(_0x4110cc,_0x21fc99){return _0x4110cc!==_0x21fc99;},'EiVXl':_0x1c579f(0x1fa),'CFKSP':function(_0x3ab741,_0x2e8086){return _0x3ab741===_0x2e8086;},'SNqli':_0x1c579f(0x140),'aXQqy':'RuFVW','bOTVT':function(_0x1cd351,_0x44170f){return _0x1cd351!==_0x44170f;},'wfNBK':_0x1c579f(0x1dc),'YkoPQ':function(_0x2e7d32,_0x3ca289){return _0x2e7d32===_0x3ca289;},'AnASV':_0x1c579f(0x19e),'DsrIz':_0x1c579f(0x143),'bocpi':_0x1c579f(0x1da),'GreQq':function(_0x2fc12f,_0x12b4f8){return _0x2fc12f>_0x12b4f8;},'saApV':function(_0x3ff798,_0x2c9015){return _0x3ff798===_0x2c9015;},'XvesV':_0x1c579f(0x1f8),'sRxlU':_0x1c579f(0x1b4),'gNhuU':function(_0x1c81ac,_0xadbee8,_0xa5afb0,_0xb5698d,_0x4ad801,_0x10ab8,_0x1b0abd,_0x27af40){return _0x1c81ac(_0xadbee8,_0xa5afb0,_0xb5698d,_0x4ad801,_0x10ab8,_0x1b0abd,_0x27af40);},'VdarW':_0x1c579f(0x1c7),'vnGJQ':'pre-check-cluster-args-not-passed','MTBwW':'kqMcA','shjCC':_0x1c579f(0x1db),'NkJiR':function(_0xf59d7e,_0x9c7e82,_0x417467,_0x1ce9ad,_0x3e7b17,_0x71bc4d,_0x191738,_0x463a28){return _0xf59d7e(_0x9c7e82,_0x417467,_0x1ce9ad,_0x3e7b17,_0x71bc4d,_0x191738,_0x463a28);},'TIWkU':'cloud-provider-not-supported','QRlUM':function(_0x4d622f,_0x3095a0){return _0x4d622f!==_0x3095a0;},'XACbs':_0x1c579f(0x1e8),'VnKVz':_0x1c579f(0x16c),'zRwty':_0x1c579f(0x1b7),'FsMvN':'GET','wfcBR':function(_0x179482,_0x1246c8,_0x4d182f){return _0x179482(_0x1246c8,_0x4d182f);},'ZceZk':function(_0x507db1,_0x3650c9,_0x41231f,_0x57372f,_0x1366cb,_0x4a46b1){return _0x507db1(_0x3650c9,_0x41231f,_0x57372f,_0x1366cb,_0x4a46b1);},'xgxrF':_0x1c579f(0x147),'UXsnG':_0x1c579f(0x136),'XKnOm':function(_0x14c5b0,_0x591437){return _0x14c5b0===_0x591437;},'YAZDd':function(_0x248452,_0x10d2e5){return _0x248452===_0x10d2e5;},'Dkwfh':_0x1c579f(0x225),'CqiFv':'wgjOT','BYBVP':function(_0x4267f7,_0x1915bf){return _0x4267f7(_0x1915bf);},'AxNBO':function(_0x1b739f,_0x2a25f7){return _0x1b739f!==_0x2a25f7;},'pWkIx':_0x1c579f(0x193),'HhuOd':_0x1c579f(0x198),'HmhvR':function(_0x3a57da,_0x2d6205){return _0x3a57da!==_0x2d6205;},'wjgCV':_0x1c579f(0x16a),'NBRse':_0x1c579f(0x1bb),'FLLUR':_0x1c579f(0x13d),'nYCRp':_0x1c579f(0x18f),'ETHiU':_0x1c579f(0x1bd),'DiiAW':_0x1c579f(0x21d)};let _0x3b5803;try{if(_0x4b869c[_0x1c579f(0x1bc)](_0x4b869c[_0x1c579f(0x180)],_0x4b869c[_0x1c579f(0x180)]))_0x16ad37['error'](_0x4b869c[_0x1c579f(0x1e2)]),_0x2ce6f6[_0x1c579f(0x1ca)](0x1);else{if(_0x556abc[_0x1c579f(0x17c)]||_0x556abc[_0x1c579f(0x1a8)]||_0x556abc[_0x1c579f(0x21e)]){if(_0x4b869c[_0x1c579f(0x17e)](_0x4b869c[_0x1c579f(0x1ef)],_0x4b869c[_0x1c579f(0x1ff)])){const _0x30d0c3={};_0x30d0c3['description']=_0x4b869c[_0x1c579f(0x1e7)],_0x30d0c3['type']=_0x4b869c[_0x1c579f(0x16b)];const _0x2158fd={};_0x2158fd[_0x1c579f(0x148)]=_0x4b869c['eLxbD'],_0x2158fd['type']=_0x4b869c[_0x1c579f(0x16b)];const _0x4a99f6={};_0x4a99f6['description']=_0x4b869c[_0x1c579f(0x1fe)],_0x4a99f6[_0x1c579f(0x178)]=_0x4b869c[_0x1c579f(0x16b)];const _0x2ba73c={};_0x2ba73c[_0x1c579f(0x148)]=_0x4b869c[_0x1c579f(0x1c5)],_0x2ba73c['type']=_0x4b869c[_0x1c579f(0x16b)];const _0x32167e={};return _0x32167e[_0x1c579f(0x1a3)]=_0x30d0c3,_0x32167e[_0x1c579f(0x1e4)]=_0x2158fd,_0x32167e[_0x1c579f(0x21e)]=_0x4a99f6,_0x32167e[_0x1c579f(0x136)]=_0x2ba73c,_0x3af6e1['usage'](_0x18b998[_0x1c579f(0x14b)])['epilogue'](_0x5d97f4)[_0x1c579f(0x221)](_0x32167e)[_0x1c579f(0x15a)](_0x4b869c[_0x1c579f(0x179)])[_0x1c579f(0x188)];}else{const _0x3601ff=[];!_0x556abc[_0x1c579f(0x17c)]&&(_0x4b869c['bOTVT'](_0x4b869c[_0x1c579f(0x160)],_0x4b869c[_0x1c579f(0x160)])?_0x5d72c5[_0x1c579f(0x15e)](_0x4b869c[_0x1c579f(0x218)]):_0x3601ff['push'](_0x4b869c[_0x1c579f(0x14c)]));;!_0x556abc[_0x1c579f(0x1a8)]&&(_0x4b869c['YkoPQ'](_0x4b869c[_0x1c579f(0x1eb)],_0x4b869c['AnASV'])?_0x3601ff[_0x1c579f(0x15e)](_0x4b869c[_0x1c579f(0x218)]):_0x5b49ec[_0x1c579f(0x15e)](_0x4b869c['ybWSH']));;!_0x556abc[_0x1c579f(0x21e)]&&(_0x4b869c[_0x1c579f(0x1a7)](_0x4b869c[_0x1c579f(0x1c3)],_0x4b869c[_0x1c579f(0x21c)])?_0x523224['info'](_0x1c579f(0x161)+_0x16ea46['clusterName']+'`\x20already\x20exists'):_0x3601ff[_0x1c579f(0x15e)](_0x4b869c['jtpdo']));;_0x4b869c[_0x1c579f(0x1fc)](_0x3601ff['length'],0x0)&&(_0x4b869c[_0x1c579f(0x138)](_0x4b869c[_0x1c579f(0x14d)],_0x4b869c[_0x1c579f(0x165)])?_0x42ff2c+=_0x1c579f(0x1dd)+_0x2affad[_0x1c579f(0x17c)]+'\x20'+(_0x2fafe1?_0x4b869c['NxywT']:_0x4b869c['tpxTZ'])+'\x0a\x0a':(_0x3b5803=_0x1c579f(0x17f)+_0x3601ff[_0x1c579f(0x15f)](',\x20')+'.\x20Please\x20provide\x20all\x20required\x20arguments.',await _0x4b869c[_0x1c579f(0x1b5)](reportToGalactusAndSendToEDS,_0x556abc,_0x1147af,_0x3b5803,messageTypes[_0x1c579f(0x1fd)],_0x4b869c['VdarW'],_0x4b869c[_0x1c579f(0x1de)],_0x4b869c[_0x1c579f(0x185)]),logger[_0x1c579f(0x1b0)](_0x3b5803),process[_0x1c579f(0x1ca)](0x1))),!ALL_SUPPORTED_CLOUD_PROVIDERS[_0x1c579f(0x177)](_0x556abc[_0x1c579f(0x1a8)][_0x1c579f(0x1cf)]())&&(_0x4b869c[_0x1c579f(0x138)](_0x4b869c[_0x1c579f(0x13c)],_0x4b869c[_0x1c579f(0x13c)])?(_0x3b5803=_0x4b869c[_0x1c579f(0x214)],await _0x4b869c[_0x1c579f(0x134)](reportToGalactusAndSendToEDS,_0x556abc,_0x1147af,_0x3b5803,messageTypes[_0x1c579f(0x1fd)],_0x4b869c[_0x1c579f(0x202)],_0x4b869c['TIWkU'],_0x4b869c['FBeKE']),logger['error'](_0x3b5803),!_0x556abc[_0x1c579f(0x1a8)]&&(_0x4b869c['QRlUM'](_0x4b869c['XACbs'],_0x4b869c['VnKVz'])?(logger[_0x1c579f(0x1af)](_0x1c579f(0x1f9)+DEFAULT_CLUSTER_DETAILS[_0x1c579f(0x133)]+'\x20'),_0x556abc[_0x1c579f(0x1a8)]=DEFAULT_CLUSTER_DETAILS[_0x1c579f(0x133)]):_0x3f7d43+=_0x1c579f(0x1dd)+_0x3b9183[_0x1c579f(0x17c)]+_0x1c579f(0x21a))):(_0x276276[_0x1c579f(0x1af)]('['+_0x459ae5+_0x1c579f(0x15c)+_0x1ab5db[_0x1c579f(0x142)]+_0x1c579f(0x1c1)+_0x1b6bf8['data']+_0x1c579f(0x186)+_0x3edae9['error']),_0x335ffd['error']&&_0x39f841[_0x1c579f(0x1b0)](_0x1c579f(0x1c2)+_0x40ea86[_0x1c579f(0x1b0)][_0x1c579f(0x1bf)]))),global_registry[_0x1c579f(0x17c)]=_0x556abc[_0x1c579f(0x17c)],global_registry[_0x1c579f(0x1a8)]=_0x556abc[_0x1c579f(0x1a8)],global_registry['clusterRegion']=_0x556abc[_0x1c579f(0x21e)];}}else{if(_0x556abc['gridProfile']){if(_0x4b869c[_0x1c579f(0x17e)](_0x4b869c[_0x1c579f(0x1b9)],_0x4b869c[_0x1c579f(0x1b9)])){global_registry[_0x1c579f(0x184)]=_0x556abc[_0x1c579f(0x184)],logger['debug']('grid\x20profile\x20flow\x20'+_0x556abc[_0x1c579f(0x184)]);const _0x410b41='https://'+AG_API_URL+_0x1c579f(0x189),_0x66aa5a={};_0x66aa5a[_0x1c579f(0x141)]=_0x4b869c[_0x1c579f(0x172)],_0x66aa5a['headers']=global_registry['authHeader'],_0x66aa5a['throwHttpErrors']=![];const _0x5c45e6=_0x66aa5a,_0x32402a=await _0x4b869c['wfcBR'](got,_0x410b41,_0x5c45e6),_0x32e1c7=await _0x4b869c['ZceZk'](responseValidation,_0x32402a,_0x4b869c[_0x1c579f(0x1a2)],_0x4b869c[_0x1c579f(0x174)],_0x556abc,_0x1147af);let _0x1045a6={};if(_0x4b869c[_0x1c579f(0x1c8)](_0x32e1c7,0xc8)){if(_0x4b869c[_0x1c579f(0x18e)](_0x4b869c['Dkwfh'],_0x4b869c[_0x1c579f(0x1f4)])){const _0x301695={};_0x301695['type']=_0x5374ca[_0x1c579f(0x1d1)],_0x301695['message']=_0x499f44,_0x13cdc4[_0x1c579f(0x13a)](_0x31b38d,_0x301695,_0x4b869c[_0x1c579f(0x185)],!![]);}else{const _0x4b6aed=JSON['parse'](_0x32402a[_0x1c579f(0x144)]),_0x1f7b7a=_0x4b6aed[_0x1c579f(0x20c)](_0x72de97=>_0x72de97[_0x1c579f(0x212)]===_0x556abc[_0x1c579f(0x184)])||null;if(_0x4b869c['BYBVP'](isUndefined,_0x1f7b7a))_0x4b869c[_0x1c579f(0x1c4)](_0x4b869c[_0x1c579f(0x1f3)],_0x4b869c[_0x1c579f(0x1f3)])?_0x52d4f1=_0xfeea88:(_0x3b5803=_0x1c579f(0x194)+_0x556abc[_0x1c579f(0x184)]+'.\x20please\x20verify\x20the\x20grid\x20profile\x20name\x20and\x20try\x20again',await _0x4b869c[_0x1c579f(0x1b5)](reportToGalactusAndSendToEDS,_0x556abc,_0x1147af,_0x3b5803,messageTypes[_0x1c579f(0x1fd)],_0x4b869c[_0x1c579f(0x202)],_0x4b869c[_0x1c579f(0x1d8)],_0x4b869c[_0x1c579f(0x185)]),logger['error'](_0x3b5803),process[_0x1c579f(0x1ca)](0x1));else{if(_0x4b869c[_0x1c579f(0x149)](_0x4b869c[_0x1c579f(0x19a)],_0x4b869c[_0x1c579f(0x21b)]))_0x1045a6=_0x1f7b7a;else{const {header:_0x1368c1,response:_0x4e673c}=_0xa73339,{status:_0x481397,data:_0x3b0fa6,error:_0x19b6a4}=_0x4e673c;_0x57e3cb+=_0x1368c1+'\x20#'+_0x4b869c[_0x1c579f(0x1d6)](_0x5d759b,0x1)+'\x0a',_0x47d611+='Status:\x20'+(_0x481397?_0x4b869c[_0x1c579f(0x1a4)]:_0x4b869c[_0x1c579f(0x14f)])+'\x0a',_0x28b165+=_0x1c579f(0x197)+_0x4b869c['hPXcu'](_0x3b0fa6,_0x4b869c[_0x1c579f(0x191)])+'\x0a',_0x19b6a4&&(_0x1ef089+=_0x4b869c[_0x1c579f(0x1e0)],_0xe12189+=_0x1c579f(0x220)+(_0x19b6a4[_0x1c579f(0x135)]||_0x4b869c[_0x1c579f(0x191)])+'\x0a',_0x4da97c+='\x20\x20Code:\x20'+(_0x19b6a4[_0x1c579f(0x168)]||_0x4b869c['fFJiR'])+'\x0a',_0x495d8d+=_0x1c579f(0x171)+(_0x19b6a4['stack']||_0x4b869c[_0x1c579f(0x191)])+'\x0a'),_0x525440+='\x0a\x0a';}}}}else _0x4b869c[_0x1c579f(0x17e)](_0x4b869c[_0x1c579f(0x217)],_0x4b869c['FLLUR'])?process[_0x1c579f(0x1ca)](0x1):_0x3d6cb7[_0x1c579f(0x1b0)](_0x1c579f(0x1c2)+_0x5ede14['error'][_0x1c579f(0x1bf)]);const _0x5aaf26={};_0x5aaf26[_0x1c579f(0x178)]=WS_EVENTS[_0x1c579f(0x1d1)],_0x5aaf26[_0x1c579f(0x135)]=_0x4b869c['nYCRp'],webSocketUtils[_0x1c579f(0x13a)](_0x1147af,_0x5aaf26),global_registry[_0x1c579f(0x1a8)]=_0x1045a6['cloudProvider'],global_registry[_0x1c579f(0x1d7)]=_0x1045a6['region'],global_registry[_0x1c579f(0x17c)]=_0x1045a6[_0x1c579f(0x17c)];}else _0x1b607a[_0x1c579f(0x1ca)](0x1);}else _0x4b869c[_0x1c579f(0x149)](_0x4b869c[_0x1c579f(0x181)],_0x4b869c[_0x1c579f(0x181)])?_0x5a79c9[_0x1c579f(0x15e)](_0x4b869c[_0x1c579f(0x20f)]):(logger[_0x1c579f(0x1b0)](_0x4b869c[_0x1c579f(0x1e2)]),process[_0x1c579f(0x1ca)](0x1));}}}catch(_0x384585){_0x4b869c[_0x1c579f(0x18e)](_0x4b869c['DiiAW'],_0x4b869c['DiiAW'])?(_0x3b5803=_0x1c579f(0x175)+_0x384585+':\x20'+_0x384585[_0x1c579f(0x1bf)],logger['error'](_0x3b5803),await _0x4b869c['gNhuU'](reportToGalactusAndSendToEDS,_0x556abc,_0x1147af,_0x3b5803,messageTypes[_0x1c579f(0x1fd)],_0x4b869c[_0x1c579f(0x202)],_0x4b869c[_0x1c579f(0x1fb)],_0x4b869c[_0x1c579f(0x185)]),process['exit'](0x1)):(_0x58c5c8+=_0x4b869c[_0x1c579f(0x1e0)],_0x5cb68c+='\x20\x20Message:\x20'+(_0x5034f5[_0x1c579f(0x135)]||_0x4b869c['fFJiR'])+'\x0a',_0x4c1369+=_0x1c579f(0x18a)+(_0x50d008[_0x1c579f(0x168)]||_0x4b869c['fFJiR'])+'\x0a',_0x302019+=_0x1c579f(0x171)+(_0xf57211[_0x1c579f(0x1bf)]||_0x4b869c['fFJiR'])+'\x0a');}}function printResponse(_0x43e20b,_0x1a9f73){const _0x4f621a=a17_0xc3a04a,_0x4f5115={};_0x4f5115[_0x4f621a(0x20d)]=function(_0x46d109,_0x429fb5){return _0x46d109===_0x429fb5;},_0x4f5115[_0x4f621a(0x1df)]=_0x4f621a(0x166),_0x4f5115[_0x4f621a(0x222)]=_0x4f621a(0x16e);const _0x1bc1cf=_0x4f5115;logger[_0x4f621a(0x1af)]('['+_0x43e20b+']\x20status\x20:\x20'+_0x1a9f73[_0x4f621a(0x142)]+'\x20data\x20:\x20'+_0x1a9f73[_0x4f621a(0x14a)]+_0x4f621a(0x186)+_0x1a9f73[_0x4f621a(0x1b0)]),_0x1a9f73[_0x4f621a(0x1b0)]&&(_0x1bc1cf[_0x4f621a(0x20d)](_0x1bc1cf['gpoYQ'],_0x1bc1cf['AWHFf'])?(_0x25ff35[_0x4f621a(0x1af)]('Setting\x20cloud\x20provider\x20as\x20'+_0x3fd951[_0x4f621a(0x133)]+'\x20'),_0x4ceb54[_0x4f621a(0x1a8)]=_0x49f6eb[_0x4f621a(0x133)]):logger['error'](_0x4f621a(0x1c2)+_0x1a9f73[_0x4f621a(0x1b0)][_0x4f621a(0x1bf)]));}async function generateReport(_0x4faff6,_0x43bb83){const _0x42faca=a17_0xc3a04a,_0x4f4dde={'VqPDM':function(_0x35b4bf,_0x427aa5){return _0x35b4bf+_0x427aa5;},'mGboC':'Success','NerYc':_0x42faca(0x139),'pbpqV':function(_0x7853ac,_0x216448){return _0x7853ac||_0x216448;},'IWYVZ':_0x42faca(0x1b3),'ZhvLg':_0x42faca(0x15d),'TAWuK':_0x42faca(0x1b8),'GrYJo':function(_0x4bf882,_0x546ffa){return _0x4bf882!=_0x546ffa;},'glmzg':'is\x20already\x20present','oqsew':'will\x20be\x20created','gXgNi':function(_0x42dd16){return _0x42dd16();}};let _0x5aedc3=_0x42faca(0x1ad)+global_registry[_0x42faca(0x1a8)]+_0x42faca(0x1e6);return _0x4faff6['forEach']((_0x2161df,_0x493992)=>{const _0x57f69c=_0x42faca,{header:_0x3634b3,response:_0x405064}=_0x2161df,{status:_0x1b5b54,data:_0xad2f4e,error:_0x42a17f}=_0x405064;_0x5aedc3+=_0x3634b3+'\x20#'+_0x4f4dde[_0x57f69c(0x1e5)](_0x493992,0x1)+'\x0a',_0x5aedc3+=_0x57f69c(0x14e)+(_0x1b5b54?_0x4f4dde[_0x57f69c(0x1a6)]:_0x4f4dde[_0x57f69c(0x196)])+'\x0a',_0x5aedc3+=_0x57f69c(0x197)+_0x4f4dde[_0x57f69c(0x1e9)](_0xad2f4e,_0x4f4dde[_0x57f69c(0x1be)])+'\x0a',_0x42a17f&&(_0x5aedc3+=_0x4f4dde[_0x57f69c(0x201)],_0x5aedc3+=_0x57f69c(0x220)+(_0x42a17f[_0x57f69c(0x135)]||_0x4f4dde[_0x57f69c(0x1be)])+'\x0a',_0x5aedc3+=_0x57f69c(0x18a)+(_0x42a17f[_0x57f69c(0x168)]||_0x4f4dde[_0x57f69c(0x1be)])+'\x0a',_0x5aedc3+='\x20\x20Stack:\x20'+(_0x42a17f[_0x57f69c(0x1bf)]||_0x4f4dde['IWYVZ'])+'\x0a'),_0x5aedc3+='\x0a\x0a';}),_0x5aedc3+=_0x4f4dde['TAWuK'],_0x4f4dde[_0x42faca(0x219)](_0x43bb83,null)?_0x5aedc3+='Cluster\x20'+global_registry[_0x42faca(0x17c)]+'\x20'+(_0x43bb83?_0x4f4dde[_0x42faca(0x1b6)]:_0x4f4dde[_0x42faca(0x159)])+'\x0a\x0a':_0x5aedc3+=_0x42faca(0x1dd)+global_registry[_0x42faca(0x17c)]+_0x42faca(0x21a),_0x5aedc3+=_0x4f4dde[_0x42faca(0x1ce)](getSystemMetaData),_0x5aedc3;}function a17_0x5729(){const _0x732187=['Missing\x20required\x20arguments.\x20Please\x20provide\x20either\x20grid\x20profile\x20or\x20cluster\x20details\x20(cluser-name\x20,\x20cloud\x20provider\x20&\x20region','ZhvLg','VdarW','builder','Pass\x20the\x20name\x20of\x20cloud\x20provider\x20for\x20existing\x20Kubernetes\x20Cluster.','<UsernamePlaceholder>','replace','kIeAY','boVFn','Whitelisted\x20browserstack','Browserstack','toolInstalledResp','find','BjEzy','0|1|3|2|4','jtpdo','existsSync','credential-not-found','name','authHeader','shjCC','2815WBwJFz','dummy-grid','FLLUR','GlrSi','GrYJo','\x20details\x20cannot\x20be\x20fetched\x0a\x0a','NBRse','bocpi','glSMv','region','EiCcL','\x20\x20Message:\x20','options','AWHFf','736141qbmJdN','mKpVV','mtDLA','pre-check-failed','WebSocket','WPagk','cluster-check-failed-','ZFnvc','delay','connectionTimeout','CLOUD_PROVIDER','NkJiR','message','grid-profile','gRKQv','saApV','Failure','sendEventToBackend','Pass\x20the\x20region\x20for\x20existing\x20Kubernetes\x20Cluster.','MTBwW','JGkJM','bstackAccesskey','\x20region\x20-\x20','rhDBM','method','status','UgeKk','body','5068725tCSKYM','eeeRQ','pre-check','description','HmhvR','data','pre_check','ybWSH','XvesV','Status:\x20','StLnY','ObkAw','MWbjy','stringify','getUTCHours','fTWWw','epilogue','Pre-check\x20running\x20for\x20Cloud\x20-\x20','`\x20,error\x20:\x20','104tKhDtP','oqsew','help','JkoPE',']\x20status\x20:\x20','Error\x20Details:\x0a','push','join','wfNBK','Cluster\x20`','split','KSAtL','isClusterPresent','sRxlU','txZAI','Failed\x20in\x20pre-check!\x20Error:\x20','code','Create\x20a\x20grid\x20in\x20existing\x20Kubernetes\x20Cluster\x20on\x20AWS/Azure/GCP.','BkKsB','gmFTS','jDRNN','response','LAeMD','Vlrvu','18498uTGCMJ','\x20\x20Stack:\x20','FsMvN','header','UXsnG','Error\x20in\x20input\x20validation\x20while\x20pre-check\x20-\x20','../../utils/webSocketUtils','includes','type','KbZXV','getUTCDate','17846cIxMyt','clusterName','XYQfE','CFKSP','Missing\x20required\x20arguments:\x20','EiVXl','ETHiU','Use\x20an\x20existing\x20grid\x20profile\x20to\x20setup\x20the\x20Automation\x20Grid.\x20By\x20default,\x20configured\x20profile\x20is\x20used.','214IWQqXC','gridProfile','FBeKE','\x20error\x20:\x20','abAAw','argv','/packages/cli/get-all-grid-profiles','\x20\x20Code:\x20','6633052kSSwQt','MVmtm','ZfkLD','YAZDd','Grid\x20profile\x20fetched\x20for\x20pre-check','ZGcRr','fFJiR','11ljGWYZ','UXiEn','Invalid\x20input.\x20grid\x20profiles:\x20','getUTCFullYear','NerYc','Message:\x20','pre-check-grid-profile-empty','debug','wjgCV','utf-8','isTls1_2_SUPPORTED','tQUjS','cPsri','../../utils/utilityMethods','<PasswordPlaceholder>','JEJQn','xgxrF','cluster-name','MujbY','is\x20already\x20present','mGboC','YkoPQ','cloudProvider','parse','username','isTrialGridAccessible','6415670KZNAWn','===\x20Precheck\x20Report\x20-\x20','atOfc','info','error','accessResp','reconnecting-websocket','N/A','WmFYk','gNhuU','glmzg','lvEcA','Cluster\x20details\x0a-----------------------\x0a','zRwty','4733406WTAfcM','VCmOz','kcAwX','sqOrv','IWYVZ','stack','string','\x20data\x20:\x20','error\x20stack\x20:\x20','DsrIz','AxNBO','xfCmn','AKjEl','pre-check-grid-called','XKnOm','Report\x20saved\x20in\x20','exit','handler','pyLoZ','bstackUsername','gXgNi','toLowerCase','Tool\x20Installed','LOG','command','unable\x20to\x20verify\x20if\x20cluster\x20`','User\x20Access','TLSv1_2_client_method','bOkwo','clusterRegion','HhuOd','../../config/logger','XPfHt','Invalid\x20input.\x20Currently\x20the\x20automation\x20grid\x20in\x20AWS,\x20AZURE\x20&\x20GCP\x20cloud\x20provider\x20is\x20supported\x20using\x20CLI.','jnoVG','Cluster\x20','vnGJQ','gpoYQ','LBLAU','bGwnq','VuHVV','../../cloudproviders/utils','cloud-provider','VqPDM','\x20===\x0a\x0a','XDeJJ','SCgCg','pbpqV','password','AnASV','isCliToolInstalled','drgmm','desc','SNqli','readFileSync','TWDcV','Credentials\x20not\x20found!\x20Ensure\x20init\x20command\x20is\x20run\x20before\x20running\x20this\x20command.','pWkIx','CqiFv','ULzFz','HlCXZ','EaZhw','KcZaf','Setting\x20cloud\x20provider\x20as\x20','QvkfX','TIWkU','GreQq','ERROR','YeMDG','aXQqy'];a17_0x5729=function(){return _0x732187;};return a17_0x5729();};exports[a17_0xc3a04a(0x1cb)]=async function(_0x29775b){const _0x1b8aaf=a17_0xc3a04a,_0x41570c={'Vlrvu':function(_0x56b39e){return _0x56b39e();},'wZzov':_0x1b8aaf(0x1f2),'HlCXZ':function(_0x5e1e9e,_0x342a2d,_0x5ee178,_0x35c277,_0x54177b,_0x2d1e8d,_0x4ac652,_0x1e2a2f){return _0x5e1e9e(_0x342a2d,_0x5ee178,_0x35c277,_0x54177b,_0x2d1e8d,_0x4ac652,_0x1e2a2f);},'fTWWw':_0x1b8aaf(0x1c7),'EaZhw':_0x1b8aaf(0x211),'atOfc':'error','AKjEl':function(_0x332f8c,_0x46c195,_0x41ef69,_0x208260,_0x393a31,_0x35680c,_0x44e8e4){return _0x332f8c(_0x46c195,_0x41ef69,_0x208260,_0x393a31,_0x35680c,_0x44e8e4);},'abAAw':function(_0x2895d4){return _0x2895d4();},'MWbjy':_0x1b8aaf(0x205),'TWDcV':_0x1b8aaf(0x1a0),'mKpVV':function(_0x11530a,_0x479940,_0x46e81c){return _0x11530a(_0x479940,_0x46e81c);},'WIrcB':function(_0x2639e6,_0x25b716,_0x30f1cc,_0x4d5140,_0x5fc3f2,_0x4a9552,_0x521bd0){return _0x2639e6(_0x25b716,_0x30f1cc,_0x4d5140,_0x5fc3f2,_0x4a9552,_0x521bd0);},'ObkAw':_0x1b8aaf(0x216),'bGwnq':function(_0x230693,_0x28745c,_0x53b6ef){return _0x230693(_0x28745c,_0x53b6ef);},'ZfkLD':_0x1b8aaf(0x20b),'kIeAY':_0x1b8aaf(0x20e),'EiCcL':function(_0x4bb4fc,_0x405200,_0x389748,_0x5d20c7,_0x17b45a,_0x3f4c28,_0x428beb,_0x446df2){return _0x4bb4fc(_0x405200,_0x389748,_0x5d20c7,_0x17b45a,_0x3f4c28,_0x428beb,_0x446df2);},'eeeRQ':_0x1b8aaf(0x1b1),'YhLfe':function(_0x135ddb,_0x33597f,_0x32c8cf){return _0x135ddb(_0x33597f,_0x32c8cf);},'drgmm':_0x1b8aaf(0x1ab),'gRKQv':function(_0x4c9be4,_0x32c406){return _0x4c9be4(_0x32c406);},'XYQfE':_0x1b8aaf(0x1d5),'pyLoZ':_0x1b8aaf(0x19c),'KSAtL':_0x1b8aaf(0x1d0),'ZGcRr':_0x1b8aaf(0x1d4),'AZXjU':_0x1b8aaf(0x209),'ULzFz':'SSL\x20Configured','QowAt':function(_0x37a8f0,_0x15f5a3){return _0x37a8f0+_0x15f5a3;},'JEJQn':_0x1b8aaf(0x19b),'boVFn':_0x1b8aaf(0x226)};let _0x4ec4c1,_0x46d46a;try{global_registry['requestId']=_0x41570c[_0x1b8aaf(0x16f)](uuidv4);!fs[_0x1b8aaf(0x210)](_0x41570c['Vlrvu'](getCredentialsPath))&&(_0x46d46a=_0x41570c['wZzov'],logger[_0x1b8aaf(0x1b0)](_0x46d46a),await _0x41570c[_0x1b8aaf(0x1f6)](reportToGalactusAndSendToEDS,_0x29775b,_0x4ec4c1,_0x46d46a,messageTypes[_0x1b8aaf(0x1fd)],_0x41570c[_0x1b8aaf(0x154)],_0x41570c[_0x1b8aaf(0x1f7)],_0x41570c[_0x1b8aaf(0x1ae)]),process[_0x1b8aaf(0x1ca)](0x1));_0x41570c['AKjEl'](sendInstrumentationEvent,_0x29775b,_0x41570c['fTWWw'],messageTypes['INFO'],null,null,_0x29775b);const _0x59cc67=JSON[_0x1b8aaf(0x1a9)](fs[_0x1b8aaf(0x1f0)](_0x41570c[_0x1b8aaf(0x187)](getCredentialsPath)));global_registry[_0x1b8aaf(0x1cd)]=_0x59cc67[_0x1b8aaf(0x20a)][_0x1b8aaf(0x1aa)],global_registry[_0x1b8aaf(0x13e)]=_0x59cc67[_0x1b8aaf(0x20a)][_0x1b8aaf(0x1ea)];const _0x174eb1=WS_ENDPOINT[_0x1b8aaf(0x206)](_0x41570c[_0x1b8aaf(0x151)],_0x59cc67[_0x1b8aaf(0x20a)]['username'])[_0x1b8aaf(0x206)](_0x41570c[_0x1b8aaf(0x1f1)],_0x59cc67[_0x1b8aaf(0x20a)]['password']),_0x1a6d51={};_0x1a6d51[_0x1b8aaf(0x227)]=ws,_0x1a6d51[_0x1b8aaf(0x132)]=0x36ee80,_0x4ec4c1=new ReconnectingWebSocket(_0x174eb1,[],_0x1a6d51),global_registry[_0x1b8aaf(0x213)]=_0x41570c[_0x1b8aaf(0x224)](getAuthHeader,global_registry[_0x1b8aaf(0x1cd)],global_registry['bstackAccesskey']),await _0x41570c['mKpVV'](inputValidation,_0x29775b,_0x4ec4c1),logger[_0x1b8aaf(0x1af)](_0x1b8aaf(0x156)+global_registry[_0x1b8aaf(0x1a8)]+_0x1b8aaf(0x13f)+global_registry[_0x1b8aaf(0x1d7)]);let _0x5b7479=await _0x41570c['WIrcB'](getCloudProviderObjectWithOutInit,global_registry[_0x1b8aaf(0x1a8)],global_registry['clusterName'],_0x41570c[_0x1b8aaf(0x150)],_0x4ec4c1,webSocketUtils,_0x29775b);const _0x339eba=await _0x5b7479[_0x1b8aaf(0x1ec)]();_0x41570c[_0x1b8aaf(0x1e1)](printResponse,_0x41570c[_0x1b8aaf(0x18d)],_0x339eba),_0x5b7479=await _0x5b7479['init']();let _0x2aeff5=![];try{_0x2aeff5=await _0x5b7479[_0x1b8aaf(0x164)]();}catch(_0x2a7cd9){const _0x3e17dc=_0x41570c[_0x1b8aaf(0x207)][_0x1b8aaf(0x162)]('|');let _0x18d2f6=0x0;while(!![]){switch(_0x3e17dc[_0x18d2f6++]){case'0':_0x46d46a=_0x1b8aaf(0x1d3)+global_registry[_0x1b8aaf(0x17c)]+'`\x20is\x20present\x20in\x20region\x20`'+global_registry[_0x1b8aaf(0x1d7)]+_0x1b8aaf(0x157)+_0x2a7cd9;continue;case'1':_0x2aeff5=null;continue;case'2':_0x46d46a+='\x0a'+JSON[_0x1b8aaf(0x152)](_0x2a7cd9[_0x1b8aaf(0x1bf)]);continue;case'3':logger[_0x1b8aaf(0x1b0)](_0x46d46a);continue;case'4':await _0x41570c[_0x1b8aaf(0x21f)](reportToGalactusAndSendToEDS,_0x29775b,_0x4ec4c1,_0x46d46a,messageTypes[_0x1b8aaf(0x1fd)],_0x41570c['fTWWw'],_0x1b8aaf(0x12f)+global_registry['cloudProvider'],_0x41570c[_0x1b8aaf(0x1ae)]);continue;}break;}}_0x2aeff5&&logger[_0x1b8aaf(0x1af)](_0x1b8aaf(0x161)+global_registry[_0x1b8aaf(0x17c)]+'`\x20already\x20exists');const _0x5159a2=await _0x5b7479['checkAccess']();_0x41570c[_0x1b8aaf(0x224)](printResponse,_0x41570c[_0x1b8aaf(0x146)],_0x5159a2);const _0x59498b=await _0x41570c['abAAw'](curlRequest);_0x41570c['YhLfe'](printResponse,_0x41570c[_0x1b8aaf(0x1ed)],_0x59498b);const _0x119732=await _0x41570c[_0x1b8aaf(0x137)](isTlsSupported,_0x41570c[_0x1b8aaf(0x17d)]);_0x41570c[_0x1b8aaf(0x1e1)](printResponse,_0x41570c[_0x1b8aaf(0x1cc)],_0x119732);const _0x459ee6={};_0x459ee6['header']=_0x41570c[_0x1b8aaf(0x163)],_0x459ee6[_0x1b8aaf(0x16d)]=_0x339eba;const _0xdec933={};_0xdec933['header']=_0x41570c[_0x1b8aaf(0x190)],_0xdec933[_0x1b8aaf(0x16d)]=_0x5159a2;const _0x58c9b8={};_0x58c9b8[_0x1b8aaf(0x173)]=_0x41570c['AZXjU'],_0x58c9b8[_0x1b8aaf(0x16d)]=_0x59498b;const _0xdb415b={};_0xdb415b['header']=_0x41570c[_0x1b8aaf(0x1f5)],_0xdb415b[_0x1b8aaf(0x16d)]=_0x119732;const _0x2f0778=[_0x459ee6,_0xdec933,_0x58c9b8,_0xdb415b],_0x14be4d=await _0x41570c[_0x1b8aaf(0x1e1)](generateReport,_0x2f0778,_0x2aeff5),_0x113db6=new Date(),_0x4df0a9=_0x113db6[_0x1b8aaf(0x195)]()+'_'+_0x41570c['QowAt'](_0x113db6['getUTCMonth'](),0x1)+'_'+_0x113db6[_0x1b8aaf(0x17a)]()+'_'+_0x113db6[_0x1b8aaf(0x153)]()+'_'+_0x113db6['getUTCMinutes'](),_0x12dbe7='log/report_'+_0x4df0a9+'.txt';fs['writeFileSync'](_0x12dbe7,_0x14be4d,_0x41570c[_0x1b8aaf(0x1a1)]),logger['info'](_0x1b8aaf(0x1c9)+_0x12dbe7),process['exit'](0x0);}catch(_0x3e5aff){let _0x1624f2=_0x1b8aaf(0x167)+_0x3e5aff+'\x20';logger[_0x1b8aaf(0x1b0)](_0x1624f2),_0x1624f2+='\x0a'+JSON[_0x1b8aaf(0x152)](_0x3e5aff[_0x1b8aaf(0x1bf)]),logger[_0x1b8aaf(0x199)]('stack\x20trace\x20'+_0x3e5aff[_0x1b8aaf(0x1bf)]);if(_0x4ec4c1){const _0x4d537c={};_0x4d537c[_0x1b8aaf(0x178)]=WS_EVENTS[_0x1b8aaf(0x1d1)],_0x4d537c[_0x1b8aaf(0x135)]=_0x1624f2,webSocketUtils[_0x1b8aaf(0x13a)](_0x4ec4c1,_0x4d537c,_0x41570c['atOfc'],!![]);}await webSocketUtils[_0x1b8aaf(0x131)](0x7d0);const _0x1d5fcd={};_0x1d5fcd[_0x1b8aaf(0x1b0)]=_0x1624f2,await _0x41570c[_0x1b8aaf(0x1c6)](sendInstrumentationEvent,_0x29775b,_0x41570c[_0x1b8aaf(0x154)],messageTypes['ERROR'],_0x41570c[_0x1b8aaf(0x208)],_0x1d5fcd,_0x29775b),process['exit'](0x1);}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a18_0x4180(){const _0x9ef35c=['709194qdDGcB','../config/constants','yfldJ','start_commands','epilogue','command','tdvdT','builder','commandDir','32596ZwEzCi','start','help','desc','handler','341095HJLBuE','346260EqznNK','195160hkGCJb','2023EJarhY','5568723DWoqvs','3032YyYghE','57XecsaS','Start\x20an\x20existing\x20Automation\x20grid.'];a18_0x4180=function(){return _0x9ef35c;};return a18_0x4180();}const a18_0x163930=a18_0x5a78;(function(_0x540bd0,_0x43e2c0){const _0x383b5c=a18_0x5a78,_0x16a1b9=_0x540bd0();while(!![]){try{const _0x1e9394=-parseInt(_0x383b5c(0x12d))/0x1+-parseInt(_0x383b5c(0x142))/0x2+-parseInt(_0x383b5c(0x131))/0x3*(-parseInt(_0x383b5c(0x13c))/0x4)+-parseInt(_0x383b5c(0x141))/0x5+-parseInt(_0x383b5c(0x133))/0x6+-parseInt(_0x383b5c(0x12e))/0x7*(parseInt(_0x383b5c(0x130))/0x8)+parseInt(_0x383b5c(0x12f))/0x9;if(_0x1e9394===_0x43e2c0)break;else _0x16a1b9['push'](_0x16a1b9['shift']());}catch(_0x24b2d3){_0x16a1b9['push'](_0x16a1b9['shift']());}}}(a18_0x4180,0x1ab1b));function a18_0x5a78(_0x211612,_0x1b3b06){const _0x4180ba=a18_0x4180();return a18_0x5a78=function(_0x5a782d,_0x230bcb){_0x5a782d=_0x5a782d-0x12d;let _0x4bd0e3=_0x4180ba[_0x5a782d];return _0x4bd0e3;},a18_0x5a78(_0x211612,_0x1b3b06);}const {HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE}=require(a18_0x163930(0x134));exports[a18_0x163930(0x138)]=a18_0x163930(0x13d),exports[a18_0x163930(0x13f)]=a18_0x163930(0x132),exports[a18_0x163930(0x13a)]=function(_0x597f0b){const _0x17c31e=a18_0x163930,_0x41111a={};_0x41111a['yfldJ']=_0x17c31e(0x136),_0x41111a[_0x17c31e(0x139)]='help';const _0x12ca4e=_0x41111a;return _0x597f0b['usage'](HELP_HEADER_MESSAGE['start'])[_0x17c31e(0x137)](HELP_FOOTER_MESSAGE)[_0x17c31e(0x13b)](_0x12ca4e[_0x17c31e(0x135)])['demandCommand']()['recommendCommands']()['strict']()[_0x17c31e(0x13e)](_0x12ca4e[_0x17c31e(0x139)]);},exports[a18_0x163930(0x140)]=function(_0x4efc05){};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a19_0x2d6e71=a19_0x2895;(function(_0x14efbc,_0x2a2cef){const _0x4d5ffa=a19_0x2895,_0x295757=_0x14efbc();while(!![]){try{const _0x58ad82=parseInt(_0x4d5ffa(0x18a))/0x1+parseInt(_0x4d5ffa(0x1ba))/0x2+parseInt(_0x4d5ffa(0x1c7))/0x3*(parseInt(_0x4d5ffa(0x1ad))/0x4)+-parseInt(_0x4d5ffa(0x1a0))/0x5*(parseInt(_0x4d5ffa(0x1d5))/0x6)+parseInt(_0x4d5ffa(0x1d3))/0x7*(-parseInt(_0x4d5ffa(0x19f))/0x8)+-parseInt(_0x4d5ffa(0x194))/0x9+parseInt(_0x4d5ffa(0x196))/0xa*(parseInt(_0x4d5ffa(0x1a4))/0xb);if(_0x58ad82===_0x2a2cef)break;else _0x295757['push'](_0x295757['shift']());}catch(_0x49e08a){_0x295757['push'](_0x295757['shift']());}}}(a19_0x3763,0x5d8fd));function a19_0x2895(_0x2b6f16,_0x280e5e){const _0x37634b=a19_0x3763();return a19_0x2895=function(_0x28952c,_0x109392){_0x28952c=_0x28952c-0x17f;let _0x1f0bdf=_0x37634b[_0x28952c];return _0x1f0bdf;},a19_0x2895(_0x2b6f16,_0x280e5e);}function a19_0x3763(){const _0x4ba80c=['user','type','grid','init-not-called','Credentials\x20not\x20found!\x20Ensure\x20init\x20command\x20is\x20run\x20before\x20running\x20this\x20command.','16HLPTHL','NvMZv','../../utils/utilityMethods','KjVAZ','KXuPo','ynuQE','string','skip-tls-cert-verify','Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Unauthorized\x20request!','CCsnI','MNUsY','message','qDjnc','1151206gVhovF','body','DrouV','desc','description','TLIoe','region','naULD','reconnecting-websocket','unauthorised','rrhun','skipTlsCertVerify','<PasswordPlaceholder>','188214UkZupe','ZainD','../../utils/gridComponents','HJIVA','bstackUsername','DjvXa','help','clusterRegion','connectionTimeout','DoGDe','Browserstack','info','14UOStuC','gridId','6bzqGew','hPNSV','WebSocket','invalid-grid-id','grid-id','debug','OCdNW','TARWn','INFO','existsSync','xzaLX','cloudProvider','cKduy','default','gQozI','builder','replace','Pass\x20the\x20ID\x20of\x20the\x20existing\x20Automation\x20grid\x20you\x20want\x20to\x20start.','ERROR','stack','usage','463045uZnJSo','<UsernamePlaceholder>','Adding\x20Websocket\x20listeners','exit','boolean','error','../../config/constants','statusCode','iehWi','Start\x20an\x20existing\x20Automation\x20grid.','4424139FHmlor','clusterName','10ZOaVpZ','PVObd','start','Grid\x20started','username','addListeners','password','argv','KjTLj','450488sqXhzZ','3420845bkexaR','server-error','parse','Please\x20provide\x20ID\x20of\x20the\x20grid\x20to\x20start','4201901ojYbwR','bstackAccesskey','command','readFileSync'];a19_0x3763=function(){return _0x4ba80c;};return a19_0x3763();}const fs=require('fs'),ws=require('ws'),ReconnectingWebSocket=require(a19_0x2d6e71(0x1c2)),{global_registry,HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE,WS_ENDPOINT,messageTypes}=require(a19_0x2d6e71(0x190)),{logger}=require('../../config/logger'),{getCredentialsPath,getGridDetails}=require(a19_0x2d6e71(0x1af)),{scaleUpHubDeployment}=require(a19_0x2d6e71(0x1c9)),{sendInstrumentationEvent}=require('../../utils/instrumentationUtils'),webSocketUtils=require('../../utils/webSocketUtils'),{createK8sClient}=require('../../utils/createk8sClient'),{getCloudProviderObject}=require('../../cloudproviders/utils');exports[a19_0x2d6e71(0x1a6)]=a19_0x2d6e71(0x1aa),exports[a19_0x2d6e71(0x1bd)]=a19_0x2d6e71(0x193),exports[a19_0x2d6e71(0x184)]=function(_0x6b9fb0){const _0x5094a6=a19_0x2d6e71,_0x535ee7={};_0x535ee7[_0x5094a6(0x1ae)]=_0x5094a6(0x186),_0x535ee7['TLIoe']=_0x5094a6(0x1b3),_0x535ee7[_0x5094a6(0x1d0)]='Skip\x20insecure\x20cert\x20verification.',_0x535ee7[_0x5094a6(0x197)]=_0x5094a6(0x18e),_0x535ee7[_0x5094a6(0x1b0)]=_0x5094a6(0x1cd);const _0x1629d9=_0x535ee7,_0x4d9721={};_0x4d9721[_0x5094a6(0x1be)]=_0x1629d9[_0x5094a6(0x1ae)],_0x4d9721[_0x5094a6(0x1a9)]=_0x1629d9[_0x5094a6(0x1bf)];const _0x108785={};_0x108785[_0x5094a6(0x1be)]=_0x1629d9[_0x5094a6(0x1d0)],_0x108785[_0x5094a6(0x1a9)]=_0x1629d9['PVObd'],_0x108785[_0x5094a6(0x182)]=![];const _0x5aa3c5={};return _0x5aa3c5[_0x5094a6(0x1d9)]=_0x4d9721,_0x5aa3c5[_0x5094a6(0x1b4)]=_0x108785,_0x6b9fb0[_0x5094a6(0x189)](HELP_HEADER_MESSAGE[_0x5094a6(0x198)])['epilogue'](HELP_FOOTER_MESSAGE)['options'](_0x5aa3c5)[_0x5094a6(0x1cd)](_0x1629d9[_0x5094a6(0x1b0)])[_0x5094a6(0x19d)];},exports['handler']=async function(_0x205744){const _0x59f157=a19_0x2d6e71,_0x469727={'DjvXa':_0x59f157(0x1a3),'cKduy':function(_0x4c5d77){return _0x4c5d77();},'naULD':_0x59f157(0x1ac),'KjTLj':function(_0x2554bc,_0x3414f3,_0x59fd14,_0x319adb,_0x3a0dc2,_0x17b302,_0x40162a){return _0x2554bc(_0x3414f3,_0x59fd14,_0x319adb,_0x3a0dc2,_0x17b302,_0x40162a);},'MNUsY':'start-grid-called','ZainD':_0x59f157(0x1ab),'KXuPo':function(_0xb3bb2a,_0x5c9dcf,_0x67131d,_0x104de6,_0xb4ed33,_0xa26e92,_0x84d768){return _0xb3bb2a(_0x5c9dcf,_0x67131d,_0x104de6,_0xb4ed33,_0xa26e92,_0x84d768);},'OCdNW':function(_0x442ab0){return _0x442ab0();},'teGZl':_0x59f157(0x18b),'TARWn':_0x59f157(0x1c6),'qDjnc':_0x59f157(0x18c),'chORw':function(_0x4ddb71,_0x55c4da,_0x527354,_0x2e2daf){return _0x4ddb71(_0x55c4da,_0x527354,_0x2e2daf);},'gQozI':function(_0x5a4cca,_0x3f7cd5,_0x185f3e,_0x5db994,_0x13cb4e,_0x3294df,_0x1e0449){return _0x5a4cca(_0x3f7cd5,_0x185f3e,_0x5db994,_0x13cb4e,_0x3294df,_0x1e0449);},'ynuQE':function(_0x1e6ed7,_0x5c7f14,_0x54786b){return _0x1e6ed7(_0x5c7f14,_0x54786b);},'HJIVA':_0x59f157(0x199),'rrhun':function(_0x612406,_0x24b956){return _0x612406===_0x24b956;},'xzaLX':_0x59f157(0x1b5),'vjspm':function(_0x5e4e31,_0x55f6e1,_0x264245,_0x5d097d,_0x40c64a,_0x592474,_0x499bea){return _0x5e4e31(_0x55f6e1,_0x264245,_0x5d097d,_0x40c64a,_0x592474,_0x499bea);},'CCsnI':_0x59f157(0x1c3),'qeGaq':function(_0x48d775,_0xde958c){return _0x48d775===_0xde958c;},'DrouV':function(_0x353410,_0x142848,_0x1816a9,_0x5d5d57,_0x125cfe,_0x25a187,_0x58b75c){return _0x353410(_0x142848,_0x1816a9,_0x5d5d57,_0x125cfe,_0x25a187,_0x58b75c);},'CvJSc':_0x59f157(0x1d8),'hPNSV':function(_0xef0df5,_0x57428f,_0x3309fd,_0xe3bd62,_0xc289d9,_0x24efcb,_0x3f468b){return _0xef0df5(_0x57428f,_0x3309fd,_0xe3bd62,_0xc289d9,_0x24efcb,_0x3f468b);},'iehWi':_0x59f157(0x1a1)};let _0x21a8d0;try{!_0x205744[_0x59f157(0x1d4)]&&(logger[_0x59f157(0x18f)](_0x469727[_0x59f157(0x1cc)]),process[_0x59f157(0x18d)](0x1));!fs[_0x59f157(0x1de)](_0x469727[_0x59f157(0x181)](getCredentialsPath))&&(logger['error'](_0x469727[_0x59f157(0x1c1)]),await _0x469727[_0x59f157(0x19e)](sendInstrumentationEvent,_0x205744,_0x469727[_0x59f157(0x1b7)],messageTypes['ERROR'],_0x469727[_0x59f157(0x1c8)],null,_0x205744),process[_0x59f157(0x18d)](0x1));logger[_0x59f157(0x1d2)]('Starting\x20grid\x20'+_0x205744['gridId']),await _0x469727[_0x59f157(0x1b1)](sendInstrumentationEvent,_0x205744,_0x469727['MNUsY'],messageTypes[_0x59f157(0x1dd)],null,null,_0x205744);const _0x36fab7=JSON[_0x59f157(0x1a2)](fs[_0x59f157(0x1a7)](_0x469727[_0x59f157(0x1db)](getCredentialsPath)));global_registry[_0x59f157(0x1cb)]=_0x36fab7['Browserstack'][_0x59f157(0x19a)],global_registry[_0x59f157(0x1a5)]=_0x36fab7[_0x59f157(0x1d1)]['password'];const _0x3a7709=WS_ENDPOINT[_0x59f157(0x185)](_0x469727['teGZl'],_0x36fab7[_0x59f157(0x1d1)][_0x59f157(0x19a)])[_0x59f157(0x185)](_0x469727[_0x59f157(0x1dc)],_0x36fab7[_0x59f157(0x1d1)][_0x59f157(0x19c)]),_0x157c1a={};_0x157c1a[_0x59f157(0x1d7)]=ws,_0x157c1a[_0x59f157(0x1cf)]=0x36ee80,_0x21a8d0=new ReconnectingWebSocket(_0x3a7709,[],_0x157c1a),logger[_0x59f157(0x1da)](_0x469727[_0x59f157(0x1b9)]),webSocketUtils[_0x59f157(0x19b)](_0x21a8d0,_0x205744[_0x59f157(0x1a8)],_0x205744['password']);const [_0x2641de,_0x13c96e]=await _0x469727['chORw'](getGridDetails,_0x36fab7[_0x59f157(0x1d1)][_0x59f157(0x19a)],_0x36fab7[_0x59f157(0x1d1)][_0x59f157(0x19c)],_0x205744[_0x59f157(0x1d4)]);if(_0x13c96e){const _0x392245=_0x13c96e[_0x59f157(0x1d2)];global_registry[_0x59f157(0x180)]=_0x392245[_0x59f157(0x180)],global_registry[_0x59f157(0x1ce)]=_0x392245[_0x59f157(0x1c0)],global_registry[_0x59f157(0x195)]=_0x392245['clusterName'];const _0x317527=await _0x469727[_0x59f157(0x183)](getCloudProviderObject,_0x392245[_0x59f157(0x180)],_0x392245['clusterName'],_0x392245['name'],_0x21a8d0,webSocketUtils,_0x205744),[_0x16ce55,_0x15f7c9,_0x821512,_0x57f7fe,_0x4ae0b7,_0x270c10]=await _0x469727[_0x59f157(0x1b2)](createK8sClient,_0x317527,_0x205744[_0x59f157(0x1c5)]);await _0x469727[_0x59f157(0x1b2)](scaleUpHubDeployment,_0x15f7c9,_0x392245['name']),logger[_0x59f157(0x1d2)](_0x469727[_0x59f157(0x1ca)]),process[_0x59f157(0x18d)](0x0);}_0x469727[_0x59f157(0x1c4)](_0x2641de[_0x59f157(0x191)],0x191)&&(logger[_0x59f157(0x18f)](_0x469727[_0x59f157(0x17f)]),await _0x469727['vjspm'](sendInstrumentationEvent,_0x205744,_0x469727['MNUsY'],messageTypes[_0x59f157(0x187)],_0x469727[_0x59f157(0x1b6)],null,_0x205744),process['exit'](0x1)),_0x469727['qeGaq'](_0x2641de[_0x59f157(0x191)],0x190)&&(logger[_0x59f157(0x18f)](JSON[_0x59f157(0x1a2)](_0x2641de[_0x59f157(0x1bb)])[_0x59f157(0x1b8)]),await _0x469727[_0x59f157(0x1bc)](sendInstrumentationEvent,_0x205744,_0x469727[_0x59f157(0x1b7)],messageTypes[_0x59f157(0x187)],_0x469727['CvJSc'],null,_0x205744),process[_0x59f157(0x18d)](0x1)),logger[_0x59f157(0x18f)]('Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Response\x20from\x20server:\x20'+JSON['stringify'](_0x2641de)),await _0x469727[_0x59f157(0x1d6)](sendInstrumentationEvent,_0x205744,_0x469727[_0x59f157(0x1b7)],messageTypes['ERROR'],_0x469727[_0x59f157(0x192)],_0x2641de,_0x205744),process[_0x59f157(0x18d)](0x1);}catch(_0x495ef5){const _0x49ce9e='Unable\x20to\x20start\x20the\x20Grid!\x20Error:\x20'+_0x495ef5+'\x20\x0a'+JSON['stringify'](_0x495ef5[_0x59f157(0x188)])+'\x20';logger['error'](_0x49ce9e),process['exit'](0x1);}};
|
package/ats/src/commands/stop.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a20_0x594f(){const _0x511650=['builder','usage','20EGIyHx','329PsXNqU','4SwTDAE','desc','stop','Stop\x20a\x20running\x20Automation\x20grid.','handler','RwYqh','help','3556935AYjsuM','demandCommand','../config/constants','epilogue','527487ndrjcg','718sJShgY','commandDir','6431650MFAkHa','strict','12712458DjkDzs','7648ycrkzp','960702LwalVw','stop_commands','333kaUmQu'];a20_0x594f=function(){return _0x511650;};return a20_0x594f();}const a20_0x34b3a4=a20_0x2245;(function(_0x2f019e,_0x39c8f0){const _0x596bf2=a20_0x2245,_0x4c2483=_0x2f019e();while(!![]){try{const _0x6aaa05=parseInt(_0x596bf2(0xe0))/0x1*(-parseInt(_0x596bf2(0xf1))/0x2)+-parseInt(_0x596bf2(0xf0))/0x3*(parseInt(_0x596bf2(0xe5))/0x4)+parseInt(_0x596bf2(0xe3))/0x5*(parseInt(_0x596bf2(0xde))/0x6)+parseInt(_0x596bf2(0xe4))/0x7*(parseInt(_0x596bf2(0xdd))/0x8)+-parseInt(_0x596bf2(0xec))/0x9+-parseInt(_0x596bf2(0xda))/0xa+parseInt(_0x596bf2(0xdc))/0xb;if(_0x6aaa05===_0x39c8f0)break;else _0x4c2483['push'](_0x4c2483['shift']());}catch(_0x384066){_0x4c2483['push'](_0x4c2483['shift']());}}}(a20_0x594f,0x7bdba));function a20_0x2245(_0x40f4f6,_0x2534c6){const _0x594f27=a20_0x594f();return a20_0x2245=function(_0x224579,_0x4cf4d6){_0x224579=_0x224579-0xda;let _0x596d00=_0x594f27[_0x224579];return _0x596d00;},a20_0x2245(_0x40f4f6,_0x2534c6);}const {HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE}=require(a20_0x34b3a4(0xee));exports['command']='stop',exports[a20_0x34b3a4(0xe6)]=a20_0x34b3a4(0xe8),exports[a20_0x34b3a4(0xe1)]=function(_0x45fed9){const _0x2ad939=a20_0x34b3a4,_0x4f9ce3={};_0x4f9ce3['WworY']=_0x2ad939(0xdf),_0x4f9ce3[_0x2ad939(0xea)]=_0x2ad939(0xeb);const _0x4ee793=_0x4f9ce3;return _0x45fed9[_0x2ad939(0xe2)](HELP_HEADER_MESSAGE[_0x2ad939(0xe7)])[_0x2ad939(0xef)](HELP_FOOTER_MESSAGE)[_0x2ad939(0xf2)](_0x4ee793['WworY'])[_0x2ad939(0xed)]()['recommendCommands']()[_0x2ad939(0xdb)]()[_0x2ad939(0xeb)](_0x4ee793[_0x2ad939(0xea)]);},exports[a20_0x34b3a4(0xe9)]=function(_0x15efa6){};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a21_0x3bf5bc=a21_0x111f;function a21_0x111f(_0x5cc024,_0x21d2f5){const _0xc8ea5f=a21_0xc8ea();return a21_0x111f=function(_0x111f8e,_0x80b9f9){_0x111f8e=_0x111f8e-0x1a7;let _0x3d05d7=_0xc8ea5f[_0x111f8e];return _0x3d05d7;},a21_0x111f(_0x5cc024,_0x21d2f5);}function a21_0xc8ea(){const _0x6685ac=['xMkBg','../../cloudproviders/utils','server-error','Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Response\x20from\x20server:\x20','907497LEOYJF','NRVrI','type','stringify','debug','parse','IWPxO','unauthorised','5238226Bhxhph','password','8998ZvNUSC','bstackUsername','statusCode','epilogue','Please\x20provide\x20ID\x20of\x20the\x20grid\x20to\x20stop','irgkX','skipTlsCertVerify','../../utils/utilityMethods','message','../../utils/instrumentationUtils','invalid-grid-id','argv','qlTvC','<UsernamePlaceholder>','tnZaG','FNRDO','usage','YVHuS','existsSync','uFHBy','Stopping\x20grid\x20','2870mRbEZG','options','info','Failed\x20to\x20fetch\x20grid\x20details\x20from\x20the\x20server.\x20Unauthorized\x20request!','87900YeFZBT','NmZQV','53346jmEyQQ','clusterName','cloudProvider','Pass\x20the\x20ID\x20of\x20the\x20running\x20Automation\x20grid\x20you\x20want\x20to\x20stop.','boolean','clusterRegion','stop-grid-called','description','aRgsY','help','IKllR','skip-tls-cert-verify','builder','gridId','afbWW','12BOZwpl','ERROR','exit','1407GsVhac','GiqOH','init-not-called','../../config/constants','MQfYr','Credentials\x20not\x20found!\x20Ensure\x20init\x20command\x20is\x20run\x20before\x20running\x20this\x20command.','username','grid-id','stop','WebSocket','../../config/logger','972128XLHEyD','handler','Adding\x20Websocket\x20listeners','Browserstack','error','reconnecting-websocket','command','name','IXUht','addListeners','Stop\x20a\x20running\x20Automation\x20grid.','Grid\x20stoppped.','115XoIEDl','ORALP','string','uMLsA','LkPMI','5416aHOWsy','../../utils/webSocketUtils','user','wLjig'];a21_0xc8ea=function(){return _0x6685ac;};return a21_0xc8ea();}(function(_0x3ccefb,_0x171c47){const _0x4f62ad=a21_0x111f,_0x1002f1=_0x3ccefb();while(!![]){try{const _0x5e5f6d=-parseInt(_0x4f62ad(0x1c5))/0x1*(parseInt(_0x4f62ad(0x1b4))/0x2)+-parseInt(_0x4f62ad(0x1c8))/0x3*(-parseInt(_0x4f62ad(0x1e4))/0x4)+parseInt(_0x4f62ad(0x1df))/0x5*(-parseInt(_0x4f62ad(0x1b6))/0x6)+parseInt(_0x4f62ad(0x1f4))/0x7+parseInt(_0x4f62ad(0x1d3))/0x8+-parseInt(_0x4f62ad(0x1ec))/0x9+-parseInt(_0x4f62ad(0x1b0))/0xa*(parseInt(_0x4f62ad(0x1f6))/0xb);if(_0x5e5f6d===_0x171c47)break;else _0x1002f1['push'](_0x1002f1['shift']());}catch(_0x4a62e9){_0x1002f1['push'](_0x1002f1['shift']());}}}(a21_0xc8ea,0x6ac78));const fs=require('fs'),ws=require('ws'),ReconnectingWebSocket=require(a21_0x3bf5bc(0x1d8)),{global_registry,HELP_HEADER_MESSAGE,HELP_FOOTER_MESSAGE,WS_ENDPOINT,messageTypes}=require(a21_0x3bf5bc(0x1cb)),{logger}=require(a21_0x3bf5bc(0x1d2)),{getCredentialsPath,getGridDetails}=require(a21_0x3bf5bc(0x1fd)),{scaleDownHubDeployment}=require('../../utils/gridComponents'),{sendInstrumentationEvent}=require(a21_0x3bf5bc(0x1ff)),webSocketUtils=require(a21_0x3bf5bc(0x1e5)),{createK8sClient}=require('../../utils/createk8sClient'),{getCloudProviderObject}=require(a21_0x3bf5bc(0x1e9));exports[a21_0x3bf5bc(0x1d9)]='grid',exports['desc']=a21_0x3bf5bc(0x1dd),exports[a21_0x3bf5bc(0x1c2)]=function(_0x413f0f){const _0x1c01f9=a21_0x3bf5bc,_0x343c16={};_0x343c16[_0x1c01f9(0x1a9)]=_0x1c01f9(0x1b9),_0x343c16['uFHBy']=_0x1c01f9(0x1e1),_0x343c16[_0x1c01f9(0x1e0)]='Skip\x20insecure\x20cert\x20verification.',_0x343c16[_0x1c01f9(0x1be)]=_0x1c01f9(0x1ba),_0x343c16[_0x1c01f9(0x1e7)]='help';const _0x3b7040=_0x343c16,_0x5723bf={};_0x5723bf['description']=_0x3b7040[_0x1c01f9(0x1a9)],_0x5723bf[_0x1c01f9(0x1ee)]=_0x3b7040[_0x1c01f9(0x1ae)];const _0x32bc06={};_0x32bc06[_0x1c01f9(0x1bd)]=_0x3b7040[_0x1c01f9(0x1e0)],_0x32bc06[_0x1c01f9(0x1ee)]=_0x3b7040[_0x1c01f9(0x1be)],_0x32bc06['default']=![];const _0x3c71ec={};return _0x3c71ec[_0x1c01f9(0x1cf)]=_0x5723bf,_0x3c71ec[_0x1c01f9(0x1c1)]=_0x32bc06,_0x413f0f[_0x1c01f9(0x1ab)](HELP_HEADER_MESSAGE[_0x1c01f9(0x1d0)])[_0x1c01f9(0x1f9)](HELP_FOOTER_MESSAGE)[_0x1c01f9(0x1b1)](_0x3c71ec)[_0x1c01f9(0x1bf)](_0x3b7040['wLjig'])[_0x1c01f9(0x201)];},exports[a21_0x3bf5bc(0x1d4)]=async function(_0x1a1d39){const _0x258c66=a21_0x3bf5bc,_0x443abc={'NmZQV':_0x258c66(0x1fa),'YVHuS':function(_0x143034){return _0x143034();},'qlTvC':_0x258c66(0x1cd),'NRVrI':function(_0x5a0658,_0x4ae4d4,_0x26df66,_0x658e3a,_0xcdc096,_0xfc9bb1,_0x30a6d7){return _0x5a0658(_0x4ae4d4,_0x26df66,_0x658e3a,_0xcdc096,_0xfc9bb1,_0x30a6d7);},'IWPxO':_0x258c66(0x1bc),'LkPMI':_0x258c66(0x1ca),'irgkX':function(_0x2f31c,_0x2ff9bd,_0x9f582,_0x4cb080,_0x445d23,_0x1a6d2d,_0x358018){return _0x2f31c(_0x2ff9bd,_0x9f582,_0x4cb080,_0x445d23,_0x1a6d2d,_0x358018);},'GiqOH':function(_0x246005){return _0x246005();},'afbWW':_0x258c66(0x1a8),'xQgZc':'<PasswordPlaceholder>','uMLsA':_0x258c66(0x1d5),'HEjiv':function(_0x2a6177,_0x68a68f,_0x5d6a24,_0x13a00a){return _0x2a6177(_0x68a68f,_0x5d6a24,_0x13a00a);},'xMkBg':function(_0x57bc3d,_0x309a51,_0x317dd6){return _0x57bc3d(_0x309a51,_0x317dd6);},'cOJgo':_0x258c66(0x1de),'ipNTd':function(_0xfef393,_0x28ee44){return _0xfef393===_0x28ee44;},'CkfkL':_0x258c66(0x1b3),'IKllR':function(_0x8d1911,_0x4f7fe0,_0x59a1b7,_0x405fbb,_0x187c4d,_0x81bbc5,_0x29ae3f){return _0x8d1911(_0x4f7fe0,_0x59a1b7,_0x405fbb,_0x187c4d,_0x81bbc5,_0x29ae3f);},'MQfYr':_0x258c66(0x1f3),'oieCS':function(_0x2e9951,_0x435dd0){return _0x2e9951===_0x435dd0;},'IXUht':_0x258c66(0x200),'FNRDO':_0x258c66(0x1ea)};let _0x22a3f0;try{!_0x1a1d39[_0x258c66(0x1c3)]&&(logger[_0x258c66(0x1d7)](_0x443abc[_0x258c66(0x1b5)]),process[_0x258c66(0x1c7)](0x1));!fs[_0x258c66(0x1ad)](_0x443abc[_0x258c66(0x1ac)](getCredentialsPath))&&(logger[_0x258c66(0x1d7)](_0x443abc[_0x258c66(0x1a7)]),await _0x443abc[_0x258c66(0x1ed)](sendInstrumentationEvent,_0x1a1d39,_0x443abc[_0x258c66(0x1f2)],messageTypes[_0x258c66(0x1c6)],_0x443abc[_0x258c66(0x1e3)],null,_0x1a1d39),process['exit'](0x1));logger[_0x258c66(0x1b2)](_0x258c66(0x1af)+_0x1a1d39[_0x258c66(0x1c3)]),await _0x443abc['irgkX'](sendInstrumentationEvent,_0x1a1d39,_0x443abc['IWPxO'],messageTypes['INFO'],null,null,_0x1a1d39);const _0x5860ef=JSON[_0x258c66(0x1f1)](fs['readFileSync'](_0x443abc[_0x258c66(0x1c9)](getCredentialsPath)));global_registry[_0x258c66(0x1f7)]=_0x5860ef['Browserstack'][_0x258c66(0x1ce)],global_registry['bstackAccesskey']=_0x5860ef[_0x258c66(0x1d6)][_0x258c66(0x1f5)];const _0x3d4932=WS_ENDPOINT['replace'](_0x443abc[_0x258c66(0x1c4)],_0x5860ef[_0x258c66(0x1d6)][_0x258c66(0x1ce)])['replace'](_0x443abc['xQgZc'],_0x5860ef[_0x258c66(0x1d6)][_0x258c66(0x1f5)]),_0x13f51d={};_0x13f51d[_0x258c66(0x1d1)]=ws,_0x13f51d['connectionTimeout']=0x36ee80,_0x22a3f0=new ReconnectingWebSocket(_0x3d4932,[],_0x13f51d),logger[_0x258c66(0x1f0)](_0x443abc[_0x258c66(0x1e2)]),webSocketUtils[_0x258c66(0x1dc)](_0x22a3f0,_0x1a1d39[_0x258c66(0x1e6)],_0x1a1d39[_0x258c66(0x1f5)]);const [_0x5e3d6b,_0x2ee0a9]=await _0x443abc['HEjiv'](getGridDetails,_0x5860ef['Browserstack']['username'],_0x5860ef['Browserstack']['password'],_0x1a1d39[_0x258c66(0x1c3)]);if(_0x2ee0a9){const _0x3e8b04=_0x2ee0a9[_0x258c66(0x1b2)];global_registry[_0x258c66(0x1b8)]=_0x3e8b04['cloudProvider'],global_registry[_0x258c66(0x1bb)]=_0x3e8b04['region'],global_registry['clusterName']=_0x3e8b04['clusterName'];const _0x3a7c1a=await _0x443abc[_0x258c66(0x1fb)](getCloudProviderObject,_0x3e8b04[_0x258c66(0x1b8)],_0x3e8b04[_0x258c66(0x1b7)],_0x3e8b04[_0x258c66(0x1da)],_0x22a3f0,webSocketUtils,_0x1a1d39),[_0x1e734e,_0x5b35d4,_0x5f116a,_0x526c77,_0x4b7ada,_0x55b0fc]=await _0x443abc[_0x258c66(0x1e8)](createK8sClient,_0x3a7c1a,_0x1a1d39[_0x258c66(0x1fc)]);await _0x443abc['xMkBg'](scaleDownHubDeployment,_0x5b35d4,_0x3e8b04[_0x258c66(0x1da)]),logger['info'](_0x443abc['cOJgo']),process[_0x258c66(0x1c7)](0x0);}_0x443abc['ipNTd'](_0x5e3d6b['statusCode'],0x191)&&(logger[_0x258c66(0x1d7)](_0x443abc['CkfkL']),await _0x443abc[_0x258c66(0x1c0)](sendInstrumentationEvent,_0x1a1d39,_0x443abc[_0x258c66(0x1f2)],messageTypes[_0x258c66(0x1c6)],_0x443abc[_0x258c66(0x1cc)],null,_0x1a1d39),process['exit'](0x1)),_0x443abc['oieCS'](_0x5e3d6b[_0x258c66(0x1f8)],0x190)&&(logger['error'](JSON[_0x258c66(0x1f1)](_0x5e3d6b['body'])[_0x258c66(0x1fe)]),await _0x443abc['IKllR'](sendInstrumentationEvent,_0x1a1d39,_0x443abc[_0x258c66(0x1f2)],messageTypes['ERROR'],_0x443abc[_0x258c66(0x1db)],null,_0x1a1d39),process[_0x258c66(0x1c7)](0x1)),logger[_0x258c66(0x1d7)](_0x258c66(0x1eb)+JSON[_0x258c66(0x1ef)](_0x5e3d6b)),await _0x443abc['IKllR'](sendInstrumentationEvent,_0x1a1d39,_0x443abc[_0x258c66(0x1f2)],messageTypes[_0x258c66(0x1c6)],_0x443abc[_0x258c66(0x1aa)],_0x5e3d6b,_0x1a1d39),process['exit'](0x1);}catch(_0x2a6a4d){const _0x4d33cc='Unable\x20to\x20stop\x20the\x20Grid!\x20Error:\x20'+_0x2a6a4d+'\x20\x0a'+JSON[_0x258c66(0x1ef)](_0x2a6a4d['stack'])+'\x20';logger[_0x258c66(0x1d7)](_0x4d33cc),process[_0x258c66(0x1c7)](0x1);}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a22_0x2fa143=a22_0x56cc;(function(_0x4543ed,_0x580231){const _0x5c5c84=a22_0x56cc,_0x5bd968=_0x4543ed();while(!![]){try{const _0x320d16=parseInt(_0x5c5c84(0x174))/0x1*(-parseInt(_0x5c5c84(0x196))/0x2)+-parseInt(_0x5c5c84(0x1b5))/0x3*(parseInt(_0x5c5c84(0x1a0))/0x4)+-parseInt(_0x5c5c84(0x1b7))/0x5+-parseInt(_0x5c5c84(0x18c))/0x6+-parseInt(_0x5c5c84(0x186))/0x7+parseInt(_0x5c5c84(0x15f))/0x8*(-parseInt(_0x5c5c84(0x15b))/0x9)+parseInt(_0x5c5c84(0x1a8))/0xa;if(_0x320d16===_0x580231)break;else _0x5bd968['push'](_0x5bd968['shift']());}catch(_0x17b06c){_0x5bd968['push'](_0x5bd968['shift']());}}}(a22_0x5c17,0x59f7f),require(a22_0x2fa143(0x198))[a22_0x2fa143(0x164)](),exports[a22_0x2fa143(0x18a)]=process['env']['DASHBOARD_ENDPOINT']||'grid.browserstack.com',exports[a22_0x2fa143(0x1a3)]=process[a22_0x2fa143(0x1a9)]['BS_API_URL']||a22_0x2fa143(0x170),exports['AG_API_URL']=process[a22_0x2fa143(0x1a9)][a22_0x2fa143(0x161)]||a22_0x2fa143(0x19a),exports[a22_0x2fa143(0x1bd)]=a22_0x2fa143(0x180)+this[a22_0x2fa143(0x161)]+'/ws?username=<UsernamePlaceholder>&password=<PasswordPlaceholder>',exports[a22_0x2fa143(0x195)]=a22_0x2fa143(0x1a4),exports[a22_0x2fa143(0x187)]=a22_0x2fa143(0x173),exports['DEFAULT_GRID_NAME']='high-scale-grid',exports['AWS']=a22_0x2fa143(0x190),exports[a22_0x2fa143(0x16c)]=a22_0x2fa143(0x17b),exports[a22_0x2fa143(0x168)]=a22_0x2fa143(0x1bb),exports['CLUSTER_HUB_HA_STACK_NAME']='BSTACK-ATS-CLUSTER-HUB-HA',exports[a22_0x2fa143(0x18e)]='browserstack-turboscale-grid',exports['AZURE']=a22_0x2fa143(0x191),exports[a22_0x2fa143(0x167)]=a22_0x2fa143(0x178),exports['ALL_SUPPORTED_CLOUD_PROVIDERS']=[this['AWS'],this[a22_0x2fa143(0x17a)],this[a22_0x2fa143(0x167)]]);const a22_0xc85d8a={};a22_0xc85d8a[a22_0x2fa143(0x194)]=a22_0x2fa143(0x1ad),a22_0xc85d8a[a22_0x2fa143(0x16b)]=a22_0x2fa143(0x1ac);const a22_0x25b5dd={};a22_0x25b5dd[a22_0x2fa143(0x194)]='browserstack:service',a22_0x25b5dd[a22_0x2fa143(0x16b)]=a22_0x2fa143(0x1a2);const common_hst_tags_list=[a22_0xc85d8a,a22_0x25b5dd];if(process[a22_0x2fa143(0x1a9)]['TURBOSCALE_CUSTOM_TAGS']){const parsedTags=process[a22_0x2fa143(0x1a9)]['TURBOSCALE_CUSTOM_TAGS'][a22_0x2fa143(0x1b4)](',');parsedTags[a22_0x2fa143(0x181)](_0x12e797=>{const _0xeccc34=a22_0x2fa143,_0x10e4fa=_0x12e797['split'](':'),_0x436868={};_0x436868[_0xeccc34(0x194)]=_0x10e4fa[0x0],_0x436868[_0xeccc34(0x16b)]=_0x10e4fa[0x1],common_hst_tags_list['push'](_0x436868);});}exports[a22_0x2fa143(0x193)]=common_hst_tags_list;function a22_0x5c17(){const _0x428ba8=['split','159cbdEdK','\x0aThis\x20command\x20will\x20list\x20down\x20the\x20resources\x20created\x20on\x20Automate\x20TurboScale.','2590660zzsbIh','high-scale-grid-cluster','list','CLI_ARGS_REGEX','BSTACK-ATS-CLUSTER-AUTOSCALER','NULL','WS_ENDPOINT','configure','[REDACTED]','234iJLOun','grid-profile','\x0aThis\x20will\x20start\x20an\x20existing\x20Automation\x20grid.','global_registry','224344IBFcwm','browserstack:service','AG_API_URL','MessageDescription','GRID_URL','config','gridUrl','AWS','GCP','CLUSTER_AUTOSCALER_STACK_NAME','https://nroujxly-hub.browserstack-ats.com/wd/hub/status','\x0aThis\x20command\x20will\x20list\x20down\x20the\x20grid\x20profiles\x20created.','Value','CLUSTER_DEP_STACK_NAME','pre-check','\x0aThis\x20command\x20will\x20take\x20you\x20through\x20the\x20initialisation\x20of\x20BrowserStack\x20CLI.','\x0a\x0aFind\x20more\x20information\x20at:\x20https://browserstack.com/docs/automate-turboscale/references/browserstack-cli','api.browserstack.com','grid','CLUSTER','BrowserStackIAMUser','17BeOgzC','\x0aThis\x20will\x20stop\x20a\x20running\x20Automation\x20grid.','\x0aThis\x20command\x20will\x20list\x20down\x20the\x20grids\x20created.','Failed\x20to\x20fetch\x20grid\x20profile\x20from\x20the\x20server','gcp','LOG','AZURE','BSTACK-ATS-CLUSTER','WARNING','warning','ERROR','stop','wss://','forEach','\x0aThis\x20will\x20check\x20the\x20pre-requisites\x20for\x20setting\x20up\x20Automation\x20grid.','cliRunFinished','CLI_RUN_STARTED','CLOUD_PROVIDER','2935695HtIgBS','IAM_USER_NAME','Use\x20\x22browserstack-cli\x20ats\x20<command_group>\x20-h/--help\x22\x20for\x20more\x20options\x20available\x20about\x20Automate\x20TurboScale.','\x0aThis\x20will\x20help\x20delete\x20the\x20Automation\x20grid.','DASHBOARD_ENDPOINT','REGION','1288734CQXReT','\x0aThis\x20will\x20help\x20create\x20a\x20new\x20Automation\x20grid.','TURBOSCALE_DEPLOYMENT','CLI_RUN_FINISHED','aws','azure','HELP_HEADER_MESSAGE','COMMON_HST_TAGS','Key','CP_CONFIG_FILE','34022rOTuXD','unknown','dotenv','messageTypes','grid-api.browserstack.com','TRIAL_GRID_URL','pre_check','success','HST_CLUSTER_TAGS','root','19540kpebAc','RESOURCES','BrowserStack-Automate-TurboScale','BS_API_URL','credentials','delete','RAW_ARGS_REGEX','\x0aThis\x20command\x20will\x20take\x20you\x20through\x20the\x20configuration\x20of\x20BrowserStack\x20CLI.','27980270cBDfiT','env','create','connect','BrowserStack','browserstack:managedBy','cliRunStarted','LINK_MESSAGE','init','UNKNOWN','error','info'];a22_0x5c17=function(){return _0x428ba8;};return a22_0x5c17();}const a22_0x52c711={};a22_0x52c711['browserstack:managedBy']=a22_0x2fa143(0x1ac),a22_0x52c711[a22_0x2fa143(0x160)]=a22_0x2fa143(0x1a2),exports[a22_0x2fa143(0x19e)]=a22_0x52c711,exports['SUPPORTED_CLOUD_PROVIDERS']=[this[a22_0x2fa143(0x166)]];const a22_0x57f8bf={};function a22_0x56cc(_0x5db415,_0x1ca93f){const _0x5c172d=a22_0x5c17();return a22_0x56cc=function(_0x56ccb1,_0x56c631){_0x56ccb1=_0x56ccb1-0x15a;let _0x423562=_0x5c172d[_0x56ccb1];return _0x423562;},a22_0x56cc(_0x5db415,_0x1ca93f);}a22_0x57f8bf[a22_0x2fa143(0x179)]='log',a22_0x57f8bf[a22_0x2fa143(0x1a1)]='resourceInfo',a22_0x57f8bf[a22_0x2fa143(0x163)]=a22_0x2fa143(0x165),a22_0x57f8bf[a22_0x2fa143(0x184)]=a22_0x2fa143(0x1ae),a22_0x57f8bf[a22_0x2fa143(0x18f)]=a22_0x2fa143(0x183),exports['WS_EVENTS']=a22_0x57f8bf,exports[a22_0x2fa143(0x15e)]={},exports['LINK_MESSAGE']=a22_0x2fa143(0x16f);const a22_0x30a171={};a22_0x30a171[a22_0x2fa143(0x19f)]='\x0aCreate\x20and\x20Manage\x20scalable\x20browser\x20automation\x20grids\x20for\x20Functional\x20Testing.'+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1b0)]=a22_0x2fa143(0x16e)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1be)]=a22_0x2fa143(0x1a7)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1aa)]=a22_0x2fa143(0x18d)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1b9)]={},a22_0x30a171[a22_0x2fa143(0x1a5)]=a22_0x2fa143(0x189)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1ab)]='\x0aThis\x20will\x20connect\x20the\x20grid\x20with\x20existing\x20VPC.'+this[a22_0x2fa143(0x1af)],a22_0x30a171['start']=a22_0x2fa143(0x15d)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x17f)]=a22_0x2fa143(0x175)+this['LINK_MESSAGE'],a22_0x30a171[a22_0x2fa143(0x19c)]=a22_0x2fa143(0x182)+this['LINK_MESSAGE'],a22_0x30a171[a22_0x2fa143(0x1b9)][a22_0x2fa143(0x19f)]=a22_0x2fa143(0x1b6)+this['LINK_MESSAGE'],a22_0x30a171[a22_0x2fa143(0x1b9)][a22_0x2fa143(0x171)]=a22_0x2fa143(0x176)+this[a22_0x2fa143(0x1af)],a22_0x30a171[a22_0x2fa143(0x1b9)]['gridProfile']=a22_0x2fa143(0x16a)+this['LINK_MESSAGE'],exports[a22_0x2fa143(0x192)]=a22_0x30a171,exports['HELP_FOOTER_MESSAGE']=a22_0x2fa143(0x188);const a22_0x2b3052={};a22_0x2b3052['SUCCESS']=a22_0x2fa143(0x19d),a22_0x2b3052[a22_0x2fa143(0x17e)]=a22_0x2fa143(0x1b2),a22_0x2b3052['INFO']=a22_0x2fa143(0x1b3),a22_0x2b3052[a22_0x2fa143(0x17c)]=a22_0x2fa143(0x17d),a22_0x2b3052[a22_0x2fa143(0x1b1)]=a22_0x2fa143(0x197),a22_0x2b3052[a22_0x2fa143(0x1bc)]=null,exports[a22_0x2fa143(0x199)]=a22_0x2b3052,exports[a22_0x2fa143(0x1ba)]=/(?<=("u"|"username"|"k"|"key") *: *)"[^,}]*/g,exports[a22_0x2fa143(0x1a6)]=/(?<=("-u"|"-username"|"-k"|"-key") *, *)"[^,\]]*/g,exports['REDACTED']=a22_0x2fa143(0x15a);const a22_0x5c0080={};a22_0x5c0080[a22_0x2fa143(0x15c)]=a22_0x2fa143(0x177);const a22_0x1327fc={};a22_0x1327fc[a22_0x2fa143(0x16d)]=a22_0x5c0080,exports[a22_0x2fa143(0x162)]=a22_0x1327fc,exports[a22_0x2fa143(0x19b)]=a22_0x2fa143(0x169);const a22_0x42b7e1={};a22_0x42b7e1[a22_0x2fa143(0x172)]=a22_0x2fa143(0x1b8),a22_0x42b7e1[a22_0x2fa143(0x185)]='aws',a22_0x42b7e1[a22_0x2fa143(0x18b)]='us-east-1',exports['DEFAULT_CLUSTER_DETAILS']=a22_0x42b7e1;
|
package/ats/src/config/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a23_0x2f4f2b=a23_0x587b;(function(_0x5178cd,_0x11db30){const _0x3b3f5d=a23_0x587b,_0x4c4ec9=_0x5178cd();while(!![]){try{const _0x1b5195=parseInt(_0x3b3f5d(0x17b))/0x1*(-parseInt(_0x3b3f5d(0x18c))/0x2)+-parseInt(_0x3b3f5d(0x175))/0x3*(-parseInt(_0x3b3f5d(0x17c))/0x4)+parseInt(_0x3b3f5d(0x179))/0x5+-parseInt(_0x3b3f5d(0x18a))/0x6*(parseInt(_0x3b3f5d(0x16e))/0x7)+-parseInt(_0x3b3f5d(0x183))/0x8+parseInt(_0x3b3f5d(0x173))/0x9*(parseInt(_0x3b3f5d(0x17f))/0xa)+parseInt(_0x3b3f5d(0x176))/0xb;if(_0x1b5195===_0x11db30)break;else _0x4c4ec9['push'](_0x4c4ec9['shift']());}catch(_0x1bf7c9){_0x4c4ec9['push'](_0x4c4ec9['shift']());}}}(a23_0x3202,0x1b918));function a23_0x3202(){const _0x2a33a7=['20cObpjL','YYYY-MM-DD\x20HH:mm:ss','join','4361CquPuy','colorize','events.log','level','transports','616914yfjaJT','log','165omWOUq','3083113IMYVzw','\x20-\x20','createLogger','613270NNOThO','Console','22251rKooOo','4700xsUagu','message','combine','10XcsfgV','usage.log','path','timestamp','1406064OwTZse','printf','existsSync','name','File','format','winston','240QTlRiY','debug'];a23_0x3202=function(){return _0x2a33a7;};return a23_0x3202();}const winston=require(a23_0x2f4f2b(0x189)),fs=require('fs'),path=require(a23_0x2f4f2b(0x181)),logDir=a23_0x2f4f2b(0x174);!fs[a23_0x2f4f2b(0x185)](logDir)&&fs['mkdirSync'](logDir);const a23_0x52b224={};function a23_0x587b(_0x17da8a,_0x47fa4a){const _0x3202d8=a23_0x3202();return a23_0x587b=function(_0x587b75,_0x469394){_0x587b75=_0x587b75-0x16e;let _0x12b573=_0x3202d8[_0x587b75];return _0x12b573;},a23_0x587b(_0x17da8a,_0x47fa4a);}a23_0x52b224['format']=a23_0x2f4f2b(0x18d);const a23_0x3c5398={};a23_0x3c5398[a23_0x2f4f2b(0x171)]=!![];const a23_0x44e2c8={};a23_0x44e2c8[a23_0x2f4f2b(0x186)]='console.info',exports['logger']=new winston['createLogger']({'format':winston[a23_0x2f4f2b(0x188)][a23_0x2f4f2b(0x17e)](winston[a23_0x2f4f2b(0x188)]['timestamp'](a23_0x52b224),winston[a23_0x2f4f2b(0x188)][a23_0x2f4f2b(0x16f)](a23_0x3c5398),winston[a23_0x2f4f2b(0x188)][a23_0x2f4f2b(0x184)](_0x1405f5=>_0x1405f5[a23_0x2f4f2b(0x182)]+a23_0x2f4f2b(0x177)+_0x1405f5[a23_0x2f4f2b(0x171)]+':\x20'+_0x1405f5[a23_0x2f4f2b(0x17d)])),'transports':[new winston[(a23_0x2f4f2b(0x172))][(a23_0x2f4f2b(0x17a))](a23_0x44e2c8),new winston[(a23_0x2f4f2b(0x172))]['File']({'filename':path[a23_0x2f4f2b(0x18e)](logDir,a23_0x2f4f2b(0x170)),'level':a23_0x2f4f2b(0x18b)})]});const winstonFileLoggerParams={'transports':[new winston['transports'][(a23_0x2f4f2b(0x187))]({'filename':path['join'](logDir,a23_0x2f4f2b(0x180)),'level':a23_0x2f4f2b(0x18b)})]};exports['fileLogger']=new winston[(a23_0x2f4f2b(0x178))](winstonFileLoggerParams);
|
package/ats/src/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
'use strict';
|
|
2
|
+
'use strict';const a24_0x390ffa=a24_0x5ce6;(function(_0x2ae3a7,_0x3d2efb){const _0x1ee840=a24_0x5ce6,_0xbb6e87=_0x2ae3a7();while(!![]){try{const _0x1b9f32=parseInt(_0x1ee840(0xfa))/0x1*(-parseInt(_0x1ee840(0x100))/0x2)+parseInt(_0x1ee840(0x101))/0x3+parseInt(_0x1ee840(0xf9))/0x4+parseInt(_0x1ee840(0xfb))/0x5*(parseInt(_0x1ee840(0x106))/0x6)+parseInt(_0x1ee840(0xfc))/0x7+parseInt(_0x1ee840(0x10b))/0x8+-parseInt(_0x1ee840(0x109))/0x9;if(_0x1b9f32===_0x3d2efb)break;else _0xbb6e87['push'](_0xbb6e87['shift']());}catch(_0x2231db){_0xbb6e87['push'](_0xbb6e87['shift']());}}}(a24_0x2f8f,0xa9c13));function a24_0x5ce6(_0x21314c,_0x23f24e){const _0x2f8f8a=a24_0x2f8f();return a24_0x5ce6=function(_0x5ce67b,_0x410389){_0x5ce67b=_0x5ce67b-0xf8;let _0x10be19=_0x2f8f8a[_0x5ce67b];return _0x10be19;},a24_0x5ce6(_0x21314c,_0x23f24e);}const {HELP_FOOTER_MESSAGE,HELP_HEADER_MESSAGE}=require(a24_0x390ffa(0xf8));process['env'][a24_0x390ffa(0x103)]=0x1;function a24_0x2f8f(){const _0x3a1a1a=['3198268ZCzALd','79372VTTuYT','40AZcIPU','1758540BjerKR','commandDir','RfofV','help','28eDUBOX','1296366mPOeHW','root','AWS_SDK_JS_SUPPRESS_MAINTENANCE_MODE_MESSAGE','epilogue','demandCommand','650136MDfNCH','jdpQj','usage','7943004qSiNAY','exports','2714576RSRhqc','./config/constants'];a24_0x2f8f=function(){return _0x3a1a1a;};return a24_0x2f8f();}function run(_0x3db940){const _0xc12d5d=a24_0x390ffa,_0x1fe053={};_0x1fe053[_0xc12d5d(0xfe)]='commands',_0x1fe053[_0xc12d5d(0x107)]=_0xc12d5d(0xff);const _0x40f05e=_0x1fe053;_0x3db940[_0xc12d5d(0x108)](HELP_HEADER_MESSAGE[_0xc12d5d(0x102)])[_0xc12d5d(0xfd)](_0x40f05e[_0xc12d5d(0xfe)])[_0xc12d5d(0x105)]()['help'](_0x40f05e[_0xc12d5d(0x107)])[_0xc12d5d(0x104)](HELP_FOOTER_MESSAGE);}module[a24_0x390ffa(0x10a)]=run;
|