Adrián Mouly
06/07/2022, 8:09 PMdev
?Adrián Mouly
06/07/2022, 10:25 PMAdrián Mouly
06/08/2022, 9:27 PMmessage group id
, but it doesn’t work.
I have this config on my EB Rule:
targets: {
targetOne: {
type: 'queue',
queue: subsystemFinishedQueue,
cdk: {
target: {
retryAttempts: 1,
messageGroupId: '$.detail.surveyQuestionId',
},
},
},
},
jamlen
06/09/2022, 1:41 PMTim
06/09/2022, 9:51 PMsst start
or sst deploy
, which turned out to be because the local environment was running node 16 and the deployed lambda was using node 14. would it be possible to have sst warn/error when sst start
is running with the wrong runtime version?Adrián Mouly
06/10/2022, 12:05 AMErik Robertson
06/10/2022, 10:08 AMCamilo Bravo
06/10/2022, 2:55 PMNextjsSite
Erik Robertson
06/10/2022, 6:08 PMimport * as firehose from "@aws-cdk/aws-kinesisfirehose-alpha";
import * as firehose_destinations from "@aws-cdk/aws-kinesisfirehose-destinations-alpha";
...
const auditBucket = new Bucket(this, 'Audit')
const cdkAuditBucket = auditBucket.cdk.bucket
const firehoseDestination = new firehose_destinations.S3Bucket(cdkAuditBucket, { dataOutputPrefix: 'site!{partitionKeyFromQuery:id_site}/!{timestamp:yyyy}/!{timestamp:MM}/', errorOutputPrefix: 'firehoseErrors/' })
const kinesisFirehose = new firehose.DeliveryStream(this, 'Audit Firehose', { destinations: [firehoseDestination] });
config['AuditKinesisDeliveryStreamName'] = kinesisFirehose.deliveryStreamName
Jarod Stewart
06/10/2022, 6:29 PMAri Becker
06/11/2022, 8:01 AM.env
files into a directory, instead of keeping them in the root?
The underlying library supports a path
option: https://github.com/motdotla/dotenv#path
As there are a bunch of different .env
files, it seems cluttered to me to store them all in the root, instead of a dotenv
or config
directory of some kind.
Ideally I'd be able to add dotenv.path
to sst.json
, I think?Giorgio
06/11/2022, 6:53 PMe8a5a024-b37d-4ce6-b85e-d0d7ee454267 REQUEST dev-dolartec-app-db-DatabaseMigrationFunction9CBE9-qOutRhPjrpC9 [index.handler] invoked
(node:19518) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use `node --trace-warnings ...` to show where the warning was created)
e8a5a024-b37d-4ce6-b85e-d0d7ee454267 ERROR Runtime.UnhandledPromiseRejection: Runtime.UserCodeSyntaxError: SyntaxError: Cannot use import statement outside a module
jamlen
06/13/2022, 12:24 PMmigrations
being a string to a path. I need to be able to know which database is targeted for migration and then set the path for the migrations accordingly. Something like this
export async function RDSStack({ stack, app }: StackContext) {
const cluster = new RDS(stack, "RDSCluster", {
engine: "postgresql10.14",
defaultDatabaseName: 'postgres',
migrations: (dbname: string) => new FileMigrationProvider(`./migrations/${dbname}`)
})
return { cluster }
@Frank @thdxr is this something that could be looked at or is there way that I can tell the underlying Kysely to use a custom MigrationProvider
class?Adrián Mouly
06/13/2022, 10:46 PMreturn new Bucket(this, 'my-bucket', {
bucketName,
cors: [
{
allowedOrigins: [allowedOrigin],
allowedMethods: [HttpMethods.GET, HttpMethods.HEAD],
},
],
lifecycleRules: [
{
expiration: Duration.days(1),
},
],
});
Now I want to remove the TTL… I removed from code, but CFormation is trying to re-create the bucket and fails… why can’t just UPDATE it?Sean Matheson
06/14/2022, 1:35 PMRemixSite
construct to contain a description. This should hopefully help with reviews.
https://github.com/serverless-stack/serverless-stack/pull/1800Salim Haruna
06/14/2022, 2:50 PMAdrián Mouly
06/15/2022, 4:26 AMStaticSite
, due I have to deploy multiple React apps into the same bucket… (for the micro-frontend discussion)…
And I need to copy the logic for invalidate CFront… but… why is the invalidation done in a lambda, and not done from the stack? is that even possible?Slackbot
06/15/2022, 7:10 AMWyatt Goettsch
06/16/2022, 12:00 AMSean Matheson
06/16/2022, 7:49 AMRemixSite
PR update;
✅ Added testsAshishkumar Pandey
06/16/2022, 8:04 PMSam Frampton
06/17/2022, 11:51 AMJP (junaway)
06/17/2022, 6:12 PMTimothée Clain
06/17/2022, 7:01 PMFilip Pyrek [AWS Hero]
06/18/2022, 1:06 PMimport { someFunction } from '@packages/some-package' // or import from '../../packages/some-package' - it's is the same in this case
export const handler = async (event) => {
someFunction('hello')
return '123'
}
Then I start the debugging session with $ sst start
When I change the file of the lambda function handler, I can see in the terminal info message:
Functions: Building api functions/lambda.handler...
Functions: Done building api functions/lambda.handler (101ms)
And everything works great so far. 👍
The problem:
When I change a file inside the package @packages/some-package
which is located in completely different folder (../../packages/some-package
), no reload/recompilation happens and the application is still using the old source code of the package.
How I hacked it and fixed it:
When I did the reverse engineering, I found out that here:
https://github.com/serverless-stack/serverless-stack/blob/9d8cc00da72942ef39348b25ff993117e502f30f/packages/core/src/runtime/watcher.ts
and here:
https://github.com/serverless-stack/serverless-stack/blob/9d8cc00da72942ef39348b25ff993117e502f30f/packages/core/src/runtime/handler/node.ts#L2[…]24
the SST is defining which files it will be watching.
When I added to the list path to my packages folder, it started to work ✅
What do you think would be the best way how to address this issue? I’m happy to contribute. 🙂
Thanks.T Indie
06/19/2022, 12:53 PMAkos
06/21/2022, 11:27 AMSam Frampton
06/21/2022, 10:03 PMIvan Roskoshnyi
06/22/2022, 7:53 AM"a bucket with this name already exists"
?Mischa Spiegelmock
06/23/2022, 11:56 PM