sst 2.22.6 → 2.22.8
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/constructs/Function.d.ts +10 -0
- package/constructs/Function.js +5 -3
- package/constructs/Job.d.ts +10 -0
- package/constructs/Job.js +1 -0
- package/constructs/NextjsSite.js +1 -0
- package/constructs/SsrFunction.js +2 -2
- package/constructs/Table.js +7 -15
- package/credentials.d.ts +0 -1
- package/credentials.js +0 -1
- package/package.json +1 -1
- package/runtime/handlers/container.js +11 -1
- package/runtime/handlers/node.js +26 -19
- package/sst.mjs +38 -912
package/constructs/Function.d.ts
CHANGED
|
@@ -554,6 +554,16 @@ export interface ContainerProps {
|
|
|
554
554
|
* ```
|
|
555
555
|
*/
|
|
556
556
|
cmd?: string[];
|
|
557
|
+
/**
|
|
558
|
+
* Name of the Dockerfile.
|
|
559
|
+
* @example
|
|
560
|
+
* ```js
|
|
561
|
+
* container: {
|
|
562
|
+
* file: "path/to/Dockerfile.prod"
|
|
563
|
+
* }
|
|
564
|
+
* ```
|
|
565
|
+
*/
|
|
566
|
+
file?: string;
|
|
557
567
|
}
|
|
558
568
|
/**
|
|
559
569
|
* Used to configure additional files to copy into the function bundle
|
package/constructs/Function.js
CHANGED
|
@@ -172,6 +172,7 @@ export class Function extends CDKFunction {
|
|
|
172
172
|
this.addEnvironment("SST_FUNCTION_ID", this.node.addr);
|
|
173
173
|
useDeferredTasks().add(async () => {
|
|
174
174
|
const bootstrap = await useBootstrap();
|
|
175
|
+
const bootstrapBucketArn = `arn:${Stack.of(this).partition}:s3:::${bootstrap.bucket}`;
|
|
175
176
|
this.attachPermissions([
|
|
176
177
|
new PolicyStatement({
|
|
177
178
|
actions: ["iot:*"],
|
|
@@ -181,9 +182,7 @@ export class Function extends CDKFunction {
|
|
|
181
182
|
new PolicyStatement({
|
|
182
183
|
actions: ["s3:*"],
|
|
183
184
|
effect: Effect.ALLOW,
|
|
184
|
-
resources: [
|
|
185
|
-
`arn:${Stack.of(this).partition}:s3:::${bootstrap.bucket}`,
|
|
186
|
-
],
|
|
185
|
+
resources: [bootstrapBucketArn, `${bootstrapBucketArn}/*`],
|
|
187
186
|
}),
|
|
188
187
|
]);
|
|
189
188
|
});
|
|
@@ -199,6 +198,9 @@ export class Function extends CDKFunction {
|
|
|
199
198
|
? { platform: Platform.custom(architecture.dockerPlatform) }
|
|
200
199
|
: {}),
|
|
201
200
|
...(props.container?.cmd ? { cmd: props.container.cmd } : {}),
|
|
201
|
+
...(props.container?.file
|
|
202
|
+
? { file: props.container.file }
|
|
203
|
+
: {}),
|
|
202
204
|
}),
|
|
203
205
|
handler: CDKHandler.FROM_IMAGE,
|
|
204
206
|
runtime: CDKRuntime.FROM_IMAGE,
|
package/constructs/Job.d.ts
CHANGED
|
@@ -21,6 +21,16 @@ export interface JobContainerProps {
|
|
|
21
21
|
* ```
|
|
22
22
|
*/
|
|
23
23
|
cmd: string[];
|
|
24
|
+
/**
|
|
25
|
+
* Name of the Dockerfile.
|
|
26
|
+
* @example
|
|
27
|
+
* ```js
|
|
28
|
+
* container: {
|
|
29
|
+
* file: "path/to/Dockerfile.prod"
|
|
30
|
+
* }
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
file?: string;
|
|
24
34
|
}
|
|
25
35
|
export interface JobProps {
|
|
26
36
|
/**
|
package/constructs/Job.js
CHANGED
|
@@ -209,6 +209,7 @@ export class Job extends Construct {
|
|
|
209
209
|
platform: architecture === "arm_64"
|
|
210
210
|
? Platform.custom("linux/arm64")
|
|
211
211
|
: Platform.custom("linux/amd64"),
|
|
212
|
+
file: container?.file,
|
|
212
213
|
});
|
|
213
214
|
image.repository?.grantPull(this.job.role);
|
|
214
215
|
const project = this.job.node.defaultChild;
|
package/constructs/NextjsSite.js
CHANGED
|
@@ -260,6 +260,7 @@ export class NextjsSite extends SsrSite {
|
|
|
260
260
|
"rsc",
|
|
261
261
|
"next-router-prefetch",
|
|
262
262
|
"next-router-state-tree",
|
|
263
|
+
"next-url",
|
|
263
264
|
]);
|
|
264
265
|
const serverBehavior = this.buildDefaultBehaviorForRegional(cachePolicy);
|
|
265
266
|
return new Distribution(this, "Distribution", {
|
|
@@ -79,7 +79,7 @@ export class SsrFunction extends Construct {
|
|
|
79
79
|
attachPermissionsToRole(this.function.role, permissions);
|
|
80
80
|
}
|
|
81
81
|
createFunction(assetBucket, assetKey) {
|
|
82
|
-
const { runtime, timeout, memorySize, handler, logRetention } = this.props;
|
|
82
|
+
const { architecture, runtime, timeout, memorySize, handler, logRetention, } = this.props;
|
|
83
83
|
return new CdkFunction(this, `ServerFunction`, {
|
|
84
84
|
...this.props,
|
|
85
85
|
handler: handler.split(path.sep).join(path.posix.sep),
|
|
@@ -90,7 +90,7 @@ export class SsrFunction extends Construct {
|
|
|
90
90
|
: runtime === "nodejs16.x"
|
|
91
91
|
? Runtime.NODEJS_16_X
|
|
92
92
|
: Runtime.NODEJS_18_X,
|
|
93
|
-
architecture: Architecture.ARM_64,
|
|
93
|
+
architecture: architecture || Architecture.ARM_64,
|
|
94
94
|
memorySize: typeof memorySize === "string"
|
|
95
95
|
? toCdkSize(memorySize).toMebibytes()
|
|
96
96
|
: memorySize,
|
package/constructs/Table.js
CHANGED
|
@@ -356,25 +356,17 @@ export class Table extends Construct {
|
|
|
356
356
|
else {
|
|
357
357
|
consumerFunction = consumer;
|
|
358
358
|
}
|
|
359
|
-
eventSourceProps = {
|
|
360
|
-
startingPosition: lambda.StartingPosition.LATEST,
|
|
361
|
-
...(eventSourceProps || {}),
|
|
362
|
-
};
|
|
363
359
|
// create function
|
|
364
360
|
const fn = Fn.fromDefinition(scope, `Consumer_${this.node.id}_${consumerName}`, consumerFunction, this.props.defaults?.function, `The "defaults.function" cannot be applied if an instance of a Function construct is passed in. Make sure to define all the consumers using FunctionProps, so the Table construct can apply the "defaults.function" to them.`);
|
|
365
361
|
this.functions[consumerName] = fn;
|
|
366
362
|
// create event source
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
Pattern: JSON.stringify(filter),
|
|
375
|
-
})),
|
|
376
|
-
});
|
|
377
|
-
}
|
|
363
|
+
fn.addEventSource(new lambdaEventSources.DynamoEventSource(this.cdk.table, {
|
|
364
|
+
startingPosition: lambda.StartingPosition.LATEST,
|
|
365
|
+
filters: filters?.map((filter) => ({
|
|
366
|
+
pattern: JSON.stringify(filter),
|
|
367
|
+
})),
|
|
368
|
+
...(eventSourceProps || {}),
|
|
369
|
+
}));
|
|
378
370
|
// attach permissions
|
|
379
371
|
this.permissionsAttachedForAllConsumers.forEach((permissions) => {
|
|
380
372
|
fn.attachPermissions(permissions);
|
package/credentials.d.ts
CHANGED
package/credentials.js
CHANGED
package/package.json
CHANGED
|
@@ -52,7 +52,14 @@ export const useContainerHandler = Context.memo(async () => {
|
|
|
52
52
|
sources.set(input.functionID, project);
|
|
53
53
|
if (input.mode === "start") {
|
|
54
54
|
try {
|
|
55
|
-
const result = await execAsync(
|
|
55
|
+
const result = await execAsync([
|
|
56
|
+
`docker build`,
|
|
57
|
+
`-t sst-dev:${input.functionID}`,
|
|
58
|
+
...(input.props.container?.file
|
|
59
|
+
? [`-f ${input.props.container.file}`]
|
|
60
|
+
: []),
|
|
61
|
+
`.`,
|
|
62
|
+
].join(" "), {
|
|
56
63
|
cwd: project,
|
|
57
64
|
env: {
|
|
58
65
|
...process.env,
|
|
@@ -74,6 +81,9 @@ export const useContainerHandler = Context.memo(async () => {
|
|
|
74
81
|
await execAsync([
|
|
75
82
|
`docker build`,
|
|
76
83
|
`-t sst-build:${input.functionID}`,
|
|
84
|
+
...(input.props.container?.file
|
|
85
|
+
? [`-f ${input.props.container.file}`]
|
|
86
|
+
: []),
|
|
77
87
|
`--platform ${platform}`,
|
|
78
88
|
`.`,
|
|
79
89
|
].join(" "), {
|
package/runtime/handlers/node.js
CHANGED
|
@@ -10,9 +10,9 @@ import { Worker } from "worker_threads";
|
|
|
10
10
|
import { useRuntimeHandlers } from "../handlers.js";
|
|
11
11
|
import { useRuntimeWorkers } from "../workers.js";
|
|
12
12
|
import { Context } from "../../context/context.js";
|
|
13
|
-
import { VisibleError } from "../../error.js";
|
|
14
13
|
import { Colors } from "../../cli/colors.js";
|
|
15
14
|
import { Logger } from "../../logger.js";
|
|
15
|
+
import { findAbove } from "../../util/fs.js";
|
|
16
16
|
export const useNodeHandler = Context.memo(async () => {
|
|
17
17
|
const workers = await useRuntimeWorkers();
|
|
18
18
|
const handlers = useRuntimeHandlers();
|
|
@@ -95,6 +95,22 @@ export const useNodeHandler = Context.memo(async () => {
|
|
|
95
95
|
.relative(input.out, target.replace(extension, parsed.ext))
|
|
96
96
|
.split(path.sep)
|
|
97
97
|
.join(path.posix.sep);
|
|
98
|
+
if (input.mode === "start") {
|
|
99
|
+
const root = await findAbove(parsed.dir, "package.json");
|
|
100
|
+
if (!root) {
|
|
101
|
+
return {
|
|
102
|
+
type: "error",
|
|
103
|
+
errors: [
|
|
104
|
+
`Could not find package.json for handler "${input.props.handler}"`,
|
|
105
|
+
],
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
const dir = path.join(root, "node_modules");
|
|
109
|
+
try {
|
|
110
|
+
await fs.symlink(path.resolve(dir), path.resolve(path.join(input.out, "node_modules")), "dir");
|
|
111
|
+
}
|
|
112
|
+
catch { }
|
|
113
|
+
}
|
|
98
114
|
// Rebuilt using existing esbuild context
|
|
99
115
|
const exists = rebuildCache[input.functionID];
|
|
100
116
|
if (exists) {
|
|
@@ -174,18 +190,16 @@ export const useNodeHandler = Context.memo(async () => {
|
|
|
174
190
|
.forEach(({ path }) => {
|
|
175
191
|
warnings.push(`You are importing from "${path}" in "${inputPath}". Did you mean to import from "sst/node"?`);
|
|
176
192
|
}));
|
|
177
|
-
async function find(dir, target) {
|
|
178
|
-
if (dir === "/")
|
|
179
|
-
throw new VisibleError("Could not find a package.json file");
|
|
180
|
-
if (await fs
|
|
181
|
-
.access(path.join(dir, target))
|
|
182
|
-
.then(() => true)
|
|
183
|
-
.catch(() => false))
|
|
184
|
-
return dir;
|
|
185
|
-
return find(path.join(dir, ".."), target);
|
|
186
|
-
}
|
|
187
193
|
if (input.mode === "deploy" && installPackages) {
|
|
188
|
-
const src = await
|
|
194
|
+
const src = await findAbove(parsed.dir, "package.json");
|
|
195
|
+
if (!src) {
|
|
196
|
+
return {
|
|
197
|
+
type: "error",
|
|
198
|
+
errors: [
|
|
199
|
+
`Could not find package.json for handler "${input.props.handler}"`,
|
|
200
|
+
],
|
|
201
|
+
};
|
|
202
|
+
}
|
|
189
203
|
const json = JSON.parse(await fs
|
|
190
204
|
.readFile(path.join(src, "package.json"))
|
|
191
205
|
.then((x) => x.toString()));
|
|
@@ -207,13 +221,6 @@ export const useNodeHandler = Context.memo(async () => {
|
|
|
207
221
|
});
|
|
208
222
|
});
|
|
209
223
|
}
|
|
210
|
-
if (input.mode === "start") {
|
|
211
|
-
const dir = path.join(await find(parsed.dir, "package.json"), "node_modules");
|
|
212
|
-
try {
|
|
213
|
-
await fs.symlink(path.resolve(dir), path.resolve(path.join(input.out, "node_modules")), "dir");
|
|
214
|
-
}
|
|
215
|
-
catch { }
|
|
216
|
-
}
|
|
217
224
|
// Cache esbuild result and context for rebuild
|
|
218
225
|
if (input.mode === "start") {
|
|
219
226
|
rebuildCache[input.functionID] = { ctx, result };
|
package/sst.mjs
CHANGED
|
@@ -1,39 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire as topLevelCreateRequire } from 'module';
|
|
3
3
|
global.require = topLevelCreateRequire(import.meta.url);
|
|
4
|
-
var __create = Object.create;
|
|
5
4
|
var __defProp = Object.defineProperty;
|
|
6
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
9
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
6
|
var __esm = (fn, res) => function __init() {
|
|
11
7
|
return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
|
|
12
8
|
};
|
|
13
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
14
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
15
|
-
};
|
|
16
9
|
var __export = (target, all) => {
|
|
17
10
|
for (var name in all)
|
|
18
11
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
12
|
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
29
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
30
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
31
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
32
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
33
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
34
|
-
mod
|
|
35
|
-
));
|
|
36
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
37
13
|
|
|
38
14
|
// src/context/context.ts
|
|
39
15
|
var context_exports = {};
|
|
@@ -863,868 +839,6 @@ var init_spinner = __esm({
|
|
|
863
839
|
}
|
|
864
840
|
});
|
|
865
841
|
|
|
866
|
-
// ../../node_modules/.pnpm/tslib@2.6.0/node_modules/tslib/tslib.es6.mjs
|
|
867
|
-
var tslib_es6_exports = {};
|
|
868
|
-
__export(tslib_es6_exports, {
|
|
869
|
-
__addDisposableResource: () => __addDisposableResource,
|
|
870
|
-
__assign: () => __assign,
|
|
871
|
-
__asyncDelegator: () => __asyncDelegator,
|
|
872
|
-
__asyncGenerator: () => __asyncGenerator,
|
|
873
|
-
__asyncValues: () => __asyncValues,
|
|
874
|
-
__await: () => __await,
|
|
875
|
-
__awaiter: () => __awaiter,
|
|
876
|
-
__classPrivateFieldGet: () => __classPrivateFieldGet,
|
|
877
|
-
__classPrivateFieldIn: () => __classPrivateFieldIn,
|
|
878
|
-
__classPrivateFieldSet: () => __classPrivateFieldSet,
|
|
879
|
-
__createBinding: () => __createBinding,
|
|
880
|
-
__decorate: () => __decorate,
|
|
881
|
-
__disposeResources: () => __disposeResources,
|
|
882
|
-
__esDecorate: () => __esDecorate,
|
|
883
|
-
__exportStar: () => __exportStar,
|
|
884
|
-
__extends: () => __extends,
|
|
885
|
-
__generator: () => __generator,
|
|
886
|
-
__importDefault: () => __importDefault,
|
|
887
|
-
__importStar: () => __importStar,
|
|
888
|
-
__makeTemplateObject: () => __makeTemplateObject,
|
|
889
|
-
__metadata: () => __metadata,
|
|
890
|
-
__param: () => __param,
|
|
891
|
-
__propKey: () => __propKey,
|
|
892
|
-
__read: () => __read,
|
|
893
|
-
__rest: () => __rest,
|
|
894
|
-
__runInitializers: () => __runInitializers,
|
|
895
|
-
__setFunctionName: () => __setFunctionName,
|
|
896
|
-
__spread: () => __spread,
|
|
897
|
-
__spreadArray: () => __spreadArray,
|
|
898
|
-
__spreadArrays: () => __spreadArrays,
|
|
899
|
-
__values: () => __values,
|
|
900
|
-
default: () => tslib_es6_default
|
|
901
|
-
});
|
|
902
|
-
function __extends(d, b) {
|
|
903
|
-
if (typeof b !== "function" && b !== null)
|
|
904
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
905
|
-
extendStatics(d, b);
|
|
906
|
-
function __() {
|
|
907
|
-
this.constructor = d;
|
|
908
|
-
}
|
|
909
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
910
|
-
}
|
|
911
|
-
function __rest(s, e) {
|
|
912
|
-
var t = {};
|
|
913
|
-
for (var p in s)
|
|
914
|
-
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
915
|
-
t[p] = s[p];
|
|
916
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
917
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
918
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
919
|
-
t[p[i]] = s[p[i]];
|
|
920
|
-
}
|
|
921
|
-
return t;
|
|
922
|
-
}
|
|
923
|
-
function __decorate(decorators, target, key, desc) {
|
|
924
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
925
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
|
|
926
|
-
r = Reflect.decorate(decorators, target, key, desc);
|
|
927
|
-
else
|
|
928
|
-
for (var i = decorators.length - 1; i >= 0; i--)
|
|
929
|
-
if (d = decorators[i])
|
|
930
|
-
r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
931
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
932
|
-
}
|
|
933
|
-
function __param(paramIndex, decorator) {
|
|
934
|
-
return function(target, key) {
|
|
935
|
-
decorator(target, key, paramIndex);
|
|
936
|
-
};
|
|
937
|
-
}
|
|
938
|
-
function __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
|
|
939
|
-
function accept(f) {
|
|
940
|
-
if (f !== void 0 && typeof f !== "function")
|
|
941
|
-
throw new TypeError("Function expected");
|
|
942
|
-
return f;
|
|
943
|
-
}
|
|
944
|
-
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
|
|
945
|
-
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
|
|
946
|
-
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
|
|
947
|
-
var _, done = false;
|
|
948
|
-
for (var i = decorators.length - 1; i >= 0; i--) {
|
|
949
|
-
var context = {};
|
|
950
|
-
for (var p in contextIn)
|
|
951
|
-
context[p] = p === "access" ? {} : contextIn[p];
|
|
952
|
-
for (var p in contextIn.access)
|
|
953
|
-
context.access[p] = contextIn.access[p];
|
|
954
|
-
context.addInitializer = function(f) {
|
|
955
|
-
if (done)
|
|
956
|
-
throw new TypeError("Cannot add initializers after decoration has completed");
|
|
957
|
-
extraInitializers.push(accept(f || null));
|
|
958
|
-
};
|
|
959
|
-
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
|
|
960
|
-
if (kind === "accessor") {
|
|
961
|
-
if (result === void 0)
|
|
962
|
-
continue;
|
|
963
|
-
if (result === null || typeof result !== "object")
|
|
964
|
-
throw new TypeError("Object expected");
|
|
965
|
-
if (_ = accept(result.get))
|
|
966
|
-
descriptor.get = _;
|
|
967
|
-
if (_ = accept(result.set))
|
|
968
|
-
descriptor.set = _;
|
|
969
|
-
if (_ = accept(result.init))
|
|
970
|
-
initializers.unshift(_);
|
|
971
|
-
} else if (_ = accept(result)) {
|
|
972
|
-
if (kind === "field")
|
|
973
|
-
initializers.unshift(_);
|
|
974
|
-
else
|
|
975
|
-
descriptor[key] = _;
|
|
976
|
-
}
|
|
977
|
-
}
|
|
978
|
-
if (target)
|
|
979
|
-
Object.defineProperty(target, contextIn.name, descriptor);
|
|
980
|
-
done = true;
|
|
981
|
-
}
|
|
982
|
-
function __runInitializers(thisArg, initializers, value) {
|
|
983
|
-
var useValue = arguments.length > 2;
|
|
984
|
-
for (var i = 0; i < initializers.length; i++) {
|
|
985
|
-
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
|
|
986
|
-
}
|
|
987
|
-
return useValue ? value : void 0;
|
|
988
|
-
}
|
|
989
|
-
function __propKey(x) {
|
|
990
|
-
return typeof x === "symbol" ? x : "".concat(x);
|
|
991
|
-
}
|
|
992
|
-
function __setFunctionName(f, name, prefix) {
|
|
993
|
-
if (typeof name === "symbol")
|
|
994
|
-
name = name.description ? "[".concat(name.description, "]") : "";
|
|
995
|
-
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
996
|
-
}
|
|
997
|
-
function __metadata(metadataKey, metadataValue) {
|
|
998
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
|
|
999
|
-
return Reflect.metadata(metadataKey, metadataValue);
|
|
1000
|
-
}
|
|
1001
|
-
function __awaiter(thisArg, _arguments, P, generator2) {
|
|
1002
|
-
function adopt(value) {
|
|
1003
|
-
return value instanceof P ? value : new P(function(resolve2) {
|
|
1004
|
-
resolve2(value);
|
|
1005
|
-
});
|
|
1006
|
-
}
|
|
1007
|
-
return new (P || (P = Promise))(function(resolve2, reject) {
|
|
1008
|
-
function fulfilled(value) {
|
|
1009
|
-
try {
|
|
1010
|
-
step(generator2.next(value));
|
|
1011
|
-
} catch (e) {
|
|
1012
|
-
reject(e);
|
|
1013
|
-
}
|
|
1014
|
-
}
|
|
1015
|
-
function rejected(value) {
|
|
1016
|
-
try {
|
|
1017
|
-
step(generator2["throw"](value));
|
|
1018
|
-
} catch (e) {
|
|
1019
|
-
reject(e);
|
|
1020
|
-
}
|
|
1021
|
-
}
|
|
1022
|
-
function step(result) {
|
|
1023
|
-
result.done ? resolve2(result.value) : adopt(result.value).then(fulfilled, rejected);
|
|
1024
|
-
}
|
|
1025
|
-
step((generator2 = generator2.apply(thisArg, _arguments || [])).next());
|
|
1026
|
-
});
|
|
1027
|
-
}
|
|
1028
|
-
function __generator(thisArg, body) {
|
|
1029
|
-
var _ = { label: 0, sent: function() {
|
|
1030
|
-
if (t[0] & 1)
|
|
1031
|
-
throw t[1];
|
|
1032
|
-
return t[1];
|
|
1033
|
-
}, trys: [], ops: [] }, f, y, t, g;
|
|
1034
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
|
|
1035
|
-
return this;
|
|
1036
|
-
}), g;
|
|
1037
|
-
function verb(n) {
|
|
1038
|
-
return function(v) {
|
|
1039
|
-
return step([n, v]);
|
|
1040
|
-
};
|
|
1041
|
-
}
|
|
1042
|
-
function step(op) {
|
|
1043
|
-
if (f)
|
|
1044
|
-
throw new TypeError("Generator is already executing.");
|
|
1045
|
-
while (g && (g = 0, op[0] && (_ = 0)), _)
|
|
1046
|
-
try {
|
|
1047
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
|
|
1048
|
-
return t;
|
|
1049
|
-
if (y = 0, t)
|
|
1050
|
-
op = [op[0] & 2, t.value];
|
|
1051
|
-
switch (op[0]) {
|
|
1052
|
-
case 0:
|
|
1053
|
-
case 1:
|
|
1054
|
-
t = op;
|
|
1055
|
-
break;
|
|
1056
|
-
case 4:
|
|
1057
|
-
_.label++;
|
|
1058
|
-
return { value: op[1], done: false };
|
|
1059
|
-
case 5:
|
|
1060
|
-
_.label++;
|
|
1061
|
-
y = op[1];
|
|
1062
|
-
op = [0];
|
|
1063
|
-
continue;
|
|
1064
|
-
case 7:
|
|
1065
|
-
op = _.ops.pop();
|
|
1066
|
-
_.trys.pop();
|
|
1067
|
-
continue;
|
|
1068
|
-
default:
|
|
1069
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
|
|
1070
|
-
_ = 0;
|
|
1071
|
-
continue;
|
|
1072
|
-
}
|
|
1073
|
-
if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
|
|
1074
|
-
_.label = op[1];
|
|
1075
|
-
break;
|
|
1076
|
-
}
|
|
1077
|
-
if (op[0] === 6 && _.label < t[1]) {
|
|
1078
|
-
_.label = t[1];
|
|
1079
|
-
t = op;
|
|
1080
|
-
break;
|
|
1081
|
-
}
|
|
1082
|
-
if (t && _.label < t[2]) {
|
|
1083
|
-
_.label = t[2];
|
|
1084
|
-
_.ops.push(op);
|
|
1085
|
-
break;
|
|
1086
|
-
}
|
|
1087
|
-
if (t[2])
|
|
1088
|
-
_.ops.pop();
|
|
1089
|
-
_.trys.pop();
|
|
1090
|
-
continue;
|
|
1091
|
-
}
|
|
1092
|
-
op = body.call(thisArg, _);
|
|
1093
|
-
} catch (e) {
|
|
1094
|
-
op = [6, e];
|
|
1095
|
-
y = 0;
|
|
1096
|
-
} finally {
|
|
1097
|
-
f = t = 0;
|
|
1098
|
-
}
|
|
1099
|
-
if (op[0] & 5)
|
|
1100
|
-
throw op[1];
|
|
1101
|
-
return { value: op[0] ? op[1] : void 0, done: true };
|
|
1102
|
-
}
|
|
1103
|
-
}
|
|
1104
|
-
function __exportStar(m, o) {
|
|
1105
|
-
for (var p in m)
|
|
1106
|
-
if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
|
|
1107
|
-
__createBinding(o, m, p);
|
|
1108
|
-
}
|
|
1109
|
-
function __values(o) {
|
|
1110
|
-
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
1111
|
-
if (m)
|
|
1112
|
-
return m.call(o);
|
|
1113
|
-
if (o && typeof o.length === "number")
|
|
1114
|
-
return {
|
|
1115
|
-
next: function() {
|
|
1116
|
-
if (o && i >= o.length)
|
|
1117
|
-
o = void 0;
|
|
1118
|
-
return { value: o && o[i++], done: !o };
|
|
1119
|
-
}
|
|
1120
|
-
};
|
|
1121
|
-
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
1122
|
-
}
|
|
1123
|
-
function __read(o, n) {
|
|
1124
|
-
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
1125
|
-
if (!m)
|
|
1126
|
-
return o;
|
|
1127
|
-
var i = m.call(o), r, ar = [], e;
|
|
1128
|
-
try {
|
|
1129
|
-
while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
|
|
1130
|
-
ar.push(r.value);
|
|
1131
|
-
} catch (error3) {
|
|
1132
|
-
e = { error: error3 };
|
|
1133
|
-
} finally {
|
|
1134
|
-
try {
|
|
1135
|
-
if (r && !r.done && (m = i["return"]))
|
|
1136
|
-
m.call(i);
|
|
1137
|
-
} finally {
|
|
1138
|
-
if (e)
|
|
1139
|
-
throw e.error;
|
|
1140
|
-
}
|
|
1141
|
-
}
|
|
1142
|
-
return ar;
|
|
1143
|
-
}
|
|
1144
|
-
function __spread() {
|
|
1145
|
-
for (var ar = [], i = 0; i < arguments.length; i++)
|
|
1146
|
-
ar = ar.concat(__read(arguments[i]));
|
|
1147
|
-
return ar;
|
|
1148
|
-
}
|
|
1149
|
-
function __spreadArrays() {
|
|
1150
|
-
for (var s = 0, i = 0, il = arguments.length; i < il; i++)
|
|
1151
|
-
s += arguments[i].length;
|
|
1152
|
-
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
1153
|
-
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
1154
|
-
r[k] = a[j];
|
|
1155
|
-
return r;
|
|
1156
|
-
}
|
|
1157
|
-
function __spreadArray(to, from, pack) {
|
|
1158
|
-
if (pack || arguments.length === 2)
|
|
1159
|
-
for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
1160
|
-
if (ar || !(i in from)) {
|
|
1161
|
-
if (!ar)
|
|
1162
|
-
ar = Array.prototype.slice.call(from, 0, i);
|
|
1163
|
-
ar[i] = from[i];
|
|
1164
|
-
}
|
|
1165
|
-
}
|
|
1166
|
-
return to.concat(ar || Array.prototype.slice.call(from));
|
|
1167
|
-
}
|
|
1168
|
-
function __await(v) {
|
|
1169
|
-
return this instanceof __await ? (this.v = v, this) : new __await(v);
|
|
1170
|
-
}
|
|
1171
|
-
function __asyncGenerator(thisArg, _arguments, generator2) {
|
|
1172
|
-
if (!Symbol.asyncIterator)
|
|
1173
|
-
throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
1174
|
-
var g = generator2.apply(thisArg, _arguments || []), i, q = [];
|
|
1175
|
-
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() {
|
|
1176
|
-
return this;
|
|
1177
|
-
}, i;
|
|
1178
|
-
function verb(n) {
|
|
1179
|
-
if (g[n])
|
|
1180
|
-
i[n] = function(v) {
|
|
1181
|
-
return new Promise(function(a, b) {
|
|
1182
|
-
q.push([n, v, a, b]) > 1 || resume(n, v);
|
|
1183
|
-
});
|
|
1184
|
-
};
|
|
1185
|
-
}
|
|
1186
|
-
function resume(n, v) {
|
|
1187
|
-
try {
|
|
1188
|
-
step(g[n](v));
|
|
1189
|
-
} catch (e) {
|
|
1190
|
-
settle(q[0][3], e);
|
|
1191
|
-
}
|
|
1192
|
-
}
|
|
1193
|
-
function step(r) {
|
|
1194
|
-
r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r);
|
|
1195
|
-
}
|
|
1196
|
-
function fulfill(value) {
|
|
1197
|
-
resume("next", value);
|
|
1198
|
-
}
|
|
1199
|
-
function reject(value) {
|
|
1200
|
-
resume("throw", value);
|
|
1201
|
-
}
|
|
1202
|
-
function settle(f, v) {
|
|
1203
|
-
if (f(v), q.shift(), q.length)
|
|
1204
|
-
resume(q[0][0], q[0][1]);
|
|
1205
|
-
}
|
|
1206
|
-
}
|
|
1207
|
-
function __asyncDelegator(o) {
|
|
1208
|
-
var i, p;
|
|
1209
|
-
return i = {}, verb("next"), verb("throw", function(e) {
|
|
1210
|
-
throw e;
|
|
1211
|
-
}), verb("return"), i[Symbol.iterator] = function() {
|
|
1212
|
-
return this;
|
|
1213
|
-
}, i;
|
|
1214
|
-
function verb(n, f) {
|
|
1215
|
-
i[n] = o[n] ? function(v) {
|
|
1216
|
-
return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v;
|
|
1217
|
-
} : f;
|
|
1218
|
-
}
|
|
1219
|
-
}
|
|
1220
|
-
function __asyncValues(o) {
|
|
1221
|
-
if (!Symbol.asyncIterator)
|
|
1222
|
-
throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
1223
|
-
var m = o[Symbol.asyncIterator], i;
|
|
1224
|
-
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() {
|
|
1225
|
-
return this;
|
|
1226
|
-
}, i);
|
|
1227
|
-
function verb(n) {
|
|
1228
|
-
i[n] = o[n] && function(v) {
|
|
1229
|
-
return new Promise(function(resolve2, reject) {
|
|
1230
|
-
v = o[n](v), settle(resolve2, reject, v.done, v.value);
|
|
1231
|
-
});
|
|
1232
|
-
};
|
|
1233
|
-
}
|
|
1234
|
-
function settle(resolve2, reject, d, v) {
|
|
1235
|
-
Promise.resolve(v).then(function(v2) {
|
|
1236
|
-
resolve2({ value: v2, done: d });
|
|
1237
|
-
}, reject);
|
|
1238
|
-
}
|
|
1239
|
-
}
|
|
1240
|
-
function __makeTemplateObject(cooked, raw) {
|
|
1241
|
-
if (Object.defineProperty) {
|
|
1242
|
-
Object.defineProperty(cooked, "raw", { value: raw });
|
|
1243
|
-
} else {
|
|
1244
|
-
cooked.raw = raw;
|
|
1245
|
-
}
|
|
1246
|
-
return cooked;
|
|
1247
|
-
}
|
|
1248
|
-
function __importStar(mod) {
|
|
1249
|
-
if (mod && mod.__esModule)
|
|
1250
|
-
return mod;
|
|
1251
|
-
var result = {};
|
|
1252
|
-
if (mod != null) {
|
|
1253
|
-
for (var k in mod)
|
|
1254
|
-
if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
|
|
1255
|
-
__createBinding(result, mod, k);
|
|
1256
|
-
}
|
|
1257
|
-
__setModuleDefault(result, mod);
|
|
1258
|
-
return result;
|
|
1259
|
-
}
|
|
1260
|
-
function __importDefault(mod) {
|
|
1261
|
-
return mod && mod.__esModule ? mod : { default: mod };
|
|
1262
|
-
}
|
|
1263
|
-
function __classPrivateFieldGet(receiver, state2, kind, f) {
|
|
1264
|
-
if (kind === "a" && !f)
|
|
1265
|
-
throw new TypeError("Private accessor was defined without a getter");
|
|
1266
|
-
if (typeof state2 === "function" ? receiver !== state2 || !f : !state2.has(receiver))
|
|
1267
|
-
throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
1268
|
-
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state2.get(receiver);
|
|
1269
|
-
}
|
|
1270
|
-
function __classPrivateFieldSet(receiver, state2, value, kind, f) {
|
|
1271
|
-
if (kind === "m")
|
|
1272
|
-
throw new TypeError("Private method is not writable");
|
|
1273
|
-
if (kind === "a" && !f)
|
|
1274
|
-
throw new TypeError("Private accessor was defined without a setter");
|
|
1275
|
-
if (typeof state2 === "function" ? receiver !== state2 || !f : !state2.has(receiver))
|
|
1276
|
-
throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
1277
|
-
return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state2.set(receiver, value), value;
|
|
1278
|
-
}
|
|
1279
|
-
function __classPrivateFieldIn(state2, receiver) {
|
|
1280
|
-
if (receiver === null || typeof receiver !== "object" && typeof receiver !== "function")
|
|
1281
|
-
throw new TypeError("Cannot use 'in' operator on non-object");
|
|
1282
|
-
return typeof state2 === "function" ? receiver === state2 : state2.has(receiver);
|
|
1283
|
-
}
|
|
1284
|
-
function __addDisposableResource(env, value, async) {
|
|
1285
|
-
if (value !== null && value !== void 0) {
|
|
1286
|
-
if (typeof value !== "object")
|
|
1287
|
-
throw new TypeError("Object expected.");
|
|
1288
|
-
var dispose;
|
|
1289
|
-
if (async) {
|
|
1290
|
-
if (!Symbol.asyncDispose)
|
|
1291
|
-
throw new TypeError("Symbol.asyncDispose is not defined.");
|
|
1292
|
-
dispose = value[Symbol.asyncDispose];
|
|
1293
|
-
}
|
|
1294
|
-
if (dispose === void 0) {
|
|
1295
|
-
if (!Symbol.dispose)
|
|
1296
|
-
throw new TypeError("Symbol.dispose is not defined.");
|
|
1297
|
-
dispose = value[Symbol.dispose];
|
|
1298
|
-
}
|
|
1299
|
-
if (typeof dispose !== "function")
|
|
1300
|
-
throw new TypeError("Object not disposable.");
|
|
1301
|
-
env.stack.push({ value, dispose, async });
|
|
1302
|
-
} else if (async) {
|
|
1303
|
-
env.stack.push({ async: true });
|
|
1304
|
-
}
|
|
1305
|
-
return value;
|
|
1306
|
-
}
|
|
1307
|
-
function __disposeResources(env) {
|
|
1308
|
-
function fail(e) {
|
|
1309
|
-
env.error = env.hasError ? new _SuppressedError(e, env.error, "An error was suppressed during disposal.") : e;
|
|
1310
|
-
env.hasError = true;
|
|
1311
|
-
}
|
|
1312
|
-
function next() {
|
|
1313
|
-
while (env.stack.length) {
|
|
1314
|
-
var rec = env.stack.pop();
|
|
1315
|
-
try {
|
|
1316
|
-
var result = rec.dispose && rec.dispose.call(rec.value);
|
|
1317
|
-
if (rec.async)
|
|
1318
|
-
return Promise.resolve(result).then(next, function(e) {
|
|
1319
|
-
fail(e);
|
|
1320
|
-
return next();
|
|
1321
|
-
});
|
|
1322
|
-
} catch (e) {
|
|
1323
|
-
fail(e);
|
|
1324
|
-
}
|
|
1325
|
-
}
|
|
1326
|
-
if (env.hasError)
|
|
1327
|
-
throw env.error;
|
|
1328
|
-
}
|
|
1329
|
-
return next();
|
|
1330
|
-
}
|
|
1331
|
-
var extendStatics, __assign, __createBinding, __setModuleDefault, _SuppressedError, tslib_es6_default;
|
|
1332
|
-
var init_tslib_es6 = __esm({
|
|
1333
|
-
"../../node_modules/.pnpm/tslib@2.6.0/node_modules/tslib/tslib.es6.mjs"() {
|
|
1334
|
-
extendStatics = function(d, b) {
|
|
1335
|
-
extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
|
|
1336
|
-
d2.__proto__ = b2;
|
|
1337
|
-
} || function(d2, b2) {
|
|
1338
|
-
for (var p in b2)
|
|
1339
|
-
if (Object.prototype.hasOwnProperty.call(b2, p))
|
|
1340
|
-
d2[p] = b2[p];
|
|
1341
|
-
};
|
|
1342
|
-
return extendStatics(d, b);
|
|
1343
|
-
};
|
|
1344
|
-
__assign = function() {
|
|
1345
|
-
__assign = Object.assign || function __assign2(t) {
|
|
1346
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
1347
|
-
s = arguments[i];
|
|
1348
|
-
for (var p in s)
|
|
1349
|
-
if (Object.prototype.hasOwnProperty.call(s, p))
|
|
1350
|
-
t[p] = s[p];
|
|
1351
|
-
}
|
|
1352
|
-
return t;
|
|
1353
|
-
};
|
|
1354
|
-
return __assign.apply(this, arguments);
|
|
1355
|
-
};
|
|
1356
|
-
__createBinding = Object.create ? function(o, m, k, k2) {
|
|
1357
|
-
if (k2 === void 0)
|
|
1358
|
-
k2 = k;
|
|
1359
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
1360
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
1361
|
-
desc = { enumerable: true, get: function() {
|
|
1362
|
-
return m[k];
|
|
1363
|
-
} };
|
|
1364
|
-
}
|
|
1365
|
-
Object.defineProperty(o, k2, desc);
|
|
1366
|
-
} : function(o, m, k, k2) {
|
|
1367
|
-
if (k2 === void 0)
|
|
1368
|
-
k2 = k;
|
|
1369
|
-
o[k2] = m[k];
|
|
1370
|
-
};
|
|
1371
|
-
__setModuleDefault = Object.create ? function(o, v) {
|
|
1372
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
1373
|
-
} : function(o, v) {
|
|
1374
|
-
o["default"] = v;
|
|
1375
|
-
};
|
|
1376
|
-
_SuppressedError = typeof SuppressedError === "function" ? SuppressedError : function(error3, suppressed, message) {
|
|
1377
|
-
var e = new Error(message);
|
|
1378
|
-
return e.name = "SuppressedError", e.error = error3, e.suppressed = suppressed, e;
|
|
1379
|
-
};
|
|
1380
|
-
tslib_es6_default = {
|
|
1381
|
-
__extends,
|
|
1382
|
-
__assign,
|
|
1383
|
-
__rest,
|
|
1384
|
-
__decorate,
|
|
1385
|
-
__param,
|
|
1386
|
-
__metadata,
|
|
1387
|
-
__awaiter,
|
|
1388
|
-
__generator,
|
|
1389
|
-
__createBinding,
|
|
1390
|
-
__exportStar,
|
|
1391
|
-
__values,
|
|
1392
|
-
__read,
|
|
1393
|
-
__spread,
|
|
1394
|
-
__spreadArrays,
|
|
1395
|
-
__spreadArray,
|
|
1396
|
-
__await,
|
|
1397
|
-
__asyncGenerator,
|
|
1398
|
-
__asyncDelegator,
|
|
1399
|
-
__asyncValues,
|
|
1400
|
-
__makeTemplateObject,
|
|
1401
|
-
__importStar,
|
|
1402
|
-
__importDefault,
|
|
1403
|
-
__classPrivateFieldGet,
|
|
1404
|
-
__classPrivateFieldSet,
|
|
1405
|
-
__classPrivateFieldIn,
|
|
1406
|
-
__addDisposableResource,
|
|
1407
|
-
__disposeResources
|
|
1408
|
-
};
|
|
1409
|
-
}
|
|
1410
|
-
});
|
|
1411
|
-
|
|
1412
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/abort.js
|
|
1413
|
-
var require_abort = __commonJS({
|
|
1414
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/abort.js"(exports) {
|
|
1415
|
-
"use strict";
|
|
1416
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1417
|
-
}
|
|
1418
|
-
});
|
|
1419
|
-
|
|
1420
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/auth.js
|
|
1421
|
-
var require_auth = __commonJS({
|
|
1422
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/auth.js"(exports) {
|
|
1423
|
-
"use strict";
|
|
1424
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1425
|
-
exports.HttpAuthLocation = void 0;
|
|
1426
|
-
var HttpAuthLocation;
|
|
1427
|
-
(function(HttpAuthLocation2) {
|
|
1428
|
-
HttpAuthLocation2["HEADER"] = "header";
|
|
1429
|
-
HttpAuthLocation2["QUERY"] = "query";
|
|
1430
|
-
})(HttpAuthLocation = exports.HttpAuthLocation || (exports.HttpAuthLocation = {}));
|
|
1431
|
-
}
|
|
1432
|
-
});
|
|
1433
|
-
|
|
1434
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/checksum.js
|
|
1435
|
-
var require_checksum = __commonJS({
|
|
1436
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/checksum.js"(exports) {
|
|
1437
|
-
"use strict";
|
|
1438
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1439
|
-
}
|
|
1440
|
-
});
|
|
1441
|
-
|
|
1442
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/client.js
|
|
1443
|
-
var require_client = __commonJS({
|
|
1444
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/client.js"(exports) {
|
|
1445
|
-
"use strict";
|
|
1446
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1447
|
-
}
|
|
1448
|
-
});
|
|
1449
|
-
|
|
1450
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/command.js
|
|
1451
|
-
var require_command = __commonJS({
|
|
1452
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/command.js"(exports) {
|
|
1453
|
-
"use strict";
|
|
1454
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1455
|
-
}
|
|
1456
|
-
});
|
|
1457
|
-
|
|
1458
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/credentials.js
|
|
1459
|
-
var require_credentials = __commonJS({
|
|
1460
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/credentials.js"(exports) {
|
|
1461
|
-
"use strict";
|
|
1462
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1463
|
-
}
|
|
1464
|
-
});
|
|
1465
|
-
|
|
1466
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/crypto.js
|
|
1467
|
-
var require_crypto = __commonJS({
|
|
1468
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/crypto.js"(exports) {
|
|
1469
|
-
"use strict";
|
|
1470
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1471
|
-
}
|
|
1472
|
-
});
|
|
1473
|
-
|
|
1474
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/dns.js
|
|
1475
|
-
var require_dns = __commonJS({
|
|
1476
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/dns.js"(exports) {
|
|
1477
|
-
"use strict";
|
|
1478
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1479
|
-
exports.HostAddressType = void 0;
|
|
1480
|
-
var HostAddressType;
|
|
1481
|
-
(function(HostAddressType2) {
|
|
1482
|
-
HostAddressType2["AAAA"] = "AAAA";
|
|
1483
|
-
HostAddressType2["A"] = "A";
|
|
1484
|
-
})(HostAddressType = exports.HostAddressType || (exports.HostAddressType = {}));
|
|
1485
|
-
}
|
|
1486
|
-
});
|
|
1487
|
-
|
|
1488
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/endpoint.js
|
|
1489
|
-
var require_endpoint = __commonJS({
|
|
1490
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/endpoint.js"(exports) {
|
|
1491
|
-
"use strict";
|
|
1492
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1493
|
-
exports.EndpointURLScheme = void 0;
|
|
1494
|
-
var EndpointURLScheme;
|
|
1495
|
-
(function(EndpointURLScheme2) {
|
|
1496
|
-
EndpointURLScheme2["HTTP"] = "http";
|
|
1497
|
-
EndpointURLScheme2["HTTPS"] = "https";
|
|
1498
|
-
})(EndpointURLScheme = exports.EndpointURLScheme || (exports.EndpointURLScheme = {}));
|
|
1499
|
-
}
|
|
1500
|
-
});
|
|
1501
|
-
|
|
1502
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/eventStream.js
|
|
1503
|
-
var require_eventStream = __commonJS({
|
|
1504
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/eventStream.js"(exports) {
|
|
1505
|
-
"use strict";
|
|
1506
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1507
|
-
}
|
|
1508
|
-
});
|
|
1509
|
-
|
|
1510
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/http.js
|
|
1511
|
-
var require_http = __commonJS({
|
|
1512
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/http.js"(exports) {
|
|
1513
|
-
"use strict";
|
|
1514
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1515
|
-
}
|
|
1516
|
-
});
|
|
1517
|
-
|
|
1518
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/AnonymousIdentity.js
|
|
1519
|
-
var require_AnonymousIdentity = __commonJS({
|
|
1520
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/AnonymousIdentity.js"(exports) {
|
|
1521
|
-
"use strict";
|
|
1522
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1523
|
-
}
|
|
1524
|
-
});
|
|
1525
|
-
|
|
1526
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/AwsCredentialIdentity.js
|
|
1527
|
-
var require_AwsCredentialIdentity = __commonJS({
|
|
1528
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/AwsCredentialIdentity.js"(exports) {
|
|
1529
|
-
"use strict";
|
|
1530
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1531
|
-
}
|
|
1532
|
-
});
|
|
1533
|
-
|
|
1534
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/Identity.js
|
|
1535
|
-
var require_Identity = __commonJS({
|
|
1536
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/Identity.js"(exports) {
|
|
1537
|
-
"use strict";
|
|
1538
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1539
|
-
}
|
|
1540
|
-
});
|
|
1541
|
-
|
|
1542
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/LoginIdentity.js
|
|
1543
|
-
var require_LoginIdentity = __commonJS({
|
|
1544
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/LoginIdentity.js"(exports) {
|
|
1545
|
-
"use strict";
|
|
1546
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1547
|
-
}
|
|
1548
|
-
});
|
|
1549
|
-
|
|
1550
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/TokenIdentity.js
|
|
1551
|
-
var require_TokenIdentity = __commonJS({
|
|
1552
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/TokenIdentity.js"(exports) {
|
|
1553
|
-
"use strict";
|
|
1554
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1555
|
-
}
|
|
1556
|
-
});
|
|
1557
|
-
|
|
1558
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/index.js
|
|
1559
|
-
var require_identity = __commonJS({
|
|
1560
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/identity/index.js"(exports) {
|
|
1561
|
-
"use strict";
|
|
1562
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1563
|
-
var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
1564
|
-
tslib_1.__exportStar(require_AnonymousIdentity(), exports);
|
|
1565
|
-
tslib_1.__exportStar(require_AwsCredentialIdentity(), exports);
|
|
1566
|
-
tslib_1.__exportStar(require_Identity(), exports);
|
|
1567
|
-
tslib_1.__exportStar(require_LoginIdentity(), exports);
|
|
1568
|
-
tslib_1.__exportStar(require_TokenIdentity(), exports);
|
|
1569
|
-
}
|
|
1570
|
-
});
|
|
1571
|
-
|
|
1572
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/logger.js
|
|
1573
|
-
var require_logger = __commonJS({
|
|
1574
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/logger.js"(exports) {
|
|
1575
|
-
"use strict";
|
|
1576
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1577
|
-
}
|
|
1578
|
-
});
|
|
1579
|
-
|
|
1580
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/middleware.js
|
|
1581
|
-
var require_middleware = __commonJS({
|
|
1582
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/middleware.js"(exports) {
|
|
1583
|
-
"use strict";
|
|
1584
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1585
|
-
}
|
|
1586
|
-
});
|
|
1587
|
-
|
|
1588
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/pagination.js
|
|
1589
|
-
var require_pagination = __commonJS({
|
|
1590
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/pagination.js"(exports) {
|
|
1591
|
-
"use strict";
|
|
1592
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1593
|
-
}
|
|
1594
|
-
});
|
|
1595
|
-
|
|
1596
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/profile.js
|
|
1597
|
-
var require_profile = __commonJS({
|
|
1598
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/profile.js"(exports) {
|
|
1599
|
-
"use strict";
|
|
1600
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1601
|
-
}
|
|
1602
|
-
});
|
|
1603
|
-
|
|
1604
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/request.js
|
|
1605
|
-
var require_request = __commonJS({
|
|
1606
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/request.js"(exports) {
|
|
1607
|
-
"use strict";
|
|
1608
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1609
|
-
}
|
|
1610
|
-
});
|
|
1611
|
-
|
|
1612
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/response.js
|
|
1613
|
-
var require_response = __commonJS({
|
|
1614
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/response.js"(exports) {
|
|
1615
|
-
"use strict";
|
|
1616
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1617
|
-
}
|
|
1618
|
-
});
|
|
1619
|
-
|
|
1620
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/retry.js
|
|
1621
|
-
var require_retry = __commonJS({
|
|
1622
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/retry.js"(exports) {
|
|
1623
|
-
"use strict";
|
|
1624
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1625
|
-
}
|
|
1626
|
-
});
|
|
1627
|
-
|
|
1628
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/serde.js
|
|
1629
|
-
var require_serde = __commonJS({
|
|
1630
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/serde.js"(exports) {
|
|
1631
|
-
"use strict";
|
|
1632
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1633
|
-
}
|
|
1634
|
-
});
|
|
1635
|
-
|
|
1636
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/shapes.js
|
|
1637
|
-
var require_shapes = __commonJS({
|
|
1638
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/shapes.js"(exports) {
|
|
1639
|
-
"use strict";
|
|
1640
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1641
|
-
}
|
|
1642
|
-
});
|
|
1643
|
-
|
|
1644
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/signature.js
|
|
1645
|
-
var require_signature = __commonJS({
|
|
1646
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/signature.js"(exports) {
|
|
1647
|
-
"use strict";
|
|
1648
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1649
|
-
}
|
|
1650
|
-
});
|
|
1651
|
-
|
|
1652
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/stream.js
|
|
1653
|
-
var require_stream = __commonJS({
|
|
1654
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/stream.js"(exports) {
|
|
1655
|
-
"use strict";
|
|
1656
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1657
|
-
}
|
|
1658
|
-
});
|
|
1659
|
-
|
|
1660
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/token.js
|
|
1661
|
-
var require_token = __commonJS({
|
|
1662
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/token.js"(exports) {
|
|
1663
|
-
"use strict";
|
|
1664
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1665
|
-
}
|
|
1666
|
-
});
|
|
1667
|
-
|
|
1668
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/transfer.js
|
|
1669
|
-
var require_transfer = __commonJS({
|
|
1670
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/transfer.js"(exports) {
|
|
1671
|
-
"use strict";
|
|
1672
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1673
|
-
}
|
|
1674
|
-
});
|
|
1675
|
-
|
|
1676
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/util.js
|
|
1677
|
-
var require_util = __commonJS({
|
|
1678
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/util.js"(exports) {
|
|
1679
|
-
"use strict";
|
|
1680
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1681
|
-
}
|
|
1682
|
-
});
|
|
1683
|
-
|
|
1684
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/waiter.js
|
|
1685
|
-
var require_waiter = __commonJS({
|
|
1686
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/waiter.js"(exports) {
|
|
1687
|
-
"use strict";
|
|
1688
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1689
|
-
}
|
|
1690
|
-
});
|
|
1691
|
-
|
|
1692
|
-
// ../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/index.js
|
|
1693
|
-
var require_dist_cjs = __commonJS({
|
|
1694
|
-
"../../node_modules/.pnpm/@aws-sdk+types@3.272.0/node_modules/@aws-sdk/types/dist-cjs/index.js"(exports) {
|
|
1695
|
-
"use strict";
|
|
1696
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1697
|
-
var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
1698
|
-
tslib_1.__exportStar(require_abort(), exports);
|
|
1699
|
-
tslib_1.__exportStar(require_auth(), exports);
|
|
1700
|
-
tslib_1.__exportStar(require_checksum(), exports);
|
|
1701
|
-
tslib_1.__exportStar(require_client(), exports);
|
|
1702
|
-
tslib_1.__exportStar(require_command(), exports);
|
|
1703
|
-
tslib_1.__exportStar(require_credentials(), exports);
|
|
1704
|
-
tslib_1.__exportStar(require_crypto(), exports);
|
|
1705
|
-
tslib_1.__exportStar(require_dns(), exports);
|
|
1706
|
-
tslib_1.__exportStar(require_endpoint(), exports);
|
|
1707
|
-
tslib_1.__exportStar(require_eventStream(), exports);
|
|
1708
|
-
tslib_1.__exportStar(require_http(), exports);
|
|
1709
|
-
tslib_1.__exportStar(require_identity(), exports);
|
|
1710
|
-
tslib_1.__exportStar(require_logger(), exports);
|
|
1711
|
-
tslib_1.__exportStar(require_middleware(), exports);
|
|
1712
|
-
tslib_1.__exportStar(require_pagination(), exports);
|
|
1713
|
-
tslib_1.__exportStar(require_profile(), exports);
|
|
1714
|
-
tslib_1.__exportStar(require_request(), exports);
|
|
1715
|
-
tslib_1.__exportStar(require_response(), exports);
|
|
1716
|
-
tslib_1.__exportStar(require_retry(), exports);
|
|
1717
|
-
tslib_1.__exportStar(require_serde(), exports);
|
|
1718
|
-
tslib_1.__exportStar(require_shapes(), exports);
|
|
1719
|
-
tslib_1.__exportStar(require_signature(), exports);
|
|
1720
|
-
tslib_1.__exportStar(require_stream(), exports);
|
|
1721
|
-
tslib_1.__exportStar(require_token(), exports);
|
|
1722
|
-
tslib_1.__exportStar(require_transfer(), exports);
|
|
1723
|
-
tslib_1.__exportStar(require_util(), exports);
|
|
1724
|
-
tslib_1.__exportStar(require_waiter(), exports);
|
|
1725
|
-
}
|
|
1726
|
-
});
|
|
1727
|
-
|
|
1728
842
|
// src/credentials.ts
|
|
1729
843
|
var credentials_exports = {};
|
|
1730
844
|
__export(credentials_exports, {
|
|
@@ -1796,11 +910,10 @@ function useAWSClient(client, force = false) {
|
|
|
1796
910
|
Logger.debug("Created AWS client", client.name);
|
|
1797
911
|
return result;
|
|
1798
912
|
}
|
|
1799
|
-
var
|
|
913
|
+
var useAWSCredentialsProvider, useAWSCredentials, useSTSIdentity, useClientCache, CredentialProviderChain, useAWSProvider;
|
|
1800
914
|
var init_credentials = __esm({
|
|
1801
915
|
"src/credentials.ts"() {
|
|
1802
916
|
"use strict";
|
|
1803
|
-
import_types = __toESM(require_dist_cjs(), 1);
|
|
1804
917
|
init_context();
|
|
1805
918
|
init_logger();
|
|
1806
919
|
init_project();
|
|
@@ -5366,9 +4479,9 @@ var init_node = __esm({
|
|
|
5366
4479
|
init_handlers2();
|
|
5367
4480
|
init_workers();
|
|
5368
4481
|
init_context();
|
|
5369
|
-
init_error();
|
|
5370
4482
|
init_colors();
|
|
5371
4483
|
init_logger();
|
|
4484
|
+
init_fs();
|
|
5372
4485
|
useNodeHandler = Context.memo(async () => {
|
|
5373
4486
|
const workers = await useRuntimeWorkers();
|
|
5374
4487
|
const handlers = useRuntimeHandlers();
|
|
@@ -5453,6 +4566,26 @@ var init_node = __esm({
|
|
|
5453
4566
|
parsed.name + extension
|
|
5454
4567
|
);
|
|
5455
4568
|
const handler = path10.relative(input.out, target.replace(extension, parsed.ext)).split(path10.sep).join(path10.posix.sep);
|
|
4569
|
+
if (input.mode === "start") {
|
|
4570
|
+
const root = await findAbove(parsed.dir, "package.json");
|
|
4571
|
+
if (!root) {
|
|
4572
|
+
return {
|
|
4573
|
+
type: "error",
|
|
4574
|
+
errors: [
|
|
4575
|
+
`Could not find package.json for handler "${input.props.handler}"`
|
|
4576
|
+
]
|
|
4577
|
+
};
|
|
4578
|
+
}
|
|
4579
|
+
const dir = path10.join(root, "node_modules");
|
|
4580
|
+
try {
|
|
4581
|
+
await fs9.symlink(
|
|
4582
|
+
path10.resolve(dir),
|
|
4583
|
+
path10.resolve(path10.join(input.out, "node_modules")),
|
|
4584
|
+
"dir"
|
|
4585
|
+
);
|
|
4586
|
+
} catch {
|
|
4587
|
+
}
|
|
4588
|
+
}
|
|
5456
4589
|
const exists = rebuildCache[input.functionID];
|
|
5457
4590
|
if (exists) {
|
|
5458
4591
|
const result = await exists.ctx.rebuild();
|
|
@@ -5528,15 +4661,16 @@ var init_node = __esm({
|
|
|
5528
4661
|
);
|
|
5529
4662
|
})
|
|
5530
4663
|
);
|
|
5531
|
-
async function find2(dir, target2) {
|
|
5532
|
-
if (dir === "/")
|
|
5533
|
-
throw new VisibleError("Could not find a package.json file");
|
|
5534
|
-
if (await fs9.access(path10.join(dir, target2)).then(() => true).catch(() => false))
|
|
5535
|
-
return dir;
|
|
5536
|
-
return find2(path10.join(dir, ".."), target2);
|
|
5537
|
-
}
|
|
5538
4664
|
if (input.mode === "deploy" && installPackages) {
|
|
5539
|
-
const src = await
|
|
4665
|
+
const src = await findAbove(parsed.dir, "package.json");
|
|
4666
|
+
if (!src) {
|
|
4667
|
+
return {
|
|
4668
|
+
type: "error",
|
|
4669
|
+
errors: [
|
|
4670
|
+
`Could not find package.json for handler "${input.props.handler}"`
|
|
4671
|
+
]
|
|
4672
|
+
};
|
|
4673
|
+
}
|
|
5540
4674
|
const json = JSON.parse(
|
|
5541
4675
|
await fs9.readFile(path10.join(src, "package.json")).then((x) => x.toString())
|
|
5542
4676
|
);
|
|
@@ -5564,20 +4698,6 @@ var init_node = __esm({
|
|
|
5564
4698
|
});
|
|
5565
4699
|
});
|
|
5566
4700
|
}
|
|
5567
|
-
if (input.mode === "start") {
|
|
5568
|
-
const dir = path10.join(
|
|
5569
|
-
await find2(parsed.dir, "package.json"),
|
|
5570
|
-
"node_modules"
|
|
5571
|
-
);
|
|
5572
|
-
try {
|
|
5573
|
-
await fs9.symlink(
|
|
5574
|
-
path10.resolve(dir),
|
|
5575
|
-
path10.resolve(path10.join(input.out, "node_modules")),
|
|
5576
|
-
"dir"
|
|
5577
|
-
);
|
|
5578
|
-
} catch {
|
|
5579
|
-
}
|
|
5580
|
-
}
|
|
5581
4701
|
if (input.mode === "start") {
|
|
5582
4702
|
rebuildCache[input.functionID] = { ctx, result };
|
|
5583
4703
|
}
|
|
@@ -5809,7 +4929,12 @@ var init_container = __esm({
|
|
|
5809
4929
|
if (input.mode === "start") {
|
|
5810
4930
|
try {
|
|
5811
4931
|
const result = await execAsync(
|
|
5812
|
-
|
|
4932
|
+
[
|
|
4933
|
+
`docker build`,
|
|
4934
|
+
`-t sst-dev:${input.functionID}`,
|
|
4935
|
+
...input.props.container?.file ? [`-f ${input.props.container.file}`] : [],
|
|
4936
|
+
`.`
|
|
4937
|
+
].join(" "),
|
|
5813
4938
|
{
|
|
5814
4939
|
cwd: project,
|
|
5815
4940
|
env: {
|
|
@@ -5831,6 +4956,7 @@ var init_container = __esm({
|
|
|
5831
4956
|
[
|
|
5832
4957
|
`docker build`,
|
|
5833
4958
|
`-t sst-build:${input.functionID}`,
|
|
4959
|
+
...input.props.container?.file ? [`-f ${input.props.container.file}`] : [],
|
|
5834
4960
|
`--platform ${platform}`,
|
|
5835
4961
|
`.`
|
|
5836
4962
|
].join(" "),
|