@awsless/awsless 0.0.604 → 0.0.606

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/bin.js CHANGED
@@ -4087,10 +4087,10 @@ var functionFeature = defineFeature({
4087
4087
  actions: [
4088
4088
  // Allow all lambda's to invoke any lambda inside your app.
4089
4089
  "lambda:InvokeFunction",
4090
- "lambda:InvokeAsync",
4090
+ "lambda:InvokeAsync"
4091
4091
  // Allow listing and getting lambda info.
4092
- "lambda:ListFunctions",
4093
- "lambda:GetFunction"
4092
+ // 'lambda:ListFunctions',
4093
+ // 'lambda:GetFunction',
4094
4094
  ],
4095
4095
  resources: [`arn:aws:lambda:*:*:function:${ctx.appConfig.name}--*`]
4096
4096
  });
@@ -6159,7 +6159,7 @@ var layerFeature = defineFeature({
6159
6159
  },
6160
6160
  {
6161
6161
  dependsOn: [zip],
6162
- replaceOnChanges: ["sourceCodeHash"]
6162
+ replaceOnChanges: ["sourceCodeHash", "s3ObjectVersion"]
6163
6163
  }
6164
6164
  );
6165
6165
  ctx.shared.add("layer", "arn", id, layer.arn);
@@ -6200,20 +6200,29 @@ var imageFeature = defineFeature({
6200
6200
  source: path,
6201
6201
  sourceHash: $hash(path)
6202
6202
  });
6203
- const layer = new aws24.lambda.LayerVersion(group, "layer", {
6204
- layerName: layerId,
6205
- description: "sharp-arm.zip for the awsless image feature.",
6206
- compatibleArchitectures: ["arm64"],
6207
- s3Bucket: zipFile.bucket,
6208
- s3ObjectVersion: zipFile.versionId,
6209
- s3Key: zipFile.key.pipe((name) => {
6210
- if (name.startsWith("/")) {
6211
- return name.substring(1);
6212
- }
6213
- return name;
6214
- }),
6215
- sourceCodeHash: $hash(path)
6216
- });
6203
+ const layer = new aws24.lambda.LayerVersion(
6204
+ group,
6205
+ "layer",
6206
+ {
6207
+ layerName: layerId,
6208
+ description: "sharp-arm.zip for the awsless image feature.",
6209
+ compatibleArchitectures: ["arm64"],
6210
+ s3Bucket: zipFile.bucket,
6211
+ s3ObjectVersion: zipFile.versionId,
6212
+ s3Key: zipFile.key.pipe((name) => {
6213
+ if (name.startsWith("/")) {
6214
+ return name.substring(1);
6215
+ }
6216
+ return name;
6217
+ }),
6218
+ sourceCodeHash: $hash(path),
6219
+ skipDestroy: true
6220
+ },
6221
+ {
6222
+ dependsOn: [zipFile],
6223
+ replaceOnChanges: ["sourceCodeHash", "s3ObjectVersion"]
6224
+ }
6225
+ );
6217
6226
  ctx.shared.add("layer", "arn", layerId, layer.arn);
6218
6227
  },
6219
6228
  onStack(ctx) {
@@ -9479,13 +9488,12 @@ var auth = (program2) => {
9479
9488
  // src/cli/command/bind.ts
9480
9489
  import { log as log22 } from "@awsless/clui";
9481
9490
  import { constantCase as constantCase15 } from "change-case";
9482
- import { spawn } from "child_process";
9483
9491
  var bind = (program2) => {
9484
9492
  program2.command("bind").argument("[command...]", "The command to execute").option("--config <string...>", "List of config values that will be accessable", (v) => v.split(",")).description(`Bind your site environment variables to a command`).action(async (commands9 = [], opts) => {
9485
9493
  await layout("bind", async ({ appConfig, stackConfigs }) => {
9486
9494
  const region = appConfig.region;
9487
9495
  const profile = appConfig.profile;
9488
- const credentials = await getCredentials(appConfig.profile);
9496
+ const credentials = await getCredentials(profile);
9489
9497
  const accountId = await getAccountId(credentials, region);
9490
9498
  const { app, binds } = createApp({ appConfig, stackConfigs, accountId });
9491
9499
  const { workspace } = await createWorkSpace({
@@ -9516,7 +9524,8 @@ var bind = (program2) => {
9516
9524
  }
9517
9525
  const command = commands9.join(" ");
9518
9526
  const freshCred = await credentials();
9519
- spawn(command, {
9527
+ console.log("");
9528
+ const instance = Bun.spawn([command], {
9520
9529
  env: {
9521
9530
  // Pass the process env vars
9522
9531
  ...process.env,
@@ -9534,9 +9543,11 @@ var bind = (program2) => {
9534
9543
  AWS_SECRET_ACCESS_KEY: freshCred.secretAccessKey,
9535
9544
  AWS_SESSION_TOKEN: freshCred.sessionToken
9536
9545
  },
9537
- stdio: "inherit",
9538
- shell: true
9546
+ stdout: "inherit",
9547
+ stderr: "inherit"
9539
9548
  });
9549
+ await instance.exited;
9550
+ process.exit(0);
9540
9551
  return;
9541
9552
  });
9542
9553
  });
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awsless/awsless",
3
- "version": "0.0.604",
3
+ "version": "0.0.606",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -33,23 +33,23 @@
33
33
  ]
34
34
  },
35
35
  "peerDependencies": {
36
- "@awsless/big-float": "^0.1.5",
37
36
  "@awsless/cloudwatch": "^0.0.1",
37
+ "@awsless/big-float": "^0.1.5",
38
+ "@awsless/clui": "^0.0.8",
38
39
  "@awsless/duration": "^0.0.4",
39
40
  "@awsless/dynamodb": "^0.3.8",
40
- "@awsless/json": "^0.0.10",
41
- "@awsless/iot": "^0.0.3",
42
41
  "@awsless/lambda": "^0.0.35",
43
- "@awsless/mqtt": "^0.0.2",
44
- "@awsless/open-search": "^0.0.21",
45
- "@awsless/s3": "^0.0.21",
42
+ "@awsless/json": "^0.0.10",
43
+ "@awsless/redis": "^0.0.14",
46
44
  "@awsless/sns": "^0.0.10",
47
45
  "@awsless/sqs": "^0.0.16",
46
+ "@awsless/open-search": "^0.0.21",
47
+ "@awsless/iot": "^0.0.3",
48
+ "@awsless/s3": "^0.0.21",
48
49
  "@awsless/validate": "^0.1.3",
50
+ "@awsless/mqtt": "^0.0.2",
49
51
  "@awsless/ssm": "^0.0.7",
50
- "@awsless/clui": "^0.0.8",
51
- "@awsless/weak-cache": "^0.0.1",
52
- "@awsless/redis": "^0.0.14"
52
+ "@awsless/weak-cache": "^0.0.1"
53
53
  },
54
54
  "dependencies": {
55
55
  "@arcanyx/cidr-slicer": "^0.3.0",
@@ -141,14 +141,14 @@
141
141
  "zod-to-json-schema": "^3.24.3",
142
142
  "@awsless/big-float": "^0.1.5",
143
143
  "@awsless/cloudwatch": "^0.0.1",
144
- "@awsless/clui": "^0.0.8",
144
+ "@awsless/duration": "^0.0.4",
145
+ "@awsless/graphql": "^0.0.9",
145
146
  "@awsless/json": "^0.0.10",
146
147
  "@awsless/scheduler": "^0.0.4",
147
- "@awsless/size": "^0.0.2",
148
- "@awsless/ts-file-cache": "^0.0.12",
149
148
  "@awsless/validate": "^0.1.3",
150
- "@awsless/duration": "^0.0.4",
151
- "@awsless/graphql": "^0.0.9"
149
+ "@awsless/size": "^0.0.2",
150
+ "@awsless/clui": "^0.0.8",
151
+ "@awsless/ts-file-cache": "^0.0.12"
152
152
  },
153
153
  "devDependencies": {
154
154
  "@hono/node-server": "1.19.9",