@stacksjs/actions 0.70.16 → 0.70.18
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/dist/build.js +8 -8
- package/dist/{chunk-wn25qps4.js → chunk-2vba9ke6.js} +25 -34
- package/dist/{chunk-hd6fdt5s.js → chunk-38cnnp2b.js} +4 -6
- package/dist/{chunk-6xeh1279.js → chunk-76zhb40c.js} +6 -7
- package/dist/{chunk-bh25aaf7.js → chunk-7s5qcjkt.js} +9 -17
- package/dist/{chunk-gdzs9jf4.js → chunk-9exgwfkw.js} +4 -5
- package/dist/{chunk-hfkdpbh8.js → chunk-c0b89186.js} +8 -8
- package/dist/{chunk-y73a5ex0.js → chunk-dhnwmbca.js} +28 -29
- package/dist/{chunk-wvzpmd54.js → chunk-e7mp4xy5.js} +10 -13
- package/dist/{chunk-ad9b7jvj.js → chunk-f6a9g4qa.js} +4 -5
- package/dist/{chunk-jdqxwpvc.js → chunk-gtghjj5c.js} +79 -35
- package/dist/{chunk-kz10a3s9.js → chunk-ky5192ey.js} +82 -85
- package/dist/{chunk-8dsect0a.js → chunk-qkm8e752.js} +4 -5
- package/dist/{chunk-6xbhnbwy.js → chunk-shmtrj5e.js} +17 -21
- package/dist/{chunk-9menqd9a.js → chunk-t5em30ak.js} +16 -24
- package/dist/{chunk-cv02w7e2.js → chunk-v1m830st.js} +3 -3
- package/dist/{chunk-0crtxf8d.js → chunk-veja9rez.js} +156 -19
- package/dist/{chunk-whqcyjvm.js → chunk-xgpn959d.js} +13 -8
- package/dist/{chunk-b5g5w1hh.js → chunk-xt9exr2c.js} +5 -6
- package/dist/{chunk-f1cxwjkf.js → chunk-zsm2c35w.js} +5 -6
- package/dist/chunk-zzerxbrm.js +107 -0
- package/dist/database/seed.js +7 -7
- package/dist/generate/index.js +8 -8
- package/dist/index.js +8 -8
- package/dist/release.js +8 -8
- package/dist/upgrade.js +1 -1
- package/package.json +17 -17
- package/dist/chunk-2m04vhea.js +0 -145
|
@@ -2,22 +2,19 @@
|
|
|
2
2
|
import {
|
|
3
3
|
loadConfig,
|
|
4
4
|
parseUrl
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-7s5qcjkt.js";
|
|
6
6
|
import"./chunk-bf8bq8pc.js";
|
|
7
|
-
import"./chunk-saqpg5nd.js";
|
|
8
|
-
import {
|
|
9
|
-
require_dist_cjs
|
|
10
|
-
} from "./chunk-2m04vhea.js";
|
|
11
7
|
import {
|
|
12
|
-
|
|
13
|
-
|
|
8
|
+
CredentialsProviderError,
|
|
9
|
+
ProviderError
|
|
10
|
+
} from "./chunk-zzerxbrm.js";
|
|
11
|
+
import"./chunk-saqpg5nd.js";
|
|
12
|
+
import"./chunk-9v6qtbez.js";
|
|
14
13
|
|
|
15
14
|
// ../../../../node_modules/@smithy/credential-provider-imds/dist-es/fromContainerMetadata.js
|
|
16
|
-
var import_property_provider2 = __toESM(require_dist_cjs(), 1);
|
|
17
15
|
import { parse } from "node:url";
|
|
18
16
|
|
|
19
17
|
// ../../../../node_modules/@smithy/credential-provider-imds/dist-es/remoteProvider/httpRequest.js
|
|
20
|
-
var import_property_provider = __toESM(require_dist_cjs(), 1);
|
|
21
18
|
import { Buffer } from "node:buffer";
|
|
22
19
|
import { request } from "node:http";
|
|
23
20
|
function httpRequest(options) {
|
|
@@ -28,17 +25,17 @@ function httpRequest(options) {
|
|
|
28
25
|
hostname: options.hostname?.replace(/^\[(.+)\]$/, "$1")
|
|
29
26
|
});
|
|
30
27
|
req.on("error", (err) => {
|
|
31
|
-
reject(Object.assign(new
|
|
28
|
+
reject(Object.assign(new ProviderError("Unable to connect to instance metadata service"), err));
|
|
32
29
|
req.destroy();
|
|
33
30
|
});
|
|
34
31
|
req.on("timeout", () => {
|
|
35
|
-
reject(new
|
|
32
|
+
reject(new ProviderError("TimeoutError from instance metadata service"));
|
|
36
33
|
req.destroy();
|
|
37
34
|
});
|
|
38
35
|
req.on("response", (res) => {
|
|
39
36
|
const { statusCode = 400 } = res;
|
|
40
37
|
if (statusCode < 200 || 300 <= statusCode) {
|
|
41
|
-
reject(Object.assign(new
|
|
38
|
+
reject(Object.assign(new ProviderError("Error response received from instance metadata service"), { statusCode }));
|
|
42
39
|
req.destroy();
|
|
43
40
|
}
|
|
44
41
|
const chunks = [];
|
|
@@ -88,7 +85,7 @@ var fromContainerMetadata = (init = {}) => {
|
|
|
88
85
|
const requestOptions = await getCmdsUri({ logger: init.logger });
|
|
89
86
|
const credsResponse = JSON.parse(await requestFromEcsImds(timeout, requestOptions));
|
|
90
87
|
if (!isImdsCredentials(credsResponse)) {
|
|
91
|
-
throw new
|
|
88
|
+
throw new CredentialsProviderError("Invalid response received from instance metadata service.", {
|
|
92
89
|
logger: init.logger
|
|
93
90
|
});
|
|
94
91
|
}
|
|
@@ -127,13 +124,13 @@ var getCmdsUri = async ({ logger }) => {
|
|
|
127
124
|
if (process.env[ENV_CMDS_FULL_URI]) {
|
|
128
125
|
const parsed = parse(process.env[ENV_CMDS_FULL_URI]);
|
|
129
126
|
if (!parsed.hostname || !(parsed.hostname in GREENGRASS_HOSTS)) {
|
|
130
|
-
throw new
|
|
127
|
+
throw new CredentialsProviderError(`${parsed.hostname} is not a valid container metadata service hostname`, {
|
|
131
128
|
tryNextLink: false,
|
|
132
129
|
logger
|
|
133
130
|
});
|
|
134
131
|
}
|
|
135
132
|
if (!parsed.protocol || !(parsed.protocol in GREENGRASS_PROTOCOLS)) {
|
|
136
|
-
throw new
|
|
133
|
+
throw new CredentialsProviderError(`${parsed.protocol} is not a valid container metadata service protocol`, {
|
|
137
134
|
tryNextLink: false,
|
|
138
135
|
logger
|
|
139
136
|
});
|
|
@@ -143,18 +140,13 @@ var getCmdsUri = async ({ logger }) => {
|
|
|
143
140
|
port: parsed.port ? parseInt(parsed.port, 10) : undefined
|
|
144
141
|
};
|
|
145
142
|
}
|
|
146
|
-
throw new
|
|
143
|
+
throw new CredentialsProviderError("The container metadata credential provider cannot be used unless" + ` the ${ENV_CMDS_RELATIVE_URI} or ${ENV_CMDS_FULL_URI} environment` + " variable is set", {
|
|
147
144
|
tryNextLink: false,
|
|
148
145
|
logger
|
|
149
146
|
});
|
|
150
147
|
};
|
|
151
|
-
// ../../../../node_modules/@smithy/credential-provider-imds/dist-es/fromInstanceMetadata.js
|
|
152
|
-
var import_property_provider4 = __toESM(require_dist_cjs(), 1);
|
|
153
|
-
|
|
154
148
|
// ../../../../node_modules/@smithy/credential-provider-imds/dist-es/error/InstanceMetadataV1FallbackError.js
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
class InstanceMetadataV1FallbackError extends import_property_provider3.CredentialsProviderError {
|
|
149
|
+
class InstanceMetadataV1FallbackError extends CredentialsProviderError {
|
|
158
150
|
constructor(message, tryNextLink = true) {
|
|
159
151
|
super(message, tryNextLink);
|
|
160
152
|
this.tryNextLink = tryNextLink;
|
|
@@ -272,7 +264,7 @@ var getInstanceMetadataProvider = (init = {}) => {
|
|
|
272
264
|
const envValue = env[AWS_EC2_METADATA_V1_DISABLED];
|
|
273
265
|
fallbackBlockedFromProcessEnv = !!envValue && envValue !== "false";
|
|
274
266
|
if (envValue === undefined) {
|
|
275
|
-
throw new
|
|
267
|
+
throw new CredentialsProviderError(`${AWS_EC2_METADATA_V1_DISABLED} not set in env, checking config file next.`, { logger: init.logger });
|
|
276
268
|
}
|
|
277
269
|
return fallbackBlockedFromProcessEnv;
|
|
278
270
|
},
|
|
@@ -366,7 +358,7 @@ var getCredentialsFromProfile = async (profile, options, init) => {
|
|
|
366
358
|
path: IMDS_PATH + profile
|
|
367
359
|
})).toString());
|
|
368
360
|
if (!isImdsCredentials(credentialsResponse)) {
|
|
369
|
-
throw new
|
|
361
|
+
throw new CredentialsProviderError("Invalid response received from instance metadata service.", {
|
|
370
362
|
logger: init.logger
|
|
371
363
|
});
|
|
372
364
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
db
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-ky5192ey.js";
|
|
4
4
|
import {
|
|
5
5
|
customValidate,
|
|
6
6
|
isObjectNotEmpty,
|
|
@@ -319,8 +319,8 @@ class Router {
|
|
|
319
319
|
return this.routes;
|
|
320
320
|
}
|
|
321
321
|
async importRoutes() {
|
|
322
|
-
await import("./chunk-
|
|
323
|
-
await import("./chunk-
|
|
322
|
+
await import("./chunk-c0b89186.js");
|
|
323
|
+
await import("./chunk-xgpn959d.js");
|
|
324
324
|
}
|
|
325
325
|
async resolveCallback(callback) {
|
|
326
326
|
if (callback instanceof Promise) {
|
|
@@ -12,16 +12,13 @@ import {
|
|
|
12
12
|
import {
|
|
13
13
|
require_dist_cjs
|
|
14
14
|
} from "./chunk-saqpg5nd.js";
|
|
15
|
-
import {
|
|
16
|
-
require_dist_cjs as require_dist_cjs7
|
|
17
|
-
} from "./chunk-2m04vhea.js";
|
|
18
15
|
import {
|
|
19
16
|
__commonJS,
|
|
20
17
|
__require
|
|
21
18
|
} from "./chunk-9v6qtbez.js";
|
|
22
19
|
|
|
23
20
|
// ../../../../node_modules/@smithy/middleware-serde/dist-cjs/index.js
|
|
24
|
-
var
|
|
21
|
+
var require_dist_cjs7 = __commonJS((exports, module) => {
|
|
25
22
|
var __defProp = Object.defineProperty;
|
|
26
23
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
27
24
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -117,7 +114,7 @@ var require_dist_cjs8 = __commonJS((exports, module) => {
|
|
|
117
114
|
});
|
|
118
115
|
|
|
119
116
|
// ../../../../node_modules/@smithy/util-middleware/dist-cjs/index.js
|
|
120
|
-
var
|
|
117
|
+
var require_dist_cjs8 = __commonJS((exports, module) => {
|
|
121
118
|
var __defProp = Object.defineProperty;
|
|
122
119
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
123
120
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -153,7 +150,7 @@ var require_dist_cjs9 = __commonJS((exports, module) => {
|
|
|
153
150
|
});
|
|
154
151
|
|
|
155
152
|
// ../../../../node_modules/@smithy/core/dist-cjs/index.js
|
|
156
|
-
var
|
|
153
|
+
var require_dist_cjs9 = __commonJS((exports, module) => {
|
|
157
154
|
var __defProp = Object.defineProperty;
|
|
158
155
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
159
156
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -200,7 +197,7 @@ var require_dist_cjs10 = __commonJS((exports, module) => {
|
|
|
200
197
|
module.exports = __toCommonJS(src_exports);
|
|
201
198
|
var import_types = require_dist_cjs();
|
|
202
199
|
var getSmithyContext = /* @__PURE__ */ __name((context) => context[import_types.SMITHY_CONTEXT_KEY] || (context[import_types.SMITHY_CONTEXT_KEY] = {}), "getSmithyContext");
|
|
203
|
-
var import_util_middleware =
|
|
200
|
+
var import_util_middleware = require_dist_cjs8();
|
|
204
201
|
function convertHttpAuthSchemesToMap(httpAuthSchemes) {
|
|
205
202
|
const map = /* @__PURE__ */ new Map;
|
|
206
203
|
for (const scheme of httpAuthSchemes) {
|
|
@@ -260,7 +257,7 @@ var require_dist_cjs10 = __commonJS((exports, module) => {
|
|
|
260
257
|
}), httpAuthSchemeEndpointRuleSetMiddlewareOptions);
|
|
261
258
|
}
|
|
262
259
|
}), "getHttpAuthSchemeEndpointRuleSetPlugin");
|
|
263
|
-
var import_middleware_serde =
|
|
260
|
+
var import_middleware_serde = require_dist_cjs7();
|
|
264
261
|
var httpAuthSchemeMiddlewareOptions = {
|
|
265
262
|
step: "serialize",
|
|
266
263
|
tags: ["HTTP_AUTH_SCHEME"],
|
|
@@ -499,7 +496,7 @@ var require_dist_cjs10 = __commonJS((exports, module) => {
|
|
|
499
496
|
});
|
|
500
497
|
|
|
501
498
|
// ../../../../node_modules/@smithy/middleware-stack/dist-cjs/index.js
|
|
502
|
-
var
|
|
499
|
+
var require_dist_cjs10 = __commonJS((exports, module) => {
|
|
503
500
|
var __defProp = Object.defineProperty;
|
|
504
501
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
505
502
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -789,7 +786,7 @@ var require_dist_cjs11 = __commonJS((exports, module) => {
|
|
|
789
786
|
});
|
|
790
787
|
|
|
791
788
|
// ../../../../node_modules/@smithy/smithy-client/dist-cjs/index.js
|
|
792
|
-
var
|
|
789
|
+
var require_dist_cjs11 = __commonJS((exports, module) => {
|
|
793
790
|
var __defProp = Object.defineProperty;
|
|
794
791
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
795
792
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -873,7 +870,7 @@ var require_dist_cjs12 = __commonJS((exports, module) => {
|
|
|
873
870
|
withBaseException: () => withBaseException
|
|
874
871
|
});
|
|
875
872
|
module.exports = __toCommonJS(src_exports);
|
|
876
|
-
var import_middleware_stack =
|
|
873
|
+
var import_middleware_stack = require_dist_cjs10();
|
|
877
874
|
var Client = class {
|
|
878
875
|
constructor(config) {
|
|
879
876
|
this.config = config;
|
|
@@ -2470,6 +2467,146 @@ var require_tslib = __commonJS((exports, module) => {
|
|
|
2470
2467
|
});
|
|
2471
2468
|
});
|
|
2472
2469
|
|
|
2470
|
+
// ../../../../node_modules/@smithy/property-provider/dist-cjs/index.js
|
|
2471
|
+
var require_dist_cjs12 = __commonJS((exports, module) => {
|
|
2472
|
+
var __defProp = Object.defineProperty;
|
|
2473
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
2474
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
2475
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
2476
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
2477
|
+
var __export = (target, all) => {
|
|
2478
|
+
for (var name in all)
|
|
2479
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
2480
|
+
};
|
|
2481
|
+
var __copyProps = (to, from, except, desc) => {
|
|
2482
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
2483
|
+
for (let key of __getOwnPropNames(from))
|
|
2484
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
2485
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
2486
|
+
}
|
|
2487
|
+
return to;
|
|
2488
|
+
};
|
|
2489
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
2490
|
+
var src_exports = {};
|
|
2491
|
+
__export(src_exports, {
|
|
2492
|
+
CredentialsProviderError: () => CredentialsProviderError,
|
|
2493
|
+
ProviderError: () => ProviderError,
|
|
2494
|
+
TokenProviderError: () => TokenProviderError,
|
|
2495
|
+
chain: () => chain,
|
|
2496
|
+
fromStatic: () => fromStatic,
|
|
2497
|
+
memoize: () => memoize
|
|
2498
|
+
});
|
|
2499
|
+
module.exports = __toCommonJS(src_exports);
|
|
2500
|
+
var ProviderError = class _ProviderError extends Error {
|
|
2501
|
+
constructor(message, options = true) {
|
|
2502
|
+
let logger;
|
|
2503
|
+
let tryNextLink = true;
|
|
2504
|
+
if (typeof options === "boolean") {
|
|
2505
|
+
logger = undefined;
|
|
2506
|
+
tryNextLink = options;
|
|
2507
|
+
} else if (options != null && typeof options === "object") {
|
|
2508
|
+
logger = options.logger;
|
|
2509
|
+
tryNextLink = options.tryNextLink ?? true;
|
|
2510
|
+
}
|
|
2511
|
+
super(message);
|
|
2512
|
+
this.name = "ProviderError";
|
|
2513
|
+
this.tryNextLink = tryNextLink;
|
|
2514
|
+
Object.setPrototypeOf(this, _ProviderError.prototype);
|
|
2515
|
+
logger?.debug?.(`@smithy/property-provider ${tryNextLink ? "->" : "(!)"} ${message}`);
|
|
2516
|
+
}
|
|
2517
|
+
static {
|
|
2518
|
+
__name(this, "ProviderError");
|
|
2519
|
+
}
|
|
2520
|
+
static from(error, options = true) {
|
|
2521
|
+
return Object.assign(new this(error.message, options), error);
|
|
2522
|
+
}
|
|
2523
|
+
};
|
|
2524
|
+
var CredentialsProviderError = class _CredentialsProviderError extends ProviderError {
|
|
2525
|
+
constructor(message, options = true) {
|
|
2526
|
+
super(message, options);
|
|
2527
|
+
this.name = "CredentialsProviderError";
|
|
2528
|
+
Object.setPrototypeOf(this, _CredentialsProviderError.prototype);
|
|
2529
|
+
}
|
|
2530
|
+
static {
|
|
2531
|
+
__name(this, "CredentialsProviderError");
|
|
2532
|
+
}
|
|
2533
|
+
};
|
|
2534
|
+
var TokenProviderError = class _TokenProviderError extends ProviderError {
|
|
2535
|
+
constructor(message, options = true) {
|
|
2536
|
+
super(message, options);
|
|
2537
|
+
this.name = "TokenProviderError";
|
|
2538
|
+
Object.setPrototypeOf(this, _TokenProviderError.prototype);
|
|
2539
|
+
}
|
|
2540
|
+
static {
|
|
2541
|
+
__name(this, "TokenProviderError");
|
|
2542
|
+
}
|
|
2543
|
+
};
|
|
2544
|
+
var chain = /* @__PURE__ */ __name((...providers) => async () => {
|
|
2545
|
+
if (providers.length === 0) {
|
|
2546
|
+
throw new ProviderError("No providers in chain");
|
|
2547
|
+
}
|
|
2548
|
+
let lastProviderError;
|
|
2549
|
+
for (const provider of providers) {
|
|
2550
|
+
try {
|
|
2551
|
+
const credentials = await provider();
|
|
2552
|
+
return credentials;
|
|
2553
|
+
} catch (err) {
|
|
2554
|
+
lastProviderError = err;
|
|
2555
|
+
if (err?.tryNextLink) {
|
|
2556
|
+
continue;
|
|
2557
|
+
}
|
|
2558
|
+
throw err;
|
|
2559
|
+
}
|
|
2560
|
+
}
|
|
2561
|
+
throw lastProviderError;
|
|
2562
|
+
}, "chain");
|
|
2563
|
+
var fromStatic = /* @__PURE__ */ __name((staticValue) => () => Promise.resolve(staticValue), "fromStatic");
|
|
2564
|
+
var memoize = /* @__PURE__ */ __name((provider, isExpired, requiresRefresh) => {
|
|
2565
|
+
let resolved;
|
|
2566
|
+
let pending;
|
|
2567
|
+
let hasResult;
|
|
2568
|
+
let isConstant = false;
|
|
2569
|
+
const coalesceProvider = /* @__PURE__ */ __name(async () => {
|
|
2570
|
+
if (!pending) {
|
|
2571
|
+
pending = provider();
|
|
2572
|
+
}
|
|
2573
|
+
try {
|
|
2574
|
+
resolved = await pending;
|
|
2575
|
+
hasResult = true;
|
|
2576
|
+
isConstant = false;
|
|
2577
|
+
} finally {
|
|
2578
|
+
pending = undefined;
|
|
2579
|
+
}
|
|
2580
|
+
return resolved;
|
|
2581
|
+
}, "coalesceProvider");
|
|
2582
|
+
if (isExpired === undefined) {
|
|
2583
|
+
return async (options) => {
|
|
2584
|
+
if (!hasResult || options?.forceRefresh) {
|
|
2585
|
+
resolved = await coalesceProvider();
|
|
2586
|
+
}
|
|
2587
|
+
return resolved;
|
|
2588
|
+
};
|
|
2589
|
+
}
|
|
2590
|
+
return async (options) => {
|
|
2591
|
+
if (!hasResult || options?.forceRefresh) {
|
|
2592
|
+
resolved = await coalesceProvider();
|
|
2593
|
+
}
|
|
2594
|
+
if (isConstant) {
|
|
2595
|
+
return resolved;
|
|
2596
|
+
}
|
|
2597
|
+
if (requiresRefresh && !requiresRefresh(resolved)) {
|
|
2598
|
+
isConstant = true;
|
|
2599
|
+
return resolved;
|
|
2600
|
+
}
|
|
2601
|
+
if (isExpired(resolved)) {
|
|
2602
|
+
await coalesceProvider();
|
|
2603
|
+
return resolved;
|
|
2604
|
+
}
|
|
2605
|
+
return resolved;
|
|
2606
|
+
};
|
|
2607
|
+
}, "memoize");
|
|
2608
|
+
});
|
|
2609
|
+
|
|
2473
2610
|
// ../../../../node_modules/@smithy/signature-v4/dist-cjs/index.js
|
|
2474
2611
|
var require_dist_cjs13 = __commonJS((exports, module) => {
|
|
2475
2612
|
var __defProp = Object.defineProperty;
|
|
@@ -2503,7 +2640,7 @@ var require_dist_cjs13 = __commonJS((exports, module) => {
|
|
|
2503
2640
|
prepareRequest: () => prepareRequest
|
|
2504
2641
|
});
|
|
2505
2642
|
module.exports = __toCommonJS(src_exports);
|
|
2506
|
-
var import_util_middleware =
|
|
2643
|
+
var import_util_middleware = require_dist_cjs8();
|
|
2507
2644
|
var import_util_utf84 = require_dist_cjs4();
|
|
2508
2645
|
var ALGORITHM_QUERY_PARAM = "X-Amz-Algorithm";
|
|
2509
2646
|
var CREDENTIAL_QUERY_PARAM = "X-Amz-Credential";
|
|
@@ -3126,8 +3263,8 @@ var require_httpAuthSchemes = __commonJS((exports, module) => {
|
|
|
3126
3263
|
return signedRequest;
|
|
3127
3264
|
}
|
|
3128
3265
|
};
|
|
3129
|
-
var import_core =
|
|
3130
|
-
var import_property_provider =
|
|
3266
|
+
var import_core = require_dist_cjs9();
|
|
3267
|
+
var import_property_provider = require_dist_cjs12();
|
|
3131
3268
|
var resolveAwsSdkSigV4AConfig = /* @__PURE__ */ __name((config) => {
|
|
3132
3269
|
config.sigv4aSigningRegionSet = (0, import_core.normalizeProvider)(config.sigv4aSigningRegionSet);
|
|
3133
3270
|
return config;
|
|
@@ -3152,7 +3289,7 @@ var require_httpAuthSchemes = __commonJS((exports, module) => {
|
|
|
3152
3289
|
default: undefined
|
|
3153
3290
|
};
|
|
3154
3291
|
var import_client = require_client();
|
|
3155
|
-
var import_core2 =
|
|
3292
|
+
var import_core2 = require_dist_cjs9();
|
|
3156
3293
|
var import_signature_v4 = require_dist_cjs13();
|
|
3157
3294
|
var resolveAwsSdkSigV4Config = /* @__PURE__ */ __name((config) => {
|
|
3158
3295
|
let inputCredentials = config.credentials;
|
|
@@ -5025,7 +5162,7 @@ var require_protocols2 = __commonJS((exports, module) => {
|
|
|
5025
5162
|
}
|
|
5026
5163
|
return val2;
|
|
5027
5164
|
}, "_toNum");
|
|
5028
|
-
var import_smithy_client =
|
|
5165
|
+
var import_smithy_client = require_dist_cjs11();
|
|
5029
5166
|
var awsExpectUnion = /* @__PURE__ */ __name((value) => {
|
|
5030
5167
|
if (value == null) {
|
|
5031
5168
|
return;
|
|
@@ -5035,7 +5172,7 @@ var require_protocols2 = __commonJS((exports, module) => {
|
|
|
5035
5172
|
}
|
|
5036
5173
|
return (0, import_smithy_client.expectUnion)(value);
|
|
5037
5174
|
}, "awsExpectUnion");
|
|
5038
|
-
var import_smithy_client2 =
|
|
5175
|
+
var import_smithy_client2 = require_dist_cjs11();
|
|
5039
5176
|
var collectBodyString = /* @__PURE__ */ __name((streamBody, context) => (0, import_smithy_client2.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body)), "collectBodyString");
|
|
5040
5177
|
var parseJsonBody = /* @__PURE__ */ __name((streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
5041
5178
|
if (encoded.length) {
|
|
@@ -5086,7 +5223,7 @@ var require_protocols2 = __commonJS((exports, module) => {
|
|
|
5086
5223
|
return sanitizeErrorCode(data["__type"]);
|
|
5087
5224
|
}
|
|
5088
5225
|
}, "loadRestJsonErrorCode");
|
|
5089
|
-
var import_smithy_client3 =
|
|
5226
|
+
var import_smithy_client3 = require_dist_cjs11();
|
|
5090
5227
|
var import_fast_xml_parser = require_fxp();
|
|
5091
5228
|
var parseXmlBody = /* @__PURE__ */ __name((streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
5092
5229
|
if (encoded.length) {
|
|
@@ -5624,4 +5761,4 @@ var require_dist = __commonJS((exports) => {
|
|
|
5624
5761
|
}
|
|
5625
5762
|
});
|
|
5626
5763
|
|
|
5627
|
-
export {
|
|
5764
|
+
export { require_dist_cjs8 as require_dist_cjs, require_dist_cjs7 as require_dist_cjs1, require_dist_cjs9 as require_dist_cjs2, require_tslib, require_dist_cjs12 as require_dist_cjs3, require_dist_cjs11 as require_dist_cjs4, require_dist_cjs14 as require_dist_cjs5, require_dist };
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
route
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import"./chunk-
|
|
4
|
+
} from "./chunk-v1m830st.js";
|
|
5
|
+
import"./chunk-ky5192ey.js";
|
|
6
6
|
import"./chunk-mdj7x1vs.js";
|
|
7
7
|
import"./chunk-p0c688mg.js";
|
|
8
|
-
import"./chunk-
|
|
8
|
+
import"./chunk-qkm8e752.js";
|
|
9
9
|
import"./chunk-a13x0e43.js";
|
|
10
10
|
import"./chunk-mdqphqep.js";
|
|
11
11
|
import"./chunk-qhh0v93n.js";
|
|
12
|
-
import"./chunk-
|
|
13
|
-
import"./chunk-
|
|
12
|
+
import"./chunk-gtghjj5c.js";
|
|
13
|
+
import"./chunk-7s5qcjkt.js";
|
|
14
14
|
import"./chunk-bf8bq8pc.js";
|
|
15
|
-
import"./chunk-
|
|
16
|
-
import"./chunk-
|
|
15
|
+
import"./chunk-xt9exr2c.js";
|
|
16
|
+
import"./chunk-zzerxbrm.js";
|
|
17
|
+
import"./chunk-veja9rez.js";
|
|
17
18
|
import"./chunk-a7k3cdby.js";
|
|
18
19
|
import"./chunk-frw3va9v.js";
|
|
19
20
|
import"./chunk-saqpg5nd.js";
|
|
20
|
-
import"./chunk-2m04vhea.js";
|
|
21
21
|
import"./chunk-2dvnt46s.js";
|
|
22
22
|
import"./chunk-w6fdq4hk.js";
|
|
23
23
|
import"./chunk-wkwtsvym.js";
|
|
@@ -74,6 +74,11 @@ route.post("license-keys", "LicenseKeyStoreOrmAction");
|
|
|
74
74
|
route.get("license-keys/{id}", "LicenseKeyShowOrmAction");
|
|
75
75
|
route.patch("license-keys/{id}", "LicenseKeyUpdateOrmAction");
|
|
76
76
|
route.delete("license-keys/{id}", "LicenseKeyDestroyOrmAction");
|
|
77
|
+
route.get("waitlist-restaurants", "WaitlistRestaurantIndexOrmAction");
|
|
78
|
+
route.post("waitlist-restaurants", "WaitlistRestaurantStoreOrmAction");
|
|
79
|
+
route.get("waitlist-restaurants/{id}", "WaitlistRestaurantShowOrmAction");
|
|
80
|
+
route.patch("waitlist-restaurants/{id}", "WaitlistRestaurantUpdateOrmAction");
|
|
81
|
+
route.delete("waitlist-restaurants/{id}", "WaitlistRestaurantDestroyOrmAction");
|
|
77
82
|
route.get("product-reviews", "ReviewIndexOrmAction");
|
|
78
83
|
route.post("product-reviews", "ReviewStoreOrmAction");
|
|
79
84
|
route.get("product-reviews/{id}", "ReviewShowOrmAction");
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
+
require_dist_cjs5 as require_dist_cjs2,
|
|
2
3
|
require_protocols
|
|
3
4
|
} from "./chunk-a7k3cdby.js";
|
|
4
5
|
import {
|
|
@@ -1050,23 +1051,21 @@ class HttpResponse {
|
|
|
1050
1051
|
return typeof resp.statusCode === "number" && typeof resp.headers === "object";
|
|
1051
1052
|
}
|
|
1052
1053
|
}
|
|
1053
|
-
// ../../../../node_modules/@smithy/util-uri-escape/dist-es/escape-uri.js
|
|
1054
|
-
var escapeUri = (uri) => encodeURIComponent(uri).replace(/[!'()*]/g, hexEncode);
|
|
1055
|
-
var hexEncode = (c) => `%${c.charCodeAt(0).toString(16).toUpperCase()}`;
|
|
1056
1054
|
// ../../../../node_modules/@smithy/querystring-builder/dist-es/index.js
|
|
1055
|
+
var import_util_uri_escape = __toESM(require_dist_cjs2(), 1);
|
|
1057
1056
|
function buildQueryString(query) {
|
|
1058
1057
|
const parts = [];
|
|
1059
1058
|
for (let key of Object.keys(query).sort()) {
|
|
1060
1059
|
const value = query[key];
|
|
1061
|
-
key = escapeUri(key);
|
|
1060
|
+
key = import_util_uri_escape.escapeUri(key);
|
|
1062
1061
|
if (Array.isArray(value)) {
|
|
1063
1062
|
for (let i = 0, iLen = value.length;i < iLen; i++) {
|
|
1064
|
-
parts.push(`${key}=${escapeUri(value[i])}`);
|
|
1063
|
+
parts.push(`${key}=${import_util_uri_escape.escapeUri(value[i])}`);
|
|
1065
1064
|
}
|
|
1066
1065
|
} else {
|
|
1067
1066
|
let qsEntry = key;
|
|
1068
1067
|
if (value || typeof value === "string") {
|
|
1069
|
-
qsEntry += `=${escapeUri(value)}`;
|
|
1068
|
+
qsEntry += `=${import_util_uri_escape.escapeUri(value)}`;
|
|
1070
1069
|
}
|
|
1071
1070
|
parts.push(qsEntry);
|
|
1072
1071
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
|
+
import {
|
|
3
|
+
CredentialsProviderError
|
|
4
|
+
} from "./chunk-zzerxbrm.js";
|
|
2
5
|
import {
|
|
3
6
|
require_client
|
|
4
7
|
} from "./chunk-frw3va9v.js";
|
|
5
|
-
import {
|
|
6
|
-
require_dist_cjs
|
|
7
|
-
} from "./chunk-2m04vhea.js";
|
|
8
8
|
import {
|
|
9
9
|
__require,
|
|
10
10
|
__toESM
|
|
@@ -12,7 +12,6 @@ import {
|
|
|
12
12
|
|
|
13
13
|
// ../../../../node_modules/@aws-sdk/credential-provider-web-identity/dist-es/fromTokenFile.js
|
|
14
14
|
var import_client = __toESM(require_client(), 1);
|
|
15
|
-
var import_property_provider = __toESM(require_dist_cjs(), 1);
|
|
16
15
|
import { readFileSync } from "node:fs";
|
|
17
16
|
|
|
18
17
|
// ../../../../node_modules/@aws-sdk/credential-provider-web-identity/dist-es/fromWebToken.js
|
|
@@ -21,7 +20,7 @@ var fromWebToken = (init) => async (awsIdentityProperties) => {
|
|
|
21
20
|
const { roleArn, roleSessionName, webIdentityToken, providerId, policyArns, policy, durationSeconds } = init;
|
|
22
21
|
let { roleAssumerWithWebIdentity } = init;
|
|
23
22
|
if (!roleAssumerWithWebIdentity) {
|
|
24
|
-
const { getDefaultRoleAssumerWithWebIdentity } = await import("./chunk-
|
|
23
|
+
const { getDefaultRoleAssumerWithWebIdentity } = await import("./chunk-9exgwfkw.js");
|
|
25
24
|
roleAssumerWithWebIdentity = getDefaultRoleAssumerWithWebIdentity({
|
|
26
25
|
...init.clientConfig,
|
|
27
26
|
credentialProviderLogger: init.logger,
|
|
@@ -52,7 +51,7 @@ var fromTokenFile = (init = {}) => async () => {
|
|
|
52
51
|
const roleArn = init?.roleArn ?? process.env[ENV_ROLE_ARN];
|
|
53
52
|
const roleSessionName = init?.roleSessionName ?? process.env[ENV_ROLE_SESSION_NAME];
|
|
54
53
|
if (!webIdentityTokenFile || !roleArn) {
|
|
55
|
-
throw new
|
|
54
|
+
throw new CredentialsProviderError("Web identity configuration not specified", {
|
|
56
55
|
logger: init.logger
|
|
57
56
|
});
|
|
58
57
|
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/ProviderError.js
|
|
2
|
+
class ProviderError extends Error {
|
|
3
|
+
constructor(message, options = true) {
|
|
4
|
+
let logger;
|
|
5
|
+
let tryNextLink = true;
|
|
6
|
+
if (typeof options === "boolean") {
|
|
7
|
+
logger = undefined;
|
|
8
|
+
tryNextLink = options;
|
|
9
|
+
} else if (options != null && typeof options === "object") {
|
|
10
|
+
logger = options.logger;
|
|
11
|
+
tryNextLink = options.tryNextLink ?? true;
|
|
12
|
+
}
|
|
13
|
+
super(message);
|
|
14
|
+
this.name = "ProviderError";
|
|
15
|
+
this.tryNextLink = tryNextLink;
|
|
16
|
+
Object.setPrototypeOf(this, ProviderError.prototype);
|
|
17
|
+
logger?.debug?.(`@smithy/property-provider ${tryNextLink ? "->" : "(!)"} ${message}`);
|
|
18
|
+
}
|
|
19
|
+
static from(error, options = true) {
|
|
20
|
+
return Object.assign(new this(error.message, options), error);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/CredentialsProviderError.js
|
|
25
|
+
class CredentialsProviderError extends ProviderError {
|
|
26
|
+
constructor(message, options = true) {
|
|
27
|
+
super(message, options);
|
|
28
|
+
this.name = "CredentialsProviderError";
|
|
29
|
+
Object.setPrototypeOf(this, CredentialsProviderError.prototype);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/TokenProviderError.js
|
|
33
|
+
class TokenProviderError extends ProviderError {
|
|
34
|
+
constructor(message, options = true) {
|
|
35
|
+
super(message, options);
|
|
36
|
+
this.name = "TokenProviderError";
|
|
37
|
+
Object.setPrototypeOf(this, TokenProviderError.prototype);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/chain.js
|
|
41
|
+
var chain = (...providers) => async () => {
|
|
42
|
+
if (providers.length === 0) {
|
|
43
|
+
throw new ProviderError("No providers in chain");
|
|
44
|
+
}
|
|
45
|
+
let lastProviderError;
|
|
46
|
+
for (const provider of providers) {
|
|
47
|
+
try {
|
|
48
|
+
const credentials = await provider();
|
|
49
|
+
return credentials;
|
|
50
|
+
} catch (err) {
|
|
51
|
+
lastProviderError = err;
|
|
52
|
+
if (err?.tryNextLink) {
|
|
53
|
+
continue;
|
|
54
|
+
}
|
|
55
|
+
throw err;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
throw lastProviderError;
|
|
59
|
+
};
|
|
60
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/fromStatic.js
|
|
61
|
+
var fromStatic = (staticValue) => () => Promise.resolve(staticValue);
|
|
62
|
+
// ../../../../node_modules/@smithy/property-provider/dist-es/memoize.js
|
|
63
|
+
var memoize = (provider, isExpired, requiresRefresh) => {
|
|
64
|
+
let resolved;
|
|
65
|
+
let pending;
|
|
66
|
+
let hasResult;
|
|
67
|
+
let isConstant = false;
|
|
68
|
+
const coalesceProvider = async () => {
|
|
69
|
+
if (!pending) {
|
|
70
|
+
pending = provider();
|
|
71
|
+
}
|
|
72
|
+
try {
|
|
73
|
+
resolved = await pending;
|
|
74
|
+
hasResult = true;
|
|
75
|
+
isConstant = false;
|
|
76
|
+
} finally {
|
|
77
|
+
pending = undefined;
|
|
78
|
+
}
|
|
79
|
+
return resolved;
|
|
80
|
+
};
|
|
81
|
+
if (isExpired === undefined) {
|
|
82
|
+
return async (options) => {
|
|
83
|
+
if (!hasResult || options?.forceRefresh) {
|
|
84
|
+
resolved = await coalesceProvider();
|
|
85
|
+
}
|
|
86
|
+
return resolved;
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
return async (options) => {
|
|
90
|
+
if (!hasResult || options?.forceRefresh) {
|
|
91
|
+
resolved = await coalesceProvider();
|
|
92
|
+
}
|
|
93
|
+
if (isConstant) {
|
|
94
|
+
return resolved;
|
|
95
|
+
}
|
|
96
|
+
if (requiresRefresh && !requiresRefresh(resolved)) {
|
|
97
|
+
isConstant = true;
|
|
98
|
+
return resolved;
|
|
99
|
+
}
|
|
100
|
+
if (isExpired(resolved)) {
|
|
101
|
+
await coalesceProvider();
|
|
102
|
+
return resolved;
|
|
103
|
+
}
|
|
104
|
+
return resolved;
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
export { ProviderError, CredentialsProviderError, TokenProviderError, chain, fromStatic, memoize };
|
package/dist/database/seed.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
seed
|
|
4
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-ky5192ey.js";
|
|
5
5
|
import"../chunk-mdj7x1vs.js";
|
|
6
6
|
import"../chunk-p0c688mg.js";
|
|
7
|
-
import"../chunk-
|
|
7
|
+
import"../chunk-qkm8e752.js";
|
|
8
8
|
import"../chunk-a13x0e43.js";
|
|
9
9
|
import"../chunk-mdqphqep.js";
|
|
10
10
|
import"../chunk-qhh0v93n.js";
|
|
11
|
-
import"../chunk-
|
|
12
|
-
import"../chunk-
|
|
11
|
+
import"../chunk-gtghjj5c.js";
|
|
12
|
+
import"../chunk-7s5qcjkt.js";
|
|
13
13
|
import"../chunk-bf8bq8pc.js";
|
|
14
|
-
import"../chunk-
|
|
15
|
-
import"../chunk-
|
|
14
|
+
import"../chunk-xt9exr2c.js";
|
|
15
|
+
import"../chunk-zzerxbrm.js";
|
|
16
|
+
import"../chunk-veja9rez.js";
|
|
16
17
|
import"../chunk-a7k3cdby.js";
|
|
17
18
|
import"../chunk-frw3va9v.js";
|
|
18
19
|
import"../chunk-saqpg5nd.js";
|
|
19
|
-
import"../chunk-2m04vhea.js";
|
|
20
20
|
import"../chunk-2dvnt46s.js";
|
|
21
21
|
import"../chunk-w6fdq4hk.js";
|
|
22
22
|
import"../chunk-wkwtsvym.js";
|