@friggframework/serverless-plugin 2.0.0--canary.461.bdbd057.0 → 2.0.0--canary.461.e58db0a.0

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.
Files changed (2) hide show
  1. package/index.js +12 -4
  2. package/package.json +2 -2
package/index.js CHANGED
@@ -42,16 +42,24 @@ class FriggServerlessPlugin {
42
42
 
43
43
  const AWS = require("aws-sdk");
44
44
 
45
- const endpointUrl = "localhost:4566"; // Assuming localstack is running on port 4
46
- const region = "us-east-1";
45
+ const endpointUrl = process.env.AWS_ENDPOINT || "http://localhost:4566"; // LocalStack SQS endpoint
46
+ const region = process.env.AWS_REGION || "us-east-1";
47
+ const accessKeyId = process.env.AWS_ACCESS_KEY_ID || "root"; // LocalStack default
48
+ const secretAccessKey = process.env.AWS_SECRET_ACCESS_KEY || "root"; // LocalStack default
47
49
 
48
- // Configure AWS SDK
50
+ // Configure AWS SDK for LocalStack
49
51
  AWS.config.update({
50
52
  region: region,
51
53
  endpoint: endpointUrl,
54
+ accessKeyId: accessKeyId,
55
+ secretAccessKey: secretAccessKey,
56
+ s3ForcePathStyle: true, // Required for LocalStack
57
+ sslEnabled: false, // Disable SSL for LocalStack
52
58
  });
53
59
 
54
- const sqs = new AWS.SQS();
60
+ const sqs = new AWS.SQS({
61
+ sslEnabled: false, // Disable SSL validation for LocalStack
62
+ });
55
63
  // Find the environment variables that we need to override and create an easy map
56
64
  const environmentMap = {};
57
65
  const environment = this.serverless.service.provider.environment;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@friggframework/serverless-plugin",
3
- "version": "2.0.0--canary.461.bdbd057.0",
3
+ "version": "2.0.0--canary.461.e58db0a.0",
4
4
  "description": "Plugin to help dynamically load frigg resources",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -11,5 +11,5 @@
11
11
  "publishConfig": {
12
12
  "access": "public"
13
13
  },
14
- "gitHead": "bdbd0572d7347cd3ffc012b4c761cfc9a1d834ba"
14
+ "gitHead": "e58db0af84dd0c8fe3abdbbc472e433815c0f96d"
15
15
  }