@maka/maka-cli 5.0.21 → 5.0.24
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/bundle/obf/package.json +53 -56
- package/bundle/obf/src/command.js +1 -1
- package/bundle/obf/src/commands/_index.js +1 -1
- package/bundle/obf/src/commands/ai.js +1 -1
- package/bundle/obf/src/commands/aws/_index.js +1 -1
- package/bundle/obf/src/commands/aws/aws.command.js +1 -1
- package/bundle/obf/src/commands/aws/cecr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/chz.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ci.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ckp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/csg.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/decr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/di.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/dkp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/dsg.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/lecr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rbi.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rdn.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rkp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/sth.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ti.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/build/_index.js +1 -1
- package/bundle/obf/src/commands/build/build.js +1 -1
- package/bundle/obf/src/commands/build/docker.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/create.js +1 -1
- package/bundle/obf/src/commands/debug.js +1 -1
- package/bundle/obf/src/commands/deploy/_index.js +1 -1
- package/bundle/obf/src/commands/deploy/deploy.command.js +1 -1
- package/bundle/obf/src/commands/deploy/galaxy.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/deploy/ubuntu.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/_index.js +1 -1
- package/bundle/obf/src/commands/game/battleship.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/play.command.js +1 -1
- package/bundle/obf/src/commands/game/pong.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/command.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/drop.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/equip.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/go.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/lock.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/look.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/say.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/search.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/solve.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/take.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/unequip.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/unlock.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/use.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/factories/commandF.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/factories/roomsF.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/game.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/_index.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/door.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/inventory.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/item.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/npc.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/player.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/puzzle.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/room.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/scene.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/scenes/items.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/scenes/rooms.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/abstracts.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/enums.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/interfaces.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/types.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/ui.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/utilities/logger.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/snake.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/tetris.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/generate.js +1 -1
- package/bundle/obf/src/commands/get/_index.js +1 -1
- package/bundle/obf/src/commands/get/get.command.js +1 -1
- package/bundle/obf/src/commands/get/global.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/get/local.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/get/whoami.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/help.js +1 -1
- package/bundle/obf/src/commands/install.js +1 -1
- package/bundle/obf/src/commands/jsdoc.js +1 -1
- package/bundle/obf/src/commands/lint.js +1 -1
- package/bundle/obf/src/commands/login.js +1 -1
- package/bundle/obf/src/commands/logout.js +1 -1
- package/bundle/obf/src/commands/logs.js +1 -1
- package/bundle/obf/src/commands/maka.cmd.js +1 -1
- package/bundle/obf/src/commands/murder.js +1 -1
- package/bundle/obf/src/commands/profile.js +1 -1
- package/bundle/obf/src/commands/proxy.js +1 -1
- package/bundle/obf/src/commands/reconfig.js +1 -1
- package/bundle/obf/src/commands/register.js +1 -1
- package/bundle/obf/src/commands/run/_index.js +1 -1
- package/bundle/obf/src/commands/run/docker.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/run/run.command.js +1 -1
- package/bundle/obf/src/commands/set/_index.js +1 -1
- package/bundle/obf/src/commands/set/global.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/set/local.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/set/set.command.js +1 -1
- package/bundle/obf/src/commands/ssh.js +1 -1
- package/bundle/obf/src/commands/ssl.js +1 -1
- package/bundle/obf/src/commands/test.js +1 -1
- package/bundle/obf/src/commands/undo.js +1 -1
- package/bundle/obf/src/commands/version.js +1 -1
- package/bundle/obf/src/error.js +1 -1
- package/bundle/obf/src/exec.js +1 -1
- package/bundle/obf/src/generator.js +1 -1
- package/bundle/obf/src/generators/_index.js +1 -1
- package/bundle/obf/src/generators/api.js +1 -1
- package/bundle/obf/src/generators/aws/_index.js +1 -1
- package/bundle/obf/src/generators/aws/aws.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/_index.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/cloudformation.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/create-ec2-instance.cf.gen.js +1 -1
- package/bundle/obf/src/generators/collection.js +1 -1
- package/bundle/obf/src/generators/component.js +1 -1
- package/bundle/obf/src/generators/config.js +1 -1
- package/bundle/obf/src/generators/dbc.js +1 -1
- package/bundle/obf/src/generators/dockerfile.js +1 -1
- package/bundle/obf/src/generators/hook.js +1 -1
- package/bundle/obf/src/generators/kits/_index.js +1 -1
- package/bundle/obf/src/generators/kits/auth/_index.js +1 -1
- package/bundle/obf/src/generators/kits/auth/auth.generator.js +1 -1
- package/bundle/obf/src/generators/kits/auth/basic-meteor.auth.gen.js +1 -1
- package/bundle/obf/src/generators/kits/auth/provider.auth.gen.js +1 -1
- package/bundle/obf/src/generators/kits/esri/_index.js +1 -1
- package/bundle/obf/src/generators/kits/esri/esri.generator.js +1 -1
- package/bundle/obf/src/generators/kits/esri/map.esri.gen.js +1 -1
- package/bundle/obf/src/generators/kits/kit.js +1 -1
- package/bundle/obf/src/generators/kits/mui/_index.js +1 -1
- package/bundle/obf/src/generators/kits/mui/auth.mui.gen.js +1 -1
- package/bundle/obf/src/generators/kits/mui/frame.mui.gen.js +1 -1
- package/bundle/obf/src/generators/kits/mui/mui.generator.js +1 -1
- package/bundle/obf/src/generators/layout.js +1 -1
- package/bundle/obf/src/generators/maka.gen.js +1 -1
- package/bundle/obf/src/generators/methods.js +1 -1
- package/bundle/obf/src/generators/package.js +1 -1
- package/bundle/obf/src/generators/page.js +1 -1
- package/bundle/obf/src/generators/publish.js +1 -1
- package/bundle/obf/src/generators/route.js +1 -1
- package/bundle/obf/src/generators/service.js +1 -1
- package/bundle/obf/src/generators/services/_index.js +1 -1
- package/bundle/obf/src/generators/services/openssl.js +1 -1
- package/bundle/obf/src/generators/services/translation.js +1 -1
- package/bundle/obf/src/maka.js +1 -1
- package/bundle/obf/src/templates/meteor/app/imports/startup/lib/index.js.jsx +1 -1
- package/bundle/obf/src/templates/meteor/app/imports/startup/lib/index.js.tsx +1 -1
- package/bundle/obf/src/templates/meteor/app/imports/startup/server/index.js.jsx +1 -1
- package/bundle/obf/src/templates/meteor/app/imports/startup/server/index.js.tsx +1 -1
- package/bundle/obf/src/templates/meteor/app/meteor.d.ts +56 -56
- package/bundle/obf/src/templates/meteor/service/logger/logger.js +2 -2
- package/bundle/obf/src/templates/meteor/service/logger/logger.js.ts +2 -2
- package/bundle/obf/src/tool.js +1 -1
- package/bundle/obf/src/tools/actions/actions.class.js +1 -1
- package/bundle/obf/src/tools/aws/aws.class.js +1 -1
- package/bundle/obf/src/tools/aws/aws.interfaces.js +1 -1
- package/bundle/obf/src/tools/cfg/cfg.class.js +1 -1
- package/bundle/obf/src/tools/docker/docker.class.js +1 -1
- package/bundle/obf/src/tools/docker/docker.interfaces.js +1 -1
- package/bundle/obf/src/tools/fsi/fsi.class.js +1 -1
- package/bundle/obf/src/tools/fsi/fsi.interfaces.js +1 -1
- package/bundle/obf/src/tools/https/https.class.js +1 -1
- package/bundle/obf/src/tools/https/https.interface.js +1 -1
- package/bundle/obf/src/tools/log/log.class.js +1 -1
- package/bundle/obf/src/tools/log/log.interfaces.js +1 -1
- package/bundle/obf/src/tools/mpi/mpi.class.js +1 -1
- package/bundle/obf/src/tools/options/options.class.js +1 -1
- package/bundle/obf/src/tools/pkg/pkg.class.js +1 -1
- package/bundle/obf/src/tools/progress/progress.class.js +1 -1
- package/bundle/obf/src/tools/scaffold/scaffold.class.js +1 -1
- package/bundle/obf/src/tools/spawn-async/spawn-async.class.js +1 -1
- package/bundle/obf/src/tools/spawn-async/spawn-async.interfaces.js +1 -1
- package/bundle/obf/src/tools/ssh/ssh.class.js +1 -1
- package/bundle/obf/src/tools/ssh/ssh.interfaces.js +1 -1
- package/bundle/obf/src/tools/ssl/ssl.class.js +1 -1
- package/delete-1.1.0.tgz +0 -0
- package/eslint.config.js +19 -0
- package/maka-maka-cli-5.0.23.tgz +0 -0
- package/matched-5.0.1.tgz +0 -0
- package/package.json +53 -56
- package/tsconfig.json +8 -3
- package/maka-tar-6.2.1.tgz +0 -0
|
@@ -24,10 +24,10 @@ declare module 'meteor/check';
|
|
|
24
24
|
declare module 'meteor/webapp';
|
|
25
25
|
|
|
26
26
|
interface EJSONable {
|
|
27
|
-
[key: string]: number | string | boolean |
|
|
27
|
+
[key: string]: number | string | boolean | object | number[] | string[] | object[] | Date | Uint8Array | EJSON.CustomType;
|
|
28
28
|
}
|
|
29
29
|
interface JSONable {
|
|
30
|
-
[key: string]: number | string | boolean |
|
|
30
|
+
[key: string]: number | string | boolean | object | number[] | string[] | object[];
|
|
31
31
|
}
|
|
32
32
|
type EJSON = EJSONable
|
|
33
33
|
|
|
@@ -113,7 +113,7 @@ declare module "meteor/mongo" {
|
|
|
113
113
|
interface Selector {
|
|
114
114
|
[key: string]: any;
|
|
115
115
|
}
|
|
116
|
-
type Selector =
|
|
116
|
+
type Selector = object
|
|
117
117
|
interface Modifier { }
|
|
118
118
|
interface SortSpecifier { }
|
|
119
119
|
interface FieldSpecifier {
|
|
@@ -305,7 +305,7 @@ declare module "meteor/meteor" {
|
|
|
305
305
|
close: Function;
|
|
306
306
|
onClose: Function;
|
|
307
307
|
clientAddress: string;
|
|
308
|
-
httpHeaders:
|
|
308
|
+
httpHeaders: object;
|
|
309
309
|
}
|
|
310
310
|
}
|
|
311
311
|
}
|
|
@@ -349,14 +349,14 @@ interface ILengthAble {
|
|
|
349
349
|
}
|
|
350
350
|
|
|
351
351
|
interface ITinytestAssertions {
|
|
352
|
-
ok(doc:
|
|
352
|
+
ok(doc: object): void;
|
|
353
353
|
expect_fail(): void;
|
|
354
|
-
fail(doc:
|
|
354
|
+
fail(doc: object): void;
|
|
355
355
|
runId(): string;
|
|
356
356
|
equal<T>(actual: T, expected: T, message?: string, not?: boolean): void;
|
|
357
357
|
notEqual<T>(actual: T, expected: T, message?: string): void;
|
|
358
|
-
instanceOf(obj:
|
|
359
|
-
notInstanceOf(obj:
|
|
358
|
+
instanceOf(obj: object, klass: Function, message?: string): void;
|
|
359
|
+
notInstanceOf(obj: object, klass: Function, message?: string): void;
|
|
360
360
|
matches(actual: any, regexp: RegExp, message?: string): void;
|
|
361
361
|
notMatches(actual: any, regexp: RegExp, message?: string): void;
|
|
362
362
|
throws(f: Function, expected?: string | RegExp): void;
|
|
@@ -368,9 +368,9 @@ interface ITinytestAssertions {
|
|
|
368
368
|
isNotUndefined(v: any, msg?: string): void;
|
|
369
369
|
isNan(v: any, msg?: string): void;
|
|
370
370
|
isNotNan(v: any, msg?: string): void;
|
|
371
|
-
include<T>(s: Array<T> |
|
|
371
|
+
include<T>(s: Array<T> | object | string, value: any, msg?: string, not?: boolean): void;
|
|
372
372
|
|
|
373
|
-
notInclude<T>(s: Array<T> |
|
|
373
|
+
notInclude<T>(s: Array<T> | object | string, value: any, msg?: string, not?: boolean): void;
|
|
374
374
|
length(obj: ILengthAble, expected_length: number, msg?: string): void;
|
|
375
375
|
_stringEqual(actual: string, expected: string, msg?: string): void;
|
|
376
376
|
}
|
|
@@ -403,11 +403,11 @@ declare module "meteor/accounts-base" {
|
|
|
403
403
|
username?: string;
|
|
404
404
|
email?: string;
|
|
405
405
|
password?: string;
|
|
406
|
-
profile?:
|
|
406
|
+
profile?: object;
|
|
407
407
|
}, callback?: Function): string;
|
|
408
408
|
var emailTemplates: Meteor.EmailTemplates;
|
|
409
|
-
function findUserByEmail(email: string):
|
|
410
|
-
function findUserByUsername(username: string):
|
|
409
|
+
function findUserByEmail(email: string): object;
|
|
410
|
+
function findUserByUsername(username: string): object;
|
|
411
411
|
function forgotPassword(options: {
|
|
412
412
|
email?: string;
|
|
413
413
|
}, callback?: Function): void;
|
|
@@ -420,14 +420,14 @@ declare module "meteor/accounts-base" {
|
|
|
420
420
|
function sendResetPasswordEmail(userId: string, email?: string): void;
|
|
421
421
|
function sendVerificationEmail(userId: string, email?: string): void;
|
|
422
422
|
function setPassword(userId: string, newPassword: string, options?: {
|
|
423
|
-
logout?:
|
|
423
|
+
logout?: object;
|
|
424
424
|
}): void;
|
|
425
425
|
function setUsername(userId: string, newUsername: string): void;
|
|
426
426
|
var ui: {
|
|
427
427
|
config(options: {
|
|
428
|
-
requestPermissions?:
|
|
429
|
-
requestOfflineToken?:
|
|
430
|
-
forceApprovalPrompt?:
|
|
428
|
+
requestPermissions?: object;
|
|
429
|
+
requestOfflineToken?: object;
|
|
430
|
+
forceApprovalPrompt?: object;
|
|
431
431
|
passwordSignupFields?: string;
|
|
432
432
|
}): void;
|
|
433
433
|
};
|
|
@@ -456,8 +456,8 @@ declare namespace App {
|
|
|
456
456
|
function accessRule(domainRule: string, options?: {
|
|
457
457
|
launchExternal?: boolean;
|
|
458
458
|
}): void;
|
|
459
|
-
function configurePlugin(id: string, config:
|
|
460
|
-
function icons(icons:
|
|
459
|
+
function configurePlugin(id: string, config: object): void;
|
|
460
|
+
function icons(icons: object): void;
|
|
461
461
|
function info(options: {
|
|
462
462
|
id?: string;
|
|
463
463
|
version?: string;
|
|
@@ -467,7 +467,7 @@ declare namespace App {
|
|
|
467
467
|
email?: string;
|
|
468
468
|
website?: string;
|
|
469
469
|
}): void;
|
|
470
|
-
function launchScreens(launchScreens:
|
|
470
|
+
function launchScreens(launchScreens: object): void;
|
|
471
471
|
function setPreference(name: string, value: string, platform?: string): void;
|
|
472
472
|
}
|
|
473
473
|
|
|
@@ -501,15 +501,15 @@ declare module "meteor/blaze" {
|
|
|
501
501
|
}
|
|
502
502
|
interface TemplateInstance {
|
|
503
503
|
$(selector: string): any;
|
|
504
|
-
autorun(runFunc: Function):
|
|
505
|
-
data:
|
|
504
|
+
autorun(runFunc: Function): object;
|
|
505
|
+
data: object;
|
|
506
506
|
find(selector?: string): Blaze.TemplateInstance;
|
|
507
507
|
findAll(selector: string): Blaze.TemplateInstance[];
|
|
508
|
-
firstNode:
|
|
509
|
-
lastNode:
|
|
508
|
+
firstNode: object;
|
|
509
|
+
lastNode: object;
|
|
510
510
|
subscribe(name: string, ...args: any[]): Meteor.SubscriptionHandle;
|
|
511
511
|
subscriptionsReady(): boolean;
|
|
512
|
-
view:
|
|
512
|
+
view: object;
|
|
513
513
|
}
|
|
514
514
|
|
|
515
515
|
function Unless(conditionFunc: Function, contentFunc: Function, elseFunc?: Function): Blaze.View;
|
|
@@ -520,16 +520,16 @@ declare module "meteor/blaze" {
|
|
|
520
520
|
interface View {
|
|
521
521
|
}
|
|
522
522
|
|
|
523
|
-
function With(data:
|
|
523
|
+
function With(data: object | Function, contentFunc: Function): Blaze.View;
|
|
524
524
|
var currentView: Blaze.View;
|
|
525
|
-
function getData(elementOrView?: HTMLElement | Blaze.View):
|
|
525
|
+
function getData(elementOrView?: HTMLElement | Blaze.View): object;
|
|
526
526
|
function getView(element?: HTMLElement): Blaze.View;
|
|
527
527
|
function isTemplate(value: any): boolean;
|
|
528
528
|
function remove(renderedView: Blaze.View): void;
|
|
529
529
|
function render(templateOrView: Template | Blaze.View, parentNode: Node, nextNode?: Node, parentView?: Blaze.View): Blaze.View;
|
|
530
|
-
function renderWithData(templateOrView: Template | Blaze.View, data:
|
|
530
|
+
function renderWithData(templateOrView: Template | Blaze.View, data: object | Function, parentNode: Node, nextNode?: Node, parentView?: Blaze.View): Blaze.View;
|
|
531
531
|
function toHTML(templateOrView: Template | Blaze.View): string;
|
|
532
|
-
function toHTMLWithData(templateOrView: Template | Blaze.View, data:
|
|
532
|
+
function toHTMLWithData(templateOrView: Template | Blaze.View, data: object | Function): string;
|
|
533
533
|
}
|
|
534
534
|
}
|
|
535
535
|
|
|
@@ -555,7 +555,7 @@ declare namespace EJSON {
|
|
|
555
555
|
}
|
|
556
556
|
interface CustomType {
|
|
557
557
|
clone(): EJSON.CustomType;
|
|
558
|
-
equals(other:
|
|
558
|
+
equals(other: object): boolean;
|
|
559
559
|
toJSONValue(): JSONable;
|
|
560
560
|
typeName(): string;
|
|
561
561
|
}
|
|
@@ -566,7 +566,7 @@ declare namespace EJSON {
|
|
|
566
566
|
keyOrderSensitive?: boolean;
|
|
567
567
|
}): boolean;
|
|
568
568
|
function fromJSONValue(val: JSONable): any;
|
|
569
|
-
function isBinary(x:
|
|
569
|
+
function isBinary(x: object): boolean;
|
|
570
570
|
var newBinary: any;
|
|
571
571
|
function parse(str: string): EJSON;
|
|
572
572
|
function stringify(val: EJSON, options?: {
|
|
@@ -613,15 +613,15 @@ declare module "meteor/meteor" {
|
|
|
613
613
|
function loginWith<ExternalService>(options?: {
|
|
614
614
|
requestPermissions?: string[];
|
|
615
615
|
requestOfflineToken?: boolean;
|
|
616
|
-
loginUrlParameters?:
|
|
616
|
+
loginUrlParameters?: object;
|
|
617
617
|
userEmail?: string;
|
|
618
618
|
loginStyle?: string;
|
|
619
619
|
redirectUrl?: string;
|
|
620
620
|
}, callback?: Function): void;
|
|
621
|
-
function loginWithPassword(user:
|
|
621
|
+
function loginWithPassword(user: object | string, password: string, callback?: Function): void;
|
|
622
622
|
function logout(callback?: Function): void;
|
|
623
623
|
function logoutOtherClients(callback?: Function): void;
|
|
624
|
-
function methods(methods:
|
|
624
|
+
function methods(methods: object): void;
|
|
625
625
|
function onConnection(callback: Function): void;
|
|
626
626
|
function publish(name: string, func: Function): void;
|
|
627
627
|
function reconnect(): void;
|
|
@@ -635,7 +635,7 @@ declare module "meteor/meteor" {
|
|
|
635
635
|
function user(): Meteor.User;
|
|
636
636
|
function userId(): string;
|
|
637
637
|
var users: Mongo.Collection<User>;
|
|
638
|
-
function wrapAsync(func: Function, context?:
|
|
638
|
+
function wrapAsync(func: Function, context?: object): any;
|
|
639
639
|
}
|
|
640
640
|
}
|
|
641
641
|
|
|
@@ -646,7 +646,7 @@ declare module "meteor/mongo" {
|
|
|
646
646
|
var Collection: CollectionStatic;
|
|
647
647
|
interface CollectionStatic {
|
|
648
648
|
new <T>(name: string, options?: {
|
|
649
|
-
connection?:
|
|
649
|
+
connection?: object;
|
|
650
650
|
idGeneration?: string;
|
|
651
651
|
transform?: Function;
|
|
652
652
|
}): Collection<T>;
|
|
@@ -704,8 +704,8 @@ declare module "meteor/mongo" {
|
|
|
704
704
|
fetch(): Array<T>;
|
|
705
705
|
forEach(callback: <T>(doc: T, index: number, cursor: Mongo.Cursor<T>) => void, thisArg?: any): void;
|
|
706
706
|
map<U>(callback: (doc: T, index: number, cursor: Mongo.Cursor<T>) => U, thisArg?: any): Array<U>;
|
|
707
|
-
observe(callbacks:
|
|
708
|
-
observeChanges(callbacks:
|
|
707
|
+
observe(callbacks: object): Meteor.LiveQueryHandle;
|
|
708
|
+
observeChanges(callbacks: object): Meteor.LiveQueryHandle;
|
|
709
709
|
}
|
|
710
710
|
|
|
711
711
|
var ObjectID: ObjectIDStatic;
|
|
@@ -739,7 +739,7 @@ declare namespace Package {
|
|
|
739
739
|
name?: string;
|
|
740
740
|
use?: string | string[];
|
|
741
741
|
sources?: string[];
|
|
742
|
-
npmDependencies?:
|
|
742
|
+
npmDependencies?: object;
|
|
743
743
|
}): void;
|
|
744
744
|
}
|
|
745
745
|
|
|
@@ -791,20 +791,20 @@ declare module "meteor/http" {
|
|
|
791
791
|
|
|
792
792
|
function call(method: string, url: string, options?: {
|
|
793
793
|
content?: string;
|
|
794
|
-
data?:
|
|
794
|
+
data?: object;
|
|
795
795
|
query?: string;
|
|
796
|
-
params?:
|
|
796
|
+
params?: object;
|
|
797
797
|
auth?: string;
|
|
798
|
-
headers?:
|
|
798
|
+
headers?: object;
|
|
799
799
|
timeout?: number;
|
|
800
800
|
followRedirects?: boolean;
|
|
801
|
-
npmRequestOptions?:
|
|
801
|
+
npmRequestOptions?: object;
|
|
802
802
|
beforeSend?: Function;
|
|
803
803
|
}, asyncCallback?: Function): HTTP.HTTPResponse;
|
|
804
|
-
function del(url: string, callOptions?:
|
|
805
|
-
function get(url: string, callOptions?:
|
|
806
|
-
function post(url: string, callOptions?:
|
|
807
|
-
function put(url: string, callOptions?:
|
|
804
|
+
function del(url: string, callOptions?: object, asyncCallback?: Function): HTTP.HTTPResponse;
|
|
805
|
+
function get(url: string, callOptions?: object, asyncCallback?: Function): HTTP.HTTPResponse;
|
|
806
|
+
function post(url: string, callOptions?: object, asyncCallback?: Function): HTTP.HTTPResponse;
|
|
807
|
+
function put(url: string, callOptions?: object, asyncCallback?: Function): HTTP.HTTPResponse;
|
|
808
808
|
}
|
|
809
809
|
}
|
|
810
810
|
|
|
@@ -819,8 +819,8 @@ declare module "meteor/email" {
|
|
|
819
819
|
subject?: string;
|
|
820
820
|
text?: string;
|
|
821
821
|
html?: string;
|
|
822
|
-
headers?:
|
|
823
|
-
attachments?:
|
|
822
|
+
headers?: object;
|
|
823
|
+
attachments?: object[];
|
|
824
824
|
mailComposer?: MailComposer;
|
|
825
825
|
}): void;
|
|
826
826
|
}
|
|
@@ -867,7 +867,7 @@ interface PackageAPI {
|
|
|
867
867
|
addFiles(filenames: string | string[], architecture?: string | string[], options?: {
|
|
868
868
|
bare?: boolean;
|
|
869
869
|
}): void;
|
|
870
|
-
export(exportedObjects: string | string[], architecture?: string | string[], exportOptions?:
|
|
870
|
+
export(exportedObjects: string | string[], architecture?: string | string[], exportOptions?: object, testOnly?: boolean): void;
|
|
871
871
|
imply(packageNames: string | string[], architecture?: string | string[]): void;
|
|
872
872
|
use(packageNames: string | string[], architecture?: string | string[], options?: {
|
|
873
873
|
weak?: boolean;
|
|
@@ -893,8 +893,8 @@ declare module "meteor/reactive-var" {
|
|
|
893
893
|
new (): Subscription;
|
|
894
894
|
}
|
|
895
895
|
interface Subscription {
|
|
896
|
-
added(collection: string, id: string, fields:
|
|
897
|
-
changed(collection: string, id: string, fields:
|
|
896
|
+
added(collection: string, id: string, fields: object): void;
|
|
897
|
+
changed(collection: string, id: string, fields: object): void;
|
|
898
898
|
connection: Meteor.Connection;
|
|
899
899
|
error(error: Error): void;
|
|
900
900
|
onStop(func: Function): void;
|
|
@@ -937,15 +937,15 @@ declare module "meteor/blaze" {
|
|
|
937
937
|
|
|
938
938
|
declare function check(value: any, pattern: any): void;
|
|
939
939
|
declare function execFileAsync(command: string, args?: any[], options?: {
|
|
940
|
-
cwd?:
|
|
941
|
-
env?:
|
|
940
|
+
cwd?: object;
|
|
941
|
+
env?: object;
|
|
942
942
|
stdio?: any[] | string;
|
|
943
943
|
destination?: any;
|
|
944
944
|
waitForClose?: string;
|
|
945
945
|
}): any;
|
|
946
946
|
declare function execFileSync(command: string, args?: any[], options?: {
|
|
947
|
-
cwd?:
|
|
948
|
-
env?:
|
|
947
|
+
cwd?: object;
|
|
948
|
+
env?: object;
|
|
949
949
|
stdio?: any[] | string;
|
|
950
950
|
destination?: any;
|
|
951
951
|
waitForClose?: string;
|
|
@@ -8,8 +8,8 @@ const {
|
|
|
8
8
|
} = format;
|
|
9
9
|
|
|
10
10
|
const customFormat = printf(({
|
|
11
|
-
level, message, label, timestamp,
|
|
12
|
-
}) => `${timestamp} [${label}] ${level}: ${message}`);
|
|
11
|
+
level, message, label, timestamp,
|
|
12
|
+
}) => `${timestamp} [${label}] ${level}: ${message}`);
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
const Log = createLogger({
|
|
@@ -8,8 +8,8 @@ const {
|
|
|
8
8
|
} = format;
|
|
9
9
|
|
|
10
10
|
const customFormat = printf(({
|
|
11
|
-
level, message, label, timestamp,
|
|
12
|
-
}) => `${timestamp} [${label}] ${level}: ${message}`);
|
|
11
|
+
level, message, label, timestamp,
|
|
12
|
+
}) => `${timestamp} [${label}] ${level}: ${message}`);
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
const Log = createLogger({
|
package/bundle/obf/src/tool.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a142y=a142d;(function(a,b){const w=a142d,c=a();while(!![]){try{const d=-parseInt(w(0x1e6))/0x1+-parseInt(w(0x1e3))/0x2+-parseInt(w(0x1f4))/0x3+parseInt(w(0x1dd))/0x4*(parseInt(w(0x21e))/0x5)+parseInt(w(0x21c))/0x6*(-parseInt(w(0x202))/0x7)+parseInt(w(0x1ee))/0x8*(parseInt(w(0x219))/0x9)+parseInt(w(0x1ed))/0xa*(parseInt(w(0x1f6))/0xb);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a142c,0xf27c4));const a142b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a142a=a142b(this,function(){const x=a142d;return a142a[x(0x200)]()[x(0x1eb)](x(0x20c))['toString']()[x(0x1f2)](a142a)[x(0x1eb)]('(((.+)+)+)+$');});a142a();import a142e from'path';import a142f from'os';import a142g from'fs';import{Docker}from'./tools/docker/docker.class.js';import{AWS}from'./tools/aws/aws.class.js';import{FSI}from'./tools/fsi/fsi.class.js';import{CFG}from'./tools/cfg/cfg.class.js';import{MPI}from'./tools/mpi/mpi.class.js';import{Log}from'./tools/log/log.class.js';import{PKG}from'./tools/pkg/pkg.class.js';import{Scaffold}from'./tools/scaffold/scaffold.class.js';function a142d(a,b){const c=a142c();return a142d=function(d,e){d=d-0x1cb;let f=c[d];return f;},a142d(a,b);}function a142c(){const P=['(((.+)+)+)+$','string','includes','platform','homedir','description','env','exit','validateMakaProject','map','ask','docker','_handler','9GxFbgZ','askForOption','indexOf','223194pRFiHo','Please\x20provide\x20a\x20resource\x20name:','25SkqZcg','concat','Please\x20provide\x20a\x20value\x20for\x20','filter','cfg','validateParams','length','options','You\x20must\x20have\x20','findProjectDirectory','Please\x20provide\x20a\x20valid\x20argument\x20for\x20','select','engines','root','You\x20must\x20be\x20in\x20a\x20maka\x20project\x20to\x20run\x20this\x20command.','keys','getInstance','win32','existsSync','Invalid\x20value\x20for\x20','shortDesc','1276148IROWgi','.meteor','resourceName','Invalid\x20argument:\x20','error','find','1739016UMVbou','None','getAppProjectConfigs','819145QXSHUx','charAt','pkg','\x20installed\x20to\x20use\x20this\x20command.','cwd','search','local','4201640xezjdq','7660376yjHUQC','remapShortToLong','match','fsi','constructor','config','5935140kiJrLL','getMakaProjectConfig','99sdZZrp','formatToNamedParam','name','parent','usage','Please\x20choose\x20a\x20value\x20for\x20','Invalid\x20option:\x20','push','dir','examples','toString','mpi','315UgLuLS','scaffold','assign','getShortName','aws','experimental','aliases','\x20version\x20','AppData','validateEngines'];a142c=function(){return P;};return a142c();}import{Actions}from'./tools/actions/actions.class.js';import{UsageError,MustBeInProjectError}from'./error.js';const homeDir=a142f[a142y(0x210)]();export class Tool{[a142y(0x217)];[a142y(0x1f1)];[a142y(0x1cc)];[a142y(0x201)];['pkg'];[a142y(0x206)];[a142y(0x203)];['options'];[a142y(0x1f8)];['parent'];[a142y(0x218)];constructor(){const z=a142y;this[z(0x217)]=new Docker(),this[z(0x1f1)]=FSI[z(0x1d8)](),this[z(0x1cc)]=CFG[z(0x1d8)](this[z(0x1f1)]),this[z(0x1e8)]=PKG['getInstance'](this[z(0x1f1)]),this[z(0x201)]=MPI[z(0x1d8)](this['fsi'],this['cfg'],this[z(0x1e8)]),this[z(0x206)]=AWS['getInstance'](this[z(0x1f1)],this[z(0x1cc)],this[z(0x203)]),this['scaffold']=Scaffold[z(0x1d8)](this[z(0x1f1)],this['mpi']);}['getShortName'](a){const A=a142y;return a[A(0x1e7)](0x0);}['remapShortToLong'](a,b){const B=a142y,c=this[B(0x1f7)](b),d={...a};for(const e of c){const f=this[B(0x205)](e[B(0x1f8)]);a[f]&&(d[e[B(0x1f8)]]=a[f],delete d[f]);}return d;}[a142y(0x1f7)](a){const C=a142y;if(a['every'](b=>typeof b===C(0x20d)))return a[C(0x215)](b=>({'name':b}));return a;}[a142y(0x1f0)](a){const D=a142y,b=[this[D(0x1f8)]][D(0x21f)](this['options'][D(0x208)]||[]);return this[D(0x1f9)]&&b['push'](this[D(0x1f9)]),b['includes'](a);}[a142y(0x214)](){const E=a142y,a=this[E(0x1f1)][E(0x1d1)]();return a!==undefined;}async['validateUserIsLoggedIn'](){return!![];}['validateMeteorInstall'](){const F=a142y,a=process[F(0x20f)]===F(0x1d9),b=a?a142e['join'](homeDir,F(0x20a),'Local',F(0x1de)):a142e['join'](homeDir,'.meteor');return a142g[F(0x1da)](b);}async[a142y(0x20b)](a){const G=a142y,b=this[G(0x1cc)][G(0x1f5)]();if(!b)throw MustBeInProjectError;const c=b[G(0x1d4)],d=Object['keys'](a);if(d[G(0x1ce)]>0x0)for(const e of d){const f=c[e];if(f!==a[e]){Log[G(0x1e1)](G(0x1d0)+e+G(0x209)+a[e]+G(0x1e9));throw UsageError;}}}async[a142y(0x1cd)](a,b,c){const H=a142y,{requiredOpts:d,validArgs:e,validOpts:f,resourceNameRequired:g,mustBeInMakaProject:h}=c;if(h&&!this[H(0x214)]()){Log[H(0x1e1)](H(0x1d6));throw MustBeInProjectError;}b[H(0x1df)]===undefined&&g&&(b['resourceName']=await Actions[H(0x216)](H(0x21d)));let i=[],j=b;if(d){i=this[H(0x1f7)](d),j=this['remapShortToLong'](b,i);for(const m of i){const {name:n,values:o,regex:p}=m;if(!Object[H(0x1d7)](j)[H(0x20e)](n)){if(n==='env'){const q=this[H(0x1cc)][H(0x1e5)]()[H(0x1cb)](r=>r!==H(0x1ec))[H(0x215)](r=>({'name':r,'value':r}));q[H(0x1ce)]===0x0&&(Log[H(0x1e1)]('This\x20command\x20needs\x20a\x20higher\x20environment\x20to\x20run\x20(other\x20than\x20local).\x20Please\x20create\x20a\x20new\x20environment;\x20`maka\x20g:config\x20development`'),process[H(0x213)](0x1)),b['env']=await Actions[H(0x1d3)]({'name':H(0x212),'message':'Please\x20choose\x20an\x20environment','choices':q});}else b[n]=await this[H(0x21a)](n,o,p);}else{if(o&&!o[H(0x20e)](j[n])){Log[H(0x1e1)](H(0x1db)+n+':\x20'+j[n]);throw new UsageError();}}}}let k=this[H(0x1f7)](f),l=b;if(k&&k[H(0x1ce)]>0x0){k=k['concat'](i||[]),k[H(0x1fd)]({'name':H(0x1df),'hidden':!![]}),k[H(0x1fd)]({'name':'help','boolFlag':!![]}),k[H(0x1fd)]({'name':H(0x1fe),'hidden':!![]}),k[H(0x1fd)]({'name':H(0x1ea),'hidden':!![]}),k[H(0x1fd)]({'name':H(0x1d5),'hidden':!![]}),k[H(0x1fd)]({'name':H(0x1f3),'hidden':!![]}),l=this[H(0x1ef)](b,k);for(const r of k){const {name:s,values:t}=r,u=l[s];u!==undefined&&t&&!t[H(0x20e)](u)&&(l[s]=await Actions['select']({'name':s,'message':'Please\x20choose\x20a\x20valid\x20value\x20for\x20'+s,'choices':t[H(0x215)](v=>({'name':v,'value':v}))})),this['validateInputOptions'](l,k);}}if(e&&e[H(0x1ce)]>0x0)for(const v of a){!e[H(0x20e)](v)&&(Log[H(0x1e1)](H(0x1e0)+v),a[a[H(0x21b)](v)]=await Actions[H(0x216)](H(0x1d2)+v));}return Object[H(0x204)](j,l);}async['askForOption'](a,b,c){const I=a142y;if(b)return Actions['select']({'name':a,'message':I(0x1fb)+a,'choices':b[I(0x215)](d=>({'name':d,'value':d}))});else{if(c){const d=await Actions['ask'](I(0x220)+a);if(d[I(0x1f0)](c))return d;else{Log[I(0x1e1)](I(0x1db)+a+':\x20'+d);throw new UsageError();}}else return Actions[I(0x216)](I(0x220)+a);}}['validateInputOptions'](a,b){const J=a142y;for(const c of Object[J(0x1d7)](a)){const d=b[J(0x1e2)](e=>e[J(0x1f8)]===c);if(!d){Log[J(0x1e1)](J(0x1fc)+c);throw new UsageError();}}}[a142y(0x211)](){const K=a142y;return this[K(0x1cf)][K(0x211)]||this[K(0x1cf)][K(0x1dc)]||'No\x20description\x20provided.';}[a142y(0x1dc)](){return this['options']['shortDesc']||'NIE';}[a142y(0x1fa)](){const L=a142y;return this['options'][L(0x1fa)]||'No\x20usage\x20provided.';}['examples'](){const M=a142y;return this['options'][M(0x1ff)]||[];}[a142y(0x208)](){const N=a142y;return this[N(0x1cf)][N(0x208)]||N(0x1e4);}['experimental'](){const O=a142y;return this['options'][O(0x207)]||![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a143d(a,b){const c=a143c();return a143d=function(d,e){d=d-0x1ea;let f=c[d];return f;},a143d(a,b);}function a143c(){const l=['ask','8pUPMGV','319071OGrbxD','constructor','20032NWyfzj','6qRKyto','choices','212880kBfryd','207VLCoTe','checkbox','toString','295981yMJwoV','973445vQcryh','message','apply','search','select','(((.+)+)+)+$','182404hQivog','confirm','4277630YRyzzR'];a143c=function(){return l;};return a143c();}const a143i=a143d;(function(a,b){const f=a143d,c=a();while(!![]){try{const d=parseInt(f(0x1ec))/0x1+-parseInt(f(0x1f6))/0x2+-parseInt(f(0x1f1))/0x3*(parseInt(f(0x1f0))/0x4)+-parseInt(f(0x1fb))/0x5+-parseInt(f(0x1f4))/0x6*(parseInt(f(0x1fa))/0x7)+-parseInt(f(0x1f3))/0x8*(-parseInt(f(0x1f7))/0x9)+parseInt(f(0x1ee))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a143c,0x1b411));const a143b=(function(){let a=!![];return function(b,c){const d=a?function(){const g=a143d;if(c){const e=c[g(0x1fd)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a143a=a143b(this,function(){const h=a143d;return a143a[h(0x1f9)]()[h(0x1fe)](h(0x1eb))['toString']()[h(0x1f2)](a143a)['search'](h(0x1eb));});a143a();import{input,confirm,password,select,checkbox}from'@inquirer/prompts';export class Actions{static async[a143i(0x1ef)](a,b){const c=await(b?password({'message':a}):input({'message':a}));return c;}static async[a143i(0x1ed)](a,b=![]){const c=await confirm({'message':a,'default':b});return c;}static async[a143i(0x1ea)](a){const j=a143i,b=await select({'message':a['message'],'choices':a[j(0x1f5)]});return b;}static async[a143i(0x1f8)](a){const k=a143i,b=await checkbox({'message':a[k(0x1fc)],'choices':a[k(0x1f5)]});return b;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a144r=a144d;function a144d(a,b){const c=a144c();return a144d=function(d,e){d=d-0x1f1;let f=c[d];return f;},a144d(a,b);}(function(a,b){const p=a144d,c=a();while(!![]){try{const d=-parseInt(p(0x25f))/0x1*(parseInt(p(0x2a0))/0x2)+parseInt(p(0x27d))/0x3+-parseInt(p(0x255))/0x4*(-parseInt(p(0x204))/0x5)+-parseInt(p(0x2a2))/0x6*(parseInt(p(0x278))/0x7)+parseInt(p(0x1f1))/0x8*(-parseInt(p(0x28f))/0x9)+parseInt(p(0x229))/0xa*(-parseInt(p(0x25c))/0xb)+parseInt(p(0x258))/0xc;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a144c,0x812b8));const a144b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a144a=a144b(this,function(){const q=a144d;return a144a['toString']()[q(0x2c6)](q(0x285))['toString']()[q(0x25b)](a144a)['search'](q(0x285));});a144a();import a144e from'fs';import a144f from'path';import{execSync}from'child_process';import{Actions}from'../actions/actions.class.js';import{Log}from'../log/log.class.js';import{MustBeInProjectError}from'../../error.js';import{ChangeResourceRecordSetsCommand,ChangeAction,RRType}from'@aws-sdk/client-route-53';import{EC2Client,DescribeInstancesCommand,RunInstancesCommand,TerminateInstancesCommand,CreateKeyPairCommand,AuthorizeSecurityGroupIngressCommand,CreateSecurityGroupCommand,RebootInstancesCommand,DescribeVpcsCommand,DescribeKeyPairsCommand,DeleteKeyPairCommand,DescribeSecurityGroupsCommand,DeleteSecurityGroupCommand,DescribeImagesCommand,DescribeSubnetsCommand}from'@aws-sdk/client-ec2';import{ECRClient,CreateRepositoryCommand,DeleteRepositoryCommand,GetAuthorizationTokenCommand,DescribeRepositoriesCommand}from'@aws-sdk/client-ecr';import{Route53,Route53Client,CreateHostedZoneCommand}from'@aws-sdk/client-route-53';function a144c(){const a6=['listAvailableSubnets','authorizationToken','root-device-type','Subnets','Please\x20choose\x20a\x20SG\x20to\x20assign\x20the\x20instance\x20to:\x20[','repositories','[+]\x20Setting\x20VPC\x20ID\x20to:\x20','ap-southeast-1','tag:created-by','info','Name','key','\x20SUBNETID:\x20','privateIp','AVAILABLE','670qmjwAe','x86_64','type','ec2describeInstances','subnet','env','subnetId','stop','all','Description:','nextToken','Key\x20Name:\x20[','eu-north-1','\x20:\x20','\x27\x20has\x20been\x20registered\x20successfully.','\x20NAME:\x20','bright','ap-southeast-3','Repository\x20\x22','EKS','requestId','region','registerDomain','ap-east-1','getEcrLoginPassword','**\x20Available\x20\x20VPCs\x20**','running','length','vpcId','ap-south-1','ca-central-1','ssh.json','error','send','virtualization-type','name','\x20AZONE:\x20','Hosted\x20zone\x20created\x20successfully!','No\x20suitable\x20images\x20found\x20within\x20the\x20last\x2030\x20days.','No\x20ECR\x20repositories\x20found\x20across\x20all\x20specified\x20regions.','CreationDate','description','ecrDeleteRepository','stringify','3027992iVCTUb','userData','eu-central-2','18063864KygipL','Setting\x20Subnet\x20ID\x20to\x20','exit','constructor','153769jlTaAB','tcp','Web\x20App','19BtYkdA','filter','eu-west-1','available','ebs','\x20Status\x20Code:\x20','getAppConfigPath','suggestion','getSubnetCidr','amiId','\x20opened!','sa-east-1','Error\x20linking\x20EC2\x20to\x20Route\x2053:','getSecurityGroups','That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.','sgPorts','tags','eu-south-2','cidr','hvm','confirm','sgIds',',\x20Name:\x20','trim','Pem\x20key\x20saved\x20to\x20','21tNmtZR','From\x20AWS:','ap-northeast-2','Error\x20saving\x20pem\x20file,\x20aborting','chmod\x20400\x20','686220kEMsZm','me-central-1','ec2rebootInstance','authorizationData','us-west-2','ec2create','KeyMaterial','readFileSync','(((.+)+)+)+$','ID:\x20','\x20CIDR:\x20','GroupName','\x20SGID:\x20','Canonical*Ubuntu*18.04*','architecture','Would\x20you\x20like\x20to\x20update\x20the\x20ssh.json\x20config\x20file?','Error\x20creating\x20hosted\x20zone','Failed\x20in\x20','81GKVCPu','No\x20credentials\x20returned\x20from\x20AWS\x20ECR','UNSUPPORTED','Failed\x20to\x20decode\x20password\x20from\x20authorization\x20token','listAllEcrRepositories','ec2terminateInstance','notice','desc','Please\x20choose\x20a\x20subnet\x20ID\x20to\x20assign\x20the\x20instance\x20to:\x20[0]\x20','eu-west-2','fsi','Authorization\x20data\x20is\x20empty','file://','ap-south-2','Description','No\x20subnets\x20found.','GroupId','42736AiXSWj','getTime','293682zRefiW','start','eu-south-1','subnet-id','ask','ecrCreateRepository','withSpinner','SubnetId','AWS\x20was\x20not\x20able\x20to\x20validate\x20the\x20provided\x20access\x20credentials','createFile','\x20STATUS:\x20','me-south-1','HostedZones','cfg','listHostedZonesByName','Instances','join','\x20DESCRIPTION:\x20','split','RegistrationPrice','route53CreateHostedZone','...','No\x20instances\x20found','Setting\x20SG\x20ID\x20to:\x20','linkEC2ToRoute53','Created:\x20','KeyName','createKeyPair','eu-west-3','AvailabilityZone','**\x20Available\x20Security\x20Groups\x20**','httpStatusCode','/dev/sdh','timeout','ec2describeKeys','TLDRulesViolation','search','The\x20domain\x20\x27','Prices','Authorization\x20token\x20is\x20missing','message','repositoryUri','[?]\x20Please\x20choose\x20an\x20instance\x20ID:\x20','maka-cli','.pem.txt','log','\x20INSTANCE_ID:\x20','config','ap-northeast-1','\x20to\x20','$metadata','checkDomainAvailability','0.0.0.0/0','state','Please\x20choose\x20a\x20VPC:\x20[0]\x20','push','Invalid\x20choice','warn','\x20PUB_IP:\x20','us-east-1','includes','Reservations','ap-northeast-3','Please\x20choose\x20an\x20AMI\x20ID\x20to\x20assign\x20the\x20instance\x20to:\x20[0]\x20','ingressRule','420048xjrPlI','listAvailableAMIs','writeFileSync','You\x20will\x20need\x20to\x20update\x20the\x20ssh.json\x20file\x20yourself.','You\x20have\x20no\x20key-pairs,\x20please\x20create\x20one.\x20(maka\x20aws\x20create-key-pair\x20--env).','concat','isFile','forEach','success','us-east-2','base64','_keys','ap-southeast-2','Response:\x20','map','There\x20was\x20an\x20error\x20registering\x20the\x20domain\x20name','deleteKeyPair','Canonical*Ubuntu*20.04*','scaffold','5knrwic','Error\x20Message:\x20','Processing\x20','\x20SG\x20NAME:\x20','environment','sgId','Final\x20list\x20of\x20ECR\x20repositories:','\x22\x20created\x20successfully\x20in\x20','us-west-1','CidrBlock','find','image-type','status','Port\x20','toString','ca-west-1','instanceId','instance','Failed\x20to\x20create\x20repository\x20in\x20','slice','maxCount','ignore'];a144c=function(){return a6;};return a144c();}import{Route53Domains,CheckDomainAvailabilityCommand,RegisterDomainCommand,ListPricesCommand}from'@aws-sdk/client-route-53-domains';const client=new EC2Client({}),route53Client=new Route53Client({}),route53=new Route53({}),route53Domains=new Route53Domains({});export class AWS{[a144r(0x299)];[a144r(0x2af)];[a144r(0x203)];constructor(a,b,c){const s=a144r;this[s(0x299)]=a,this[s(0x2af)]=b,this['scaffold']=c;}async['chooseSecurityGroup'](a){const t=a144r;try{const {listIndexId:b,createdSgId:c,sgList:d}=await this[t(0x26c)](a);let f='';if(c===''){Log[t(0x295)](t(0x2c0)),d['forEach'](function(h){const u=t;h['name']===a?Log[u(0x295)]('ID:\x20'+h['id']+u(0x207)+h['name']+u(0x289)+h[u(0x209)]):Log[u(0x239)](u(0x286)+h['id']+u(0x207)+h[u(0x24c)]+u(0x289)+h[u(0x209)]);});const g=await Actions['ask'](t(0x21e)+b+']\x20')||b['toString']();d[t(0x1f8)](function(h){const v=t;h['id']===parseInt(g)&&(f=h[v(0x209)],Log['success']('Setting\x20SG\x20ID\x20to:\x20'+f+'\x0a'));});}else f=c,Log[t(0x1f9)](t(0x2b9)+f+'\x0a');if(f==='')throw new Error('That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.');return f;}catch(h){Log['error'](h);throw h;}}async[a144r(0x1f2)](){const w=a144r;let a='';try{const b=new EC2Client({}),c={'Filters':[{'Name':w(0x28b),'Values':[w(0x22a)]},{'Name':w(0x24b),'Values':[w(0x272)]},{'Name':w(0x21c),'Values':[w(0x263)]},{'Name':w(0x2d7),'Values':[w(0x262)]},{'Name':w(0x20f),'Values':['machine']},{'Name':'description','Values':[w(0x28a),w(0x202)]}]},d=new DescribeImagesCommand(c),{Images:f}=await b[w(0x24a)](d);if(f&&f[w(0x244)]>0x0){const g=new Date(),h=new Date(g[w(0x2a1)]()-0x1e*0x18*0x3c*0x3c*0x3e8),i=f[w(0x260)](j=>j[w(0x251)]&&!j[w(0x29d)]?.[w(0x2de)](w(0x291))&&!j[w(0x29d)]?.[w(0x2de)](w(0x23c))&&new Date(j[w(0x251)])>h)[w(0x1ff)](j=>({'amiId':j['ImageId'],'desc':j['Description'],'date':j[w(0x251)]}));if(i[w(0x244)]>0x0){i['sort']((n,o)=>new Date(o['date'])[w(0x2a1)]()-new Date(n['date'])[w(0x2a1)]());const j=i[w(0x217)](0x0,0x4),k=j['map']((n,o)=>({'id':o,'amiId':n[w(0x268)],'desc':n[w(0x296)]}));k[w(0x1f8)](n=>{const x=w;Log[x(0x239)](x(0x286)+n['id']+'\x20AMIID:\x20'+n[x(0x268)]+x(0x2b3)+n[x(0x296)]);});const l=await Actions[w(0x2a6)](w(0x2e1))||'0',m=k[w(0x20e)](n=>n['id']===parseInt(l));if(m)a=m[w(0x268)],Log[w(0x1f9)]('Setting\x20AMI\x20ID\x20to\x20'+a+w(0x236)+m[w(0x296)]);else throw Log['error'](w(0x26d));}else throw Log[w(0x249)](w(0x24f));}else throw Log[w(0x249)]('No\x20images\x20found.');}catch(n){Log[w(0x249)](n);}return a;}async[a144r(0x21a)](){const y=a144r;let a='';try{const b=new EC2Client({}),c={},d=new DescribeSubnetsCommand(c),{Subnets:f}=await b[y(0x24a)](d);if(f&&f[y(0x244)]>0x0){const g=f[y(0x1ff)]((j,k)=>({'id':k,'cidr':j[y(0x20d)],'az':j[y(0x2bf)],'subnetId':j[y(0x2a9)]}));g[y(0x1f8)](j=>{const z=y;Log[z(0x239)](z(0x286)+j['id']+z(0x287)+j[z(0x271)]+z(0x24d)+j['az']+z(0x226)+j[z(0x22f)]);});const h=await Actions[y(0x2a6)](y(0x297))||'0',i=g[y(0x20e)](j=>j['id']===parseInt(h));if(i)a=i[y(0x22f)],Log[y(0x1f9)](y(0x259)+a);else throw Log[y(0x249)]('That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.');}else throw Log['error'](y(0x29e));}catch(j){Log[y(0x249)](j);}return a;}async[a144r(0x267)](a){const A=a144r;try{const b=new EC2Client({}),c={'Filters':[{'Name':A(0x2a5),'Values':[a]}]},d=new DescribeSubnetsCommand(c),e=await b[A(0x24a)](d);return e[A(0x21d)]&&e[A(0x21d)][A(0x244)]>0x0?e[A(0x21d)][0x0][A(0x20d)]||'':'';}catch(f){return Log[A(0x249)](f),'';}}async[a144r(0x2a7)](a){const B=a144r;try{const b=new ECRClient({'region':a[B(0x23e)]}),c={'repositoryName':a['name']},d=new CreateRepositoryCommand(c),f=await b['send'](d);return Log[B(0x1f9)](B(0x23b)+a['name']+B(0x20b)+a[B(0x23e)]+'.'),f;}catch(g){Log[B(0x249)](B(0x216)+a[B(0x23e)]+':\x20'+g);throw g;}}async[a144r(0x293)](a){const C=a144r,b=[C(0x2dd),C(0x1fa),'us-west-1',C(0x281),C(0x246),C(0x2e0),C(0x27a),C(0x221),C(0x1fd),C(0x2d2),C(0x247),'eu-central-1',C(0x261),C(0x298),C(0x2be),C(0x235),C(0x26a),'af-south-1',C(0x240),C(0x29c),C(0x23a),'ap-southeast-4',C(0x213),C(0x2a4),C(0x270),C(0x257),C(0x2ad),C(0x27e),'il-central-1'],c=['us-east-1',C(0x1fa),C(0x20c),C(0x281)],d=a===C(0x231)?b:a?a[C(0x2b4)](','):c;let f=[];const g=Log[C(0x2a8)]();for(const h of d){g[C(0x2a3)](C(0x206)+h[C(0x276)]()+C(0x2b7));const i=new ECRClient({'region':h[C(0x276)]()});try{let j=undefined;do{const k=await Promise['race']([i['send'](new DescribeRepositoriesCommand({'nextToken':j})),new Promise(l=>setTimeout(()=>l('timeout'),0x7d0))]);if(k===C(0x2c3)){Log['warn']('Timeout\x20while\x20processing\x20'+h['trim']()+'.');break;}else k[C(0x21f)]&&k[C(0x21f)]['length']>0x0&&(f=f[C(0x1f6)](k[C(0x21f)][C(0x1ff)](l=>({'name':l['repositoryName'],'uri':l[C(0x2cb)],'region':h[C(0x276)]()}))));j=k[C(0x233)];}while(j);}catch(l){Log['error'](C(0x28e)+h['trim']()+':\x20'+l['message']);}finally{g[C(0x230)]();}}return f['length']>0x0?(console[C(0x2cf)](),Log['success'](C(0x20a)),f[C(0x1f8)](m=>{const D=C;Log[D(0x223)]('Region:\x20'+m[D(0x23e)]+D(0x275)+m[D(0x24c)]+',\x20URI:\x20'+m['uri']);})):Log[C(0x2db)](C(0x250)),f;}async[a144r(0x2b6)](a){const E=a144r;try{const b={'CallerReference':''+Date['now'](),'Name':a},c=new CreateHostedZoneCommand(b);await route53Client[E(0x24a)](c),Log[E(0x1f9)](E(0x24e));}catch(d){Log[E(0x249)](E(0x28d)),console[E(0x249)](d);}}async[a144r(0x23f)](a,b,c,d){const F=a144r;try{const e={'DomainName':b,'DurationInYears':c,'AutoRenew':d,'AdminContact':a,'RegistrantContact':a,'TechContact':a,'BillingContact':a},f=new RegisterDomainCommand(e),g=await route53Domains[F(0x24a)](f);Log[F(0x295)](F(0x2c7)+b+F(0x237)),Log[F(0x295)](F(0x1fe)+JSON[F(0x254)](g));}catch(h){Log['error'](F(0x200)),Log[F(0x2db)](F(0x279)),h[F(0x2d4)]&&(console[F(0x249)](F(0x264)+h[F(0x2d4)][F(0x2c1)]),console[F(0x249)]('\x20Request\x20ID:\x20'+h['$metadata'][F(0x23d)])),console[F(0x249)](F(0x205)+h[F(0x2ca)]),h[F(0x24c)]===F(0x2c5)?Log[F(0x249)](h[F(0x2ca)]):Log[F(0x249)]('An\x20unknown\x20error\x20occurred.'),console['error'](h);}}async[a144r(0x2d5)](a){const G=a144r,b={'DomainName':a},c=new CheckDomainAvailabilityCommand(b),d=await route53Domains[G(0x24a)](c),e=d['Availability']===G(0x228);if(e){const f=a[G(0x2b4)]('.')['pop'](),g={'MaxItems':0x1,'Tld':f};try{const h=new ListPricesCommand(g),i=await route53Domains[G(0x24a)](h);if(i&&i[G(0x2c8)]&&i[G(0x2c8)][0x0]?.['RegistrationPrice']){const j=i['Prices'][0x0][G(0x2b5)];return{'available':e,'cost':j};}}catch(k){console[G(0x249)]('Error\x20fetching\x20domain\x20pricing:',k);}}return{'available':e};}async[a144r(0x2ba)](a,b,c){const H=a144r;try{const d=await route53[H(0x2b0)]({'DNSName':c});if(!d?.[H(0x2ae)])throw Log[H(0x249)]('Could\x20not\x20find\x20hosted\x20zone');const e=d?.['HostedZones'][0x0]['Id'],f={'ChangeBatch':{'Changes':[{'Action':ChangeAction['UPSERT'],'ResourceRecordSet':{'Name':c,'Type':RRType['A'],'TTL':0x12c,'ResourceRecords':[{'Value':b}]}}]},'HostedZoneId':e},g=new ChangeResourceRecordSetsCommand(f);await route53[H(0x24a)](g),Log['notice']('Successfully\x20linked\x20EC2\x20instance\x20'+a+H(0x2d3)+c);}catch(h){console[H(0x249)](H(0x26b),h);}}async[a144r(0x241)]({awsAccountId:a,region:b}){const I=a144r,c=new ECRClient({'region':b});try{const d=new GetAuthorizationTokenCommand({'registryIds':[a]}),f=await c[I(0x24a)](d);if(!f[I(0x280)]||f[I(0x280)][I(0x244)]===0x0)throw new Error(I(0x29a));const g=f[I(0x280)][0x0];if(!g['authorizationToken'])throw new Error(I(0x2c9));const h=g[I(0x21b)];if(!h)throw new Error(I(0x290));const i=Buffer['from'](h,I(0x1fb))[I(0x212)](),j=i[I(0x2b4)](':')[0x1];if(!j)throw new Error(I(0x292));return j;}catch(k){Log[I(0x249)](k);throw k;}}async[a144r(0x253)]({repoName:a,region:b}){const c=new ECRClient({'region':b});try{const d=new DeleteRepositoryCommand({'repositoryName':a,'force':!![]}),f=await c['send'](d);return f;}catch(g){Log['error'](g);throw g;}}async[a144r(0x282)](a){const J=a144r;try{const b={'BlockDeviceMappings':[{'DeviceName':J(0x2c2),'Ebs':{'VolumeSize':0x64}}],'ImageId':a['imageId'],'InstanceType':a[J(0x22b)],'KeyName':a[J(0x225)],'MaxCount':a[J(0x218)],'MinCount':a['minCount'],'SecurityGroupIds':a[J(0x274)][J(0x2b4)](','),'SubnetId':a[J(0x22d)],'TagSpecifications':[{'ResourceType':J(0x215),'Tags':a[J(0x26f)]}]};a[J(0x256)]&&(b['UserData']=J(0x29b)+a['userData']);const c=new RunInstancesCommand(b),d=await client[J(0x24a)](c);return d;}catch(f){Log[J(0x249)](f);}}async[a144r(0x294)](a){try{const b={'InstanceIds':[a['instanceId']]},c=new TerminateInstancesCommand(b),d=await client['send'](c);return d;}catch(f){return Log['error'](f),{};}}async['createKeyPairEC2Key']({keyName:a,env:b}){const K=a144r,c=this[K(0x2af)][K(0x265)](b),d=a144f[K(0x2b2)](c,K(0x1fc),a+K(0x2ce));try{const f={'KeyName':a},g=new CreateKeyPairCommand(f),h=await client[K(0x24a)](g),i=h[K(0x283)];if(i){await this[K(0x299)][K(0x2ab)]({'filePath':d,'data':i}),execSync(K(0x27c)+d,{'stdio':K(0x219)});const j=this[K(0x299)]['isFile'](d);if(j)return Log[K(0x1f9)](K(0x277)+d),{'keyName':a,'filePath':d};else throw new Error(K(0x27b));}else throw new Error('Error\x20generating\x20key\x20pair');}catch(k){Log[K(0x249)](k),process['exit'](0x1);}}async['ingressRule']({port:a,groupId:b}){const L=a144r,c={'GroupId':b,'IpPermissions':[{'FromPort':a,'IpProtocol':L(0x25d),'IpRanges':[{'CidrIp':L(0x2d6),'Description':''}],'ToPort':a}]},d=new AuthorizeSecurityGroupIngressCommand(c);return Log['notice'](L(0x211)+a+L(0x269)),await client[L(0x24a)](d);}async['ec2createSG'](a){const M=a144r;try{a[M(0x252)]===''&&(a['description']=await Actions[M(0x2a6)](M(0x232))||M(0x25e));const b={'Description':a[M(0x252)],'GroupName':a[M(0x24c)],'VpcId':a[M(0x245)]},c=new CreateSecurityGroupCommand(b),d=await client[M(0x24a)](c),{GroupId:f}=d;if(!d)throw new Error(M(0x2aa));f&&a[M(0x26e)][M(0x1f8)](g=>{const N=M;this[N(0x2e2)]({'port':parseInt(g),'groupId':f});}),Log[M(0x1f9)](M(0x2bb)+f+'\x20NAME:\x20'+a['name']);}catch(g){return Log[M(0x249)](g),![];}return!![];}async[a144r(0x2c4)](a){const Q=a144r,b=[];try{const c={},d=new DescribeKeyPairsCommand(c),f=await client['send'](d);if(!f)throw'AWS\x20was\x20not\x20able\x20to\x20validate\x20the\x20provided\x20access\x20credentials';const {KeyPairs:g}=f;g?(g?.['forEach']((h,i)=>{const O=a144d;h[O(0x2bc)]&&b[O(0x2d9)]({'id':i,'name':h['KeyName']});}),b['length']>0x0&&b['forEach'](h=>{const P=a144d;h[P(0x24c)]===a?.[P(0x266)]?Log['success'](P(0x286)+h['id']+'\x20NAME:\x20'+h[P(0x24c)]):Log[P(0x295)]('ID:\x20'+h['id']+P(0x238)+h['name']);})):Log[Q(0x249)](Q(0x1f5));}catch(h){Log[Q(0x249)](h);}return b;}async[a144r(0x201)](a){const R=a144r;try{const b={'KeyName':a},c=new DeleteKeyPairCommand(b);await client['send'](c);}catch(d){Log[R(0x249)](d),process[R(0x25a)](0x1);}}async[a144r(0x22c)](){const S=a144r,a=[];try{const b={'Filters':[{'Name':S(0x222),'Values':[S(0x2cd)]}]},c=new DescribeInstancesCommand(b),d=await client['send'](c);d[S(0x2df)]?.[S(0x1f8)]((f,g)=>{const T=S;if(f?.[T(0x2b1)]){const {InstanceId:h,PublicIpAddress:i,PrivateIpAddress:j,State:k,KeyName:l,Tags:m}=f[T(0x2b1)][0x0],n=m?.[T(0x20e)](({Key:o})=>o===T(0x208));a[T(0x2d9)]({'id':g,'instanceId':h,'privateIp':j,'publicIp':i,'status':k?.[T(0x224)],'name':l,'env':n?.['Value']});}}),a[S(0x244)]>0x0?a['forEach'](f=>{const U=S,g=U(0x286)+f['id']+U(0x238)+f[U(0x24c)]+'\x20ENV:\x20'+f[U(0x22e)]+U(0x2ac)+f[U(0x210)]+U(0x2d0)+f[U(0x214)]+U(0x2dc)+f['publicIp']+'\x20PRIV_IP:\x20'+f[U(0x227)];if(f[U(0x210)]==='terminated')Log['error'](g);else f[U(0x210)]===U(0x243)?Log[U(0x1f9)](g):Log[U(0x295)](g);}):Log['error']('You\x20have\x20no\x20instances\x20created\x20by\x20maka-cli.\x20\x20Please\x20reivew\x20your\x20AWS\x20console\x20manually!!!');}catch(f){Log[S(0x249)](f);}return a;}async[a144r(0x27f)](a){const V=a144r;try{const b={'InstanceIds':[a[V(0x214)]]},c=new RebootInstancesCommand(b),d=await client[V(0x24a)](c);return d['$metadata'][V(0x2c1)]===0xc8&&Log[V(0x1f9)]('Instance\x20rebooted!'),d;}catch(f){Log[V(0x249)](f);}}async['chooseVPC'](){const W=a144r;let a='';Log['notice'](W(0x242));const b=new DescribeVpcsCommand({}),c=await client[W(0x24a)](b),{Vpcs:d}=c,e=[];d&&d[W(0x1f8)]((g,h)=>{const X=W;g['VpcId']&&g['CidrBlock']&&e[X(0x2d9)]({'id':h,'vpcId':g['VpcId'],'cidr':g[X(0x20d)]});});e[W(0x1f8)](function(g){const Y=W;console[Y(0x2cf)]('ID:\x20'+g['id']+'\x20VPCID:\x20'+g[Y(0x245)]+Y(0x287)+g[Y(0x271)]);});const f=await Actions[W(0x2a6)](W(0x2d8))||0x0;e['forEach'](function(g){const Z=W;g['id']==f&&(a=g['vpcId'],Log[Z(0x1f9)](Z(0x220)+a+'\x0a'));});if(a==='')return Log['error'](W(0x26d)),'';return a;}async['chooseInstance'](){const a0=a144r,a=await this[a0(0x22c)]();if(a['length']===0x0)return Log[a0(0x249)](a0(0x2b8)),null;const b=await Actions['ask'](a0(0x2cc));!b&&(Log['error'](a0(0x2da)),process[a0(0x25a)](0x0));const c=a['find'](({id:d})=>{return d==parseInt(b);})||null;return c;}async[a144r(0x2bd)]({env:a}){const a1=a144r;try{const b=this[a1(0x2af)]['getMakaProjectConfig']();if(!b)throw MustBeInProjectError;const {appName:c}=b,d=c+'-'+a,f=await Actions[a1(0x2a6)](a1(0x234)+d+']\x20')||d,{filePath:g}=await this['createKeyPairEC2Key']({'keyName':f,'env':a}),h=await Actions[a1(0x273)](a1(0x28c),!![]);if(h)try{const i=a144f[a1(0x2b2)]('config',a,a1(0x248));!this[a1(0x299)][a1(0x1f7)](i)&&await this[a1(0x203)]['template']({'srcPath':'config/ssh.json','destPath':i,'context':{'app':f}});const j=a144e[a1(0x284)](a144f[a1(0x2b2)]('config',a,'ssh.json'),'utf8'),k=JSON['parse'](j);k['pem']=a144f[a1(0x2b2)](a1(0x1fc),f+'.pem.txt'),a144e[a1(0x1f3)](a144f['join'](a1(0x2d1),a,a1(0x248)),JSON[a1(0x254)](k,null,0x2));}catch(l){Log[a1(0x249)](l),Log['error'](a1(0x1f4));}return{'keyName':f,'filePath':g};}catch(m){Log[a1(0x249)](m),process[a1(0x25a)](0x1);}}async[a144r(0x26c)](a){const a2=a144r,b=[],c={},d=new DescribeSecurityGroupsCommand(c),e=await client['send'](d),{SecurityGroups:f}=e;f&&f[a2(0x1f8)](function(i,j){const a3=a2;i[a3(0x288)]&&i[a3(0x29f)]&&b[a3(0x2d9)]({'id':j,'name':i[a3(0x288)],'sgId':i[a3(0x29f)]});});let g='',h=0x0;return b[a2(0x1f8)](function(i){const a4=a2;i[a4(0x24c)]===a&&(g=i[a4(0x209)],h=i['id']);}),{'sgList':b,'createdSgId':g,'listIndexId':h};}async['deleteSecurityGroup'](a){const a5=a144r;try{const b={'GroupId':a},c=new DeleteSecurityGroupCommand(b);await client[a5(0x24a)](c);}catch(d){Log[a5(0x249)](d),process[a5(0x25a)](0x1);}}}
|
|
1
|
+
const a144s=a144d;(function(a,b){const p=a144d,c=a();while(!![]){try{const d=-parseInt(p(0x1c3))/0x1*(-parseInt(p(0x18b))/0x2)+-parseInt(p(0x156))/0x3+-parseInt(p(0x135))/0x4*(parseInt(p(0x19b))/0x5)+-parseInt(p(0x140))/0x6+-parseInt(p(0x152))/0x7*(parseInt(p(0x1c4))/0x8)+parseInt(p(0x1ac))/0x9+parseInt(p(0x196))/0xa*(parseInt(p(0x118))/0xb);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a144c,0x4d177));const a144b=(function(){let a=!![];return function(b,c){const d=a?function(){const q=a144d;if(c){const e=c[q(0xe6)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a144a=a144b(this,function(){const r=a144d;return a144a['toString']()[r(0xda)](r(0xfd))[r(0x174)]()['constructor'](a144a)[r(0xda)](r(0xfd));});a144a();import a144e from'fs';import a144f from'path';import{execSync}from'child_process';function a144d(a,b){const c=a144c();return a144d=function(d,e){d=d-0xd8;let f=c[d];return f;},a144d(a,b);}import{Actions}from'../actions/actions.class.js';import{Log}from'../log/log.class.js';import{MustBeInProjectError}from'../../error.js';import{ChangeResourceRecordSetsCommand,ChangeAction,RRType}from'@aws-sdk/client-route-53';import{EC2Client,DescribeInstancesCommand,RunInstancesCommand,TerminateInstancesCommand,CreateKeyPairCommand,AuthorizeSecurityGroupIngressCommand,CreateSecurityGroupCommand,RebootInstancesCommand,DescribeVpcsCommand,DescribeKeyPairsCommand,DeleteKeyPairCommand,DescribeSecurityGroupsCommand,DeleteSecurityGroupCommand,DescribeImagesCommand,DescribeSubnetsCommand}from'@aws-sdk/client-ec2';import{ECRClient,CreateRepositoryCommand,DeleteRepositoryCommand,GetAuthorizationTokenCommand,DescribeRepositoriesCommand}from'@aws-sdk/client-ecr';import{Route53,Route53Client,CreateHostedZoneCommand}from'@aws-sdk/client-route-53';function a144c(){const aa=['chooseInstance','GroupId','amiId','stop','.pem.txt','Authorization\x20data\x20is\x20empty','ec2describeKeys','\x20STATUS:\x20','22kkjMDO','\x20ENV:\x20','ask','Successfully\x20linked\x20EC2\x20instance\x20','virtualization-type','Error\x20saving\x20pem\x20file,\x20aborting','now','ap-northeast-1','Canonical*Ubuntu*18.04*','me-south-1','ec2describeInstances','Authorization\x20token\x20is\x20missing','parse','\x20AZONE:\x20','region','type','Region:\x20','Key\x20Name:\x20[','ebs','repositories','UPSERT','date','ca-central-1','cidr','There\x20was\x20an\x20error\x20registering\x20the\x20domain\x20name','ingressRule','pem','me-central-1','\x20DESCRIPTION:\x20','173284vkdxEV','listAvailableAMIs','nextToken','config','Error\x20creating\x20hosted\x20zone','requestId','filter','tags','chooseSecurityGroup','eu-west-1','suggestion','2816844MLpXNP','Setting\x20AMI\x20ID\x20to\x20','Error\x20fetching\x20domain\x20pricing:','Failed\x20to\x20create\x20repository\x20in\x20','\x20SG\x20NAME:\x20','ID:\x20','getTime','notice','pop','vpcId','af-south-1','Please\x20choose\x20an\x20AMI\x20ID\x20to\x20assign\x20the\x20instance\x20to:\x20[0]\x20','Invalid\x20choice','linkEC2ToRoute53','withSpinner','getSubnetCidr','\x20Request\x20ID:\x20','ecrDeleteRepository','2507351UtyKXD','No\x20instances\x20found','_keys','eu-south-2','149082OhwmHv','success','Error\x20Message:\x20','ssh.json','confirm','maxCount','base64','terminated','cfg','ap-south-1','message','CidrBlock','\x20SGID:\x20','route53CreateHostedZone','Web\x20App','status','listAvailableSubnets','Repository\x20\x22','No\x20images\x20found.','Instances','listHostedZonesByName','timeout','log','Please\x20choose\x20a\x20SG\x20to\x20assign\x20the\x20instance\x20to:\x20[','Processing\x20','trim','Reservations','tcp','sa-east-1','state','toString','**\x20Available\x20Security\x20Groups\x20**','Subnets','authorizationToken','instanceId','uri','ecrCreateRepository','length','CreationDate','x86_64','\x20PRIV_IP:\x20','eu-north-1','from','From\x20AWS:','instance','/dev/sdh','getEcrLoginPassword','file://','minCount','\x20INSTANCE_ID:\x20','isFile','No\x20ECR\x20repositories\x20found\x20across\x20all\x20specified\x20regions.','desc','12306ihYSmu','getAppConfigPath','repositoryName',',\x20URI:\x20','utf8','UserData','You\x20have\x20no\x20key-pairs,\x20please\x20create\x20one.\x20(maka\x20aws\x20create-key-pair\x20--env).','info','ap-southeast-4','privateIp','concat','5229670dVCGKP','includes','name','key','find','65UzMmQZ','hvm','Port\x20','eu-central-2','sgId','checkDomainAvailability','VpcId','description','AVAILABLE','forEach','eu-central-1','scaffold','Could\x20not\x20find\x20hosted\x20zone','listAllEcrRepositories','Hosted\x20zone\x20created\x20successfully!','eu-west-2','Failed\x20in\x20','1907766uAkWyL','KeyMaterial','Setting\x20Subnet\x20ID\x20to\x20','split','us-east-2','deleteKeyPair','httpStatusCode','eu-west-3','\x20CIDR:\x20','getMakaProjectConfig','readFileSync','subnet-id','authorizationData','ImageId','SubnetId','registerDomain','ap-southeast-2',',\x20Name:\x20','userData','machine','You\x20have\x20no\x20instances\x20created\x20by\x20maka-cli.\x20\x20Please\x20reivew\x20your\x20AWS\x20console\x20manually!!!','stringify','KeyName','81UxUcfT','8bRlqiV','deleteSecurityGroup','all','search','bright','ap-southeast-3','\x20opened!','An\x20unknown\x20error\x20occurred.','[+]\x20Setting\x20VPC\x20ID\x20to:\x20','createFile','No\x20suitable\x20images\x20found\x20within\x20the\x20last\x2030\x20days.','\x20NAME:\x20','**\x20Available\x20\x20VPCs\x20**','map','AWS\x20was\x20not\x20able\x20to\x20validate\x20the\x20provided\x20access\x20credentials','apply','RegistrationPrice','Final\x20list\x20of\x20ECR\x20repositories:','Timeout\x20while\x20processing\x20','getSecurityGroups','subnetId','createKeyPairEC2Key','TLDRulesViolation','ec2create','No\x20credentials\x20returned\x20from\x20AWS\x20ECR','Prices','ap-east-1','Description','Pem\x20key\x20saved\x20to\x20','The\x20domain\x20\x27','us-west-2','Would\x20you\x20like\x20to\x20update\x20the\x20ssh.json\x20config\x20file?','\x20:\x20','maka-cli','template','writeFileSync','join','\x20Status\x20Code:\x20','(((.+)+)+)+$','ap-northeast-3','send','error','exit','Instance\x20rebooted!','Name','Response:\x20','\x20PUB_IP:\x20','push','fsi','$metadata','\x20VPCID:\x20','sort','warn','That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.','eu-south-1','env','Availability'];a144c=function(){return aa;};return a144c();}import{Route53Domains,CheckDomainAvailabilityCommand,RegisterDomainCommand,ListPricesCommand}from'@aws-sdk/client-route-53-domains';const client=new EC2Client({}),route53Client=new Route53Client({}),route53=new Route53({}),route53Domains=new Route53Domains({});export class AWS{static [a144s(0x182)];['fsi'];[a144s(0x15e)];[a144s(0x1a6)];constructor(a,b,c){const t=a144s;this[t(0x107)]=a,this[t(0x15e)]=b,this[t(0x1a6)]=c;}static['getInstance'](a,b,c){const u=a144s;return!AWS['instance']&&(AWS['instance']=new AWS(a,b,c)),AWS[u(0x182)];}async[a144s(0x13d)](a){const v=a144s;try{const {listIndexId:b,createdSgId:c,sgList:d}=await this[v(0xea)](a);let f='';if(c===''){Log['notice'](v(0x175)),d['forEach'](function(h){const w=v;h['name']===a?Log[w(0x147)](w(0x145)+h['id']+w(0x144)+h[w(0x198)]+w(0x162)+h[w(0x19f)]):Log[w(0xdb)](w(0x145)+h['id']+w(0x144)+h[w(0x198)]+w(0x162)+h[w(0x19f)]);});const g=await Actions[v(0x11a)](v(0x16d)+b+']\x20')||b['toString']();d[v(0x1a4)](function(h){const x=v;h['id']===parseInt(g)&&(f=h[x(0x19f)],Log[x(0x157)]('Setting\x20SG\x20ID\x20to:\x20'+f+'\x0a'));});}else f=c,Log[v(0x157)]('Setting\x20SG\x20ID\x20to:\x20'+f+'\x0a');if(f==='')throw new Error('That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.');return f;}catch(h){Log[v(0x100)](h);throw h;}}async[a144s(0x136)](){const y=a144s;let a='';try{const b=new EC2Client({}),c={'Filters':[{'Name':'architecture','Values':[y(0x17d)]},{'Name':y(0x11c),'Values':[y(0x19c)]},{'Name':'root-device-type','Values':[y(0x12a)]},{'Name':y(0x173),'Values':['available']},{'Name':'image-type','Values':[y(0x1bf)]},{'Name':'description','Values':[y(0x120),'Canonical*Ubuntu*20.04*']}]},d=new DescribeImagesCommand(c),{Images:f}=await b[y(0xff)](d);if(f&&f[y(0x17b)]>0x0){const g=new Date(),h=new Date(g[y(0x146)]()-0x1e*0x18*0x3c*0x3c*0x3e8),i=f[y(0x13b)](j=>j[y(0x17c)]&&!j[y(0xf2)]?.['includes']('UNSUPPORTED')&&!j[y(0xf2)]?.[y(0x197)]('EKS')&&new Date(j['CreationDate'])>h)[y(0xe4)](j=>({'amiId':j[y(0x1b9)],'desc':j[y(0xf2)],'date':j['CreationDate']}));if(i['length']>0x0){i[y(0x10a)]((n,o)=>new Date(o[y(0x12d)])[y(0x146)]()-new Date(n[y(0x12d)])['getTime']());const j=i['slice'](0x0,0x4),k=j[y(0xe4)]((n,o)=>({'id':o,'amiId':n[y(0x112)],'desc':n[y(0x18a)]}));k[y(0x1a4)](n=>{const z=y;Log[z(0xdb)](z(0x145)+n['id']+'\x20AMIID:\x20'+n[z(0x112)]+z(0x134)+n[z(0x18a)]);});const l=await Actions[y(0x11a)](y(0x14b))||'0',m=k['find'](n=>n['id']===parseInt(l));if(m)a=m[y(0x112)],Log['success'](y(0x141)+a+y(0xf7)+m[y(0x18a)]);else throw Log[y(0x100)](y(0x10c));}else throw Log['error'](y(0xe1));}else throw Log[y(0x100)](y(0x168));}catch(n){Log[y(0x100)](n);}return a;}async[a144s(0x166)](){const A=a144s;let a='';try{const b=new EC2Client({}),c={},d=new DescribeSubnetsCommand(c),{Subnets:f}=await b[A(0xff)](d);if(f&&f[A(0x17b)]>0x0){const g=f[A(0xe4)]((j,k)=>({'id':k,'cidr':j['CidrBlock'],'az':j['AvailabilityZone'],'subnetId':j[A(0x1ba)]}));g['forEach'](j=>{const B=A;Log[B(0xdb)]('ID:\x20'+j['id']+B(0x1b4)+j[B(0x12f)]+B(0x125)+j['az']+'\x20SUBNETID:\x20'+j[B(0xeb)]);});const h=await Actions[A(0x11a)]('Please\x20choose\x20a\x20subnet\x20ID\x20to\x20assign\x20the\x20instance\x20to:\x20[0]\x20')||'0',i=g['find'](j=>j['id']===parseInt(h));if(i)a=i[A(0xeb)],Log[A(0x157)](A(0x1ae)+a);else throw Log['error'](A(0x10c));}else throw Log[A(0x100)]('No\x20subnets\x20found.');}catch(j){Log[A(0x100)](j);}return a;}async[a144s(0x14f)](a){const C=a144s;try{const b=new EC2Client({}),c={'Filters':[{'Name':C(0x1b7),'Values':[a]}]},d=new DescribeSubnetsCommand(c),e=await b[C(0xff)](d);return e['Subnets']&&e[C(0x176)][C(0x17b)]>0x0?e['Subnets'][0x0][C(0x161)]||'':'';}catch(f){return Log['error'](f),'';}}async[a144s(0x17a)](a){const D=a144s;try{const b=new ECRClient({'region':a['region']}),c={'repositoryName':a['name']},d=new CreateRepositoryCommand(c),f=await b[D(0xff)](d);return Log[D(0x157)](D(0x167)+a['name']+'\x22\x20created\x20successfully\x20in\x20'+a[D(0x126)]+'.'),f;}catch(g){Log[D(0x100)](D(0x143)+a['region']+':\x20'+g);throw g;}}async[a144s(0x1a8)](a){const E=a144s,b=['us-east-1',E(0x1b0),'us-west-1','us-west-2',E(0x15f),E(0xfe),'ap-northeast-2','ap-southeast-1',E(0x1bc),E(0x11f),E(0x12e),E(0x1a5),E(0x13e),E(0x1aa),E(0x1b3),E(0x17f),E(0x172),E(0x14a),E(0xf1),'ap-south-2',E(0xdc),E(0x193),'ca-west-1',E(0x10d),E(0x155),E(0x19e),E(0x121),E(0x133),'il-central-1'],c=['us-east-1',E(0x1b0),'us-west-1',E(0xf5)],d=a===E(0xd9)?b:a?a[E(0x1af)](','):c;let f=[];const g=Log[E(0x14e)]();for(const h of d){g['start'](E(0x16e)+h[E(0x16f)]()+'...');const i=new ECRClient({'region':h[E(0x16f)]()});try{let j=undefined;do{const k=await Promise['race']([i[E(0xff)](new DescribeRepositoriesCommand({'nextToken':j})),new Promise(l=>setTimeout(()=>l(E(0x16b)),0x7d0))]);if(k===E(0x16b)){Log[E(0x10b)](E(0xe9)+h[E(0x16f)]()+'.');break;}else k['repositories']&&k['repositories'][E(0x17b)]>0x0&&(f=f[E(0x195)](k[E(0x12b)][E(0xe4)](l=>({'name':l[E(0x18d)],'uri':l['repositoryUri'],'region':h[E(0x16f)]()}))));j=k[E(0x137)];}while(j);}catch(l){Log[E(0x100)](E(0x1ab)+h[E(0x16f)]()+':\x20'+l['message']);}finally{g[E(0x113)]();}}return f[E(0x17b)]>0x0?(console[E(0x16c)](),Log[E(0x157)](E(0xe8)),f[E(0x1a4)](m=>{const F=E;Log[F(0x192)](F(0x128)+m[F(0x126)]+F(0x1bd)+m[F(0x198)]+F(0x18e)+m[F(0x179)]);})):Log[E(0x10b)](E(0x189)),f;}async[a144s(0x163)](a){const G=a144s;try{const b={'CallerReference':''+Date[G(0x11e)](),'Name':a},c=new CreateHostedZoneCommand(b);await route53Client[G(0xff)](c),Log[G(0x157)](G(0x1a9));}catch(d){Log[G(0x100)](G(0x139)),console[G(0x100)](d);}}async[a144s(0x1bb)](a,b,c,d){const H=a144s;try{const e={'DomainName':b,'DurationInYears':c,'AutoRenew':d,'AdminContact':a,'RegistrantContact':a,'TechContact':a,'BillingContact':a},f=new RegisterDomainCommand(e),g=await route53Domains[H(0xff)](f);Log['notice'](H(0xf4)+b+'\x27\x20has\x20been\x20registered\x20successfully.'),Log[H(0x147)](H(0x104)+JSON['stringify'](g));}catch(h){Log[H(0x100)](H(0x130)),Log[H(0x10b)](H(0x181)),h['$metadata']&&(Log[H(0x100)](H(0xfc)+h['$metadata'][H(0x1b2)]),Log[H(0x100)](H(0x150)+h[H(0x108)][H(0x13a)])),Log[H(0x100)](H(0x158)+h['message']),h['name']===H(0xed)?Log[H(0x100)](h[H(0x160)]):Log[H(0x100)](H(0xde)),Log['error'](h);}}async[a144s(0x1a0)](a){const I=a144s,b={'DomainName':a},c=new CheckDomainAvailabilityCommand(b),d=await route53Domains[I(0xff)](c),e=d[I(0x10f)]===I(0x1a3);if(e){const f=a[I(0x1af)]('.')[I(0x148)](),g={'MaxItems':0x1,'Tld':f};try{const h=new ListPricesCommand(g),i=await route53Domains[I(0xff)](h);if(i&&i[I(0xf0)]&&i[I(0xf0)][0x0]?.[I(0xe7)]){const j=i['Prices'][0x0][I(0xe7)];return{'available':e,'cost':j};}}catch(k){console[I(0x100)](I(0x142),k);}}return{'available':e};}async[a144s(0x14d)](a,b,c){const J=a144s;try{const d=await route53[J(0x16a)]({'DNSName':c});if(!d?.['HostedZones'])throw Log['error'](J(0x1a7));const e=d?.['HostedZones'][0x0]['Id'],f={'ChangeBatch':{'Changes':[{'Action':ChangeAction[J(0x12c)],'ResourceRecordSet':{'Name':c,'Type':RRType['A'],'TTL':0x12c,'ResourceRecords':[{'Value':b}]}}]},'HostedZoneId':e},g=new ChangeResourceRecordSetsCommand(f);await route53['send'](g),Log['notice'](J(0x11b)+a+'\x20to\x20'+c);}catch(h){console['error']('Error\x20linking\x20EC2\x20to\x20Route\x2053:',h);}}async[a144s(0x184)]({awsAccountId:a,region:b}){const K=a144s,c=new ECRClient({'region':b});try{const d=new GetAuthorizationTokenCommand({'registryIds':[a]}),f=await c[K(0xff)](d);if(!f['authorizationData']||f[K(0x1b8)][K(0x17b)]===0x0)throw new Error(K(0x115));const g=f[K(0x1b8)][0x0];if(!g[K(0x177)])throw new Error(K(0x123));const h=g[K(0x177)];if(!h)throw new Error(K(0xef));const i=Buffer[K(0x180)](h,K(0x15c))[K(0x174)](),j=i[K(0x1af)](':')[0x1];if(!j)throw new Error('Failed\x20to\x20decode\x20password\x20from\x20authorization\x20token');return j;}catch(k){Log[K(0x100)](k);throw k;}}async[a144s(0x151)]({repoName:a,region:b}){const L=a144s,c=new ECRClient({'region':b});try{const d=new DeleteRepositoryCommand({'repositoryName':a,'force':!![]}),f=await c['send'](d);return f;}catch(g){Log[L(0x100)](g);throw g;}}async[a144s(0xee)](a){const M=a144s;try{const b={'BlockDeviceMappings':[{'DeviceName':M(0x183),'Ebs':{'VolumeSize':0x64}}],'ImageId':a['imageId'],'InstanceType':a[M(0x127)],'KeyName':a[M(0x199)],'MaxCount':a[M(0x15b)],'MinCount':a[M(0x186)],'SecurityGroupIds':a['sgIds']['split'](','),'SubnetId':a['subnet'],'TagSpecifications':[{'ResourceType':M(0x182),'Tags':a[M(0x13c)]}]};a[M(0x1be)]&&(b[M(0x190)]=M(0x185)+a['userData']);const c=new RunInstancesCommand(b),d=await client[M(0xff)](c);return d;}catch(f){Log['error'](f);}}async['ec2terminateInstance'](a){const N=a144s;try{const b={'InstanceIds':[a[N(0x178)]]},c=new TerminateInstancesCommand(b),d=await client['send'](c);return d;}catch(f){return Log[N(0x100)](f),{};}}async[a144s(0xec)]({keyName:a,env:b}){const O=a144s,c=this[O(0x15e)][O(0x18c)](b),d=a144f[O(0xfb)](c,O(0x154),a+O(0x114));try{const f={'KeyName':a},g=new CreateKeyPairCommand(f),h=await client[O(0xff)](g),i=h[O(0x1ad)];if(i){await this[O(0x107)][O(0xe0)]({'filePath':d,'data':i}),execSync('chmod\x20400\x20'+d,{'stdio':'ignore'});const j=this['fsi']['isFile'](d);if(j)return Log[O(0x157)](O(0xf3)+d),{'keyName':a,'filePath':d};else throw new Error(O(0x11d));}else throw new Error('Error\x20generating\x20key\x20pair');}catch(k){Log['error'](k),process[O(0x101)](0x1);}}async[a144s(0x131)]({port:a,groupId:b}){const P=a144s,c={'GroupId':b,'IpPermissions':[{'FromPort':a,'IpProtocol':P(0x171),'IpRanges':[{'CidrIp':'0.0.0.0/0','Description':''}],'ToPort':a}]},d=new AuthorizeSecurityGroupIngressCommand(c);return Log[P(0x147)](P(0x19d)+a+P(0xdd)),await client['send'](d);}async['ec2createSG'](a){const Q=a144s;try{a[Q(0x1a2)]===''&&(a['description']=await Actions[Q(0x11a)]('Description:')||Q(0x164));const b={'Description':a[Q(0x1a2)],'GroupName':a[Q(0x198)],'VpcId':a['vpcId']},c=new CreateSecurityGroupCommand(b),d=await client[Q(0xff)](c),{GroupId:f}=d;if(!d)throw new Error(Q(0xe5));f&&a['sgPorts'][Q(0x1a4)](g=>{const R=Q;this[R(0x131)]({'port':parseInt(g),'groupId':f});}),Log[Q(0x157)]('Created:\x20'+f+Q(0xe2)+a[Q(0x198)]);}catch(g){return Log[Q(0x100)](g),![];}return!![];}async[a144s(0x116)](a){const S=a144s,b=[];try{const c={},d=new DescribeKeyPairsCommand(c),f=await client[S(0xff)](d);if(!f)throw S(0xe5);const {KeyPairs:g}=f;g?(g?.[S(0x1a4)]((h,i)=>{const T=S;h[T(0x1c2)]&&b['push']({'id':i,'name':h[T(0x1c2)]});}),b[S(0x17b)]>0x0&&b[S(0x1a4)](h=>{const U=S;h[U(0x198)]===a?.[U(0x13f)]?Log['success'](U(0x145)+h['id']+U(0xe2)+h['name']):Log[U(0x147)](U(0x145)+h['id']+U(0xe2)+h[U(0x198)]);})):Log[S(0x100)](S(0x191));}catch(h){Log[S(0x100)](h);}return b;}async[a144s(0x1b1)](a){const V=a144s;try{const b={'KeyName':a},c=new DeleteKeyPairCommand(b);await client[V(0xff)](c);}catch(d){Log[V(0x100)](d),process[V(0x101)](0x1);}}async[a144s(0x122)](){const W=a144s,a=[];try{const b={'Filters':[{'Name':'tag:created-by','Values':[W(0xf8)]}]},c=new DescribeInstancesCommand(b),d=await client[W(0xff)](c);d[W(0x170)]?.[W(0x1a4)]((f,g)=>{const X=W;if(f?.[X(0x169)]){const {InstanceId:h,PublicIpAddress:i,PrivateIpAddress:j,State:k,KeyName:l,Tags:m}=f[X(0x169)][0x0],n=m?.['find'](({Key:o})=>o==='environment');a[X(0x106)]({'id':g,'instanceId':h,'privateIp':j,'publicIp':i,'status':k?.[X(0x103)],'name':l,'env':n?.['Value']});}}),a[W(0x17b)]>0x0?a['forEach'](f=>{const Y=W,g=Y(0x145)+f['id']+Y(0xe2)+f[Y(0x198)]+Y(0x119)+f[Y(0x10e)]+Y(0x117)+f[Y(0x165)]+Y(0x187)+f[Y(0x178)]+Y(0x105)+f['publicIp']+Y(0x17e)+f[Y(0x194)];if(f[Y(0x165)]===Y(0x15d))Log[Y(0x100)](g);else f[Y(0x165)]==='running'?Log[Y(0x157)](g):Log[Y(0x147)](g);}):Log[W(0x100)](W(0x1c0));}catch(f){Log[W(0x100)](f);}return a;}async['ec2rebootInstance'](a){const Z=a144s;try{const b={'InstanceIds':[a['instanceId']]},c=new RebootInstancesCommand(b),d=await client['send'](c);return d['$metadata'][Z(0x1b2)]===0xc8&&Log[Z(0x157)](Z(0x102)),d;}catch(f){Log['error'](f);}}async['chooseVPC'](){const a0=a144s;let a='';Log['notice'](a0(0xe3));const b=new DescribeVpcsCommand({}),c=await client[a0(0xff)](b),{Vpcs:d}=c,e=[];d&&d[a0(0x1a4)]((g,h)=>{const a1=a0;g[a1(0x1a1)]&&g[a1(0x161)]&&e[a1(0x106)]({'id':h,'vpcId':g[a1(0x1a1)],'cidr':g['CidrBlock']});});e[a0(0x1a4)](function(g){const a2=a0;console[a2(0x16c)](a2(0x145)+g['id']+a2(0x109)+g['vpcId']+a2(0x1b4)+g['cidr']);});const f=await Actions[a0(0x11a)]('Please\x20choose\x20a\x20VPC:\x20[0]\x20')||0x0;e[a0(0x1a4)](function(g){const a3=a0;g['id']==f&&(a=g[a3(0x149)],Log['success'](a3(0xdf)+a+'\x0a'));});if(a==='')return Log[a0(0x100)]('That\x20was\x20not\x20an\x20id\x20in\x20the\x20list.'),'';return a;}async[a144s(0x110)](){const a4=a144s,a=await this['ec2describeInstances']();if(a['length']===0x0)return Log[a4(0x100)](a4(0x153)),null;const b=await Actions['ask']('[?]\x20Please\x20choose\x20an\x20instance\x20ID:\x20');!b&&(Log['error'](a4(0x14c)),process[a4(0x101)](0x0));const c=a[a4(0x19a)](({id:d})=>{return d==parseInt(b);})||null;return c;}async['createKeyPair']({env:a}){const a5=a144s;try{const b=this[a5(0x15e)][a5(0x1b5)]();if(!b)throw MustBeInProjectError;const {appName:c}=b,d=c+'-'+a,f=await Actions['ask'](a5(0x129)+d+']\x20')||d,{filePath:g}=await this['createKeyPairEC2Key']({'keyName':f,'env':a}),h=await Actions[a5(0x15a)](a5(0xf6),!![]);if(h)try{const i=a144f[a5(0xfb)](a5(0x138),a,a5(0x159));!this[a5(0x107)][a5(0x188)](i)&&await this[a5(0x1a6)][a5(0xf9)]({'srcPath':'config/ssh.json','destPath':i,'context':{'app':f}});const j=a144e[a5(0x1b6)](a144f[a5(0xfb)](a5(0x138),a,a5(0x159)),a5(0x18f)),k=JSON[a5(0x124)](j);k[a5(0x132)]=a144f['join'](a5(0x154),f+a5(0x114)),a144e[a5(0xfa)](a144f[a5(0xfb)](a5(0x138),a,a5(0x159)),JSON[a5(0x1c1)](k,null,0x2));}catch(l){Log[a5(0x100)](l),Log[a5(0x100)]('You\x20will\x20need\x20to\x20update\x20the\x20ssh.json\x20file\x20yourself.');}return{'keyName':f,'filePath':g};}catch(m){Log['error'](m),process[a5(0x101)](0x1);}}async[a144s(0xea)](a){const a6=a144s,b=[],c={},d=new DescribeSecurityGroupsCommand(c),e=await client[a6(0xff)](d),{SecurityGroups:f}=e;f&&f[a6(0x1a4)](function(i,j){const a7=a6;i['GroupName']&&i[a7(0x111)]&&b[a7(0x106)]({'id':j,'name':i['GroupName'],'sgId':i[a7(0x111)]});});let g='',h=0x0;return b[a6(0x1a4)](function(i){const a8=a6;i[a8(0x198)]===a&&(g=i[a8(0x19f)],h=i['id']);}),{'sgList':b,'createdSgId':g,'listIndexId':h};}async[a144s(0xd8)](a){const a9=a144s;try{const b={'GroupId':a},c=new DeleteSecurityGroupCommand(b);await client[a9(0xff)](c);}catch(d){Log[a9(0x100)](d),process[a9(0x101)](0x1);}}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(a,b){var k=a145d,c=a();while(!![]){try{var d=-parseInt(k(
|
|
1
|
+
(function(a,b){var k=a145d,c=a();while(!![]){try{var d=-parseInt(k(0x9a))/0x1+-parseInt(k(0xa0))/0x2*(-parseInt(k(0x9f))/0x3)+parseInt(k(0x99))/0x4*(parseInt(k(0x98))/0x5)+parseInt(k(0x95))/0x6*(-parseInt(k(0xa3))/0x7)+-parseInt(k(0x97))/0x8*(parseInt(k(0x9e))/0x9)+-parseInt(k(0x96))/0xa+parseInt(k(0xa4))/0xb*(parseInt(k(0xa2))/0xc);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a145c,0x52e73));function a145d(a,b){var c=a145c();return a145d=function(d,e){d=d-0x95;var f=c[d];return f;},a145d(a,b);}export var CountryCode;(function(c){var d=(function(){var f=!![];return function(g,h){var i=f?function(){var l=a145d;if(h){var j=h[l(0x9b)](g,arguments);return h=null,j;}}:function(){};return f=![],i;};}()),e=d(this,function(){var m=a145d;return e['toString']()['search'](m(0xa1))[m(0x9d)]()['constructor'](e)[m(0x9c)](m(0xa1));});e(),c['AC']='AC',c['AD']='AD',c['AE']='AE',c['AF']='AF',c['AG']='AG',c['AI']='AI',c['AL']='AL',c['AM']='AM',c['AN']='AN',c['AO']='AO',c['AQ']='AQ',c['AR']='AR',c['AS']='AS',c['AT']='AT',c['AU']='AU',c['AW']='AW',c['AX']='AX',c['AZ']='AZ',c['BA']='BA',c['BB']='BB',c['BD']='BD',c['BE']='BE',c['BF']='BF',c['BG']='BG',c['BH']='BH',c['BI']='BI',c['BJ']='BJ',c['BL']='BL',c['BM']='BM',c['BN']='BN',c['BO']='BO',c['BQ']='BQ',c['BR']='BR',c['BS']='BS',c['BT']='BT',c['BV']='BV',c['BW']='BW',c['BY']='BY',c['BZ']='BZ',c['CA']='CA',c['CC']='CC',c['CD']='CD',c['CF']='CF',c['CG']='CG',c['CH']='CH',c['CI']='CI',c['CK']='CK',c['CL']='CL',c['CM']='CM',c['CN']='CN',c['CO']='CO',c['CR']='CR',c['CU']='CU',c['CV']='CV',c['CW']='CW',c['CX']='CX',c['CY']='CY',c['CZ']='CZ',c['DE']='DE',c['DJ']='DJ',c['DK']='DK',c['DM']='DM',c['DO']='DO',c['DZ']='DZ',c['EC']='EC',c['EE']='EE',c['EG']='EG',c['EH']='EH',c['ER']='ER',c['ES']='ES',c['ET']='ET',c['FI']='FI',c['FJ']='FJ',c['FK']='FK',c['FM']='FM',c['FO']='FO',c['FR']='FR',c['GA']='GA',c['GB']='GB',c['GD']='GD',c['GE']='GE',c['GF']='GF',c['GG']='GG',c['GH']='GH',c['GI']='GI',c['GL']='GL',c['GM']='GM',c['GN']='GN',c['GP']='GP',c['GQ']='GQ',c['GR']='GR',c['GS']='GS',c['GT']='GT',c['GU']='GU',c['GW']='GW',c['GY']='GY',c['HK']='HK',c['HM']='HM',c['HN']='HN',c['HR']='HR',c['HT']='HT',c['HU']='HU',c['ID']='ID',c['IE']='IE',c['IL']='IL',c['IM']='IM',c['IN']='IN',c['IO']='IO',c['IQ']='IQ',c['IR']='IR',c['IS']='IS',c['IT']='IT',c['JE']='JE',c['JM']='JM',c['JO']='JO',c['JP']='JP',c['KE']='KE',c['KG']='KG',c['KH']='KH',c['KI']='KI',c['KM']='KM',c['KN']='KN',c['KP']='KP',c['KR']='KR',c['KW']='KW',c['KY']='KY',c['KZ']='KZ',c['LA']='LA',c['LB']='LB',c['LC']='LC',c['LI']='LI',c['LK']='LK',c['LR']='LR',c['LS']='LS',c['LT']='LT',c['LU']='LU',c['LV']='LV',c['LY']='LY',c['MA']='MA',c['MC']='MC',c['MD']='MD',c['ME']='ME',c['MF']='MF',c['MG']='MG',c['MH']='MH',c['MK']='MK',c['ML']='ML',c['MM']='MM',c['MN']='MN',c['MO']='MO',c['MP']='MP',c['MQ']='MQ',c['MR']='MR',c['MS']='MS',c['MT']='MT',c['MU']='MU',c['MV']='MV',c['MW']='MW',c['MX']='MX',c['MY']='MY',c['MZ']='MZ',c['NA']='NA',c['NC']='NC',c['NE']='NE',c['NF']='NF',c['NG']='NG',c['NI']='NI',c['NL']='NL',c['NO']='NO',c['NP']='NP',c['NR']='NR',c['NU']='NU',c['NZ']='NZ',c['OM']='OM',c['PA']='PA',c['PE']='PE',c['PF']='PF',c['PG']='PG',c['PH']='PH',c['PK']='PK',c['PL']='PL',c['PM']='PM',c['PN']='PN',c['PR']='PR',c['PS']='PS',c['PT']='PT',c['PW']='PW',c['PY']='PY',c['QA']='QA',c['RE']='RE',c['RO']='RO',c['RS']='RS',c['RU']='RU',c['RW']='RW',c['SA']='SA',c['SB']='SB',c['SC']='SC',c['SD']='SD',c['SE']='SE',c['SG']='SG',c['SH']='SH',c['SI']='SI',c['SJ']='SJ',c['SK']='SK',c['SL']='SL',c['SM']='SM',c['SN']='SN',c['SO']='SO',c['SR']='SR',c['SS']='SS',c['ST']='ST',c['SV']='SV',c['SX']='SX',c['SY']='SY',c['SZ']='SZ',c['TC']='TC',c['TD']='TD',c['TF']='TF',c['TG']='TG',c['TH']='TH',c['TJ']='TJ',c['TK']='TK',c['TL']='TL',c['TM']='TM',c['TN']='TN',c['TO']='TO',c['TP']='TP',c['TR']='TR',c['TT']='TT',c['TV']='TV',c['TW']='TW',c['TZ']='TZ',c['UA']='UA',c['UG']='UG',c['US']='US',c['UY']='UY',c['UZ']='UZ',c['VA']='VA',c['VC']='VC',c['VE']='VE',c['VG']='VG',c['VI']='VI',c['VN']='VN',c['VU']='VU',c['WF']='WF',c['WS']='WS',c['YE']='YE',c['YT']='YT',c['ZA']='ZA',c['ZM']='ZM',c['ZW']='ZW';}(CountryCode||(CountryCode={})));function a145c(){var n=['search','toString','5908041NmBxnC','9UQSaPg','41982CjhhLG','(((.+)+)+)+$','238512PPsEIC','42ibDdsY','847HSayTB','620166LwcnXz','2516150rHTvnq','8VdUrYt','535aGunUa','13828VaNpLi','95523CwUmVH','apply'];a145c=function(){return n;};return a145c();}
|