Sounds cool. How does the connecting to a differen...
# general
r
Sounds cool. How does the connecting to a different stage work? Looking at the docs it seems it can connect to a deployed application. Is the console scraping the CloudWatch logs or is there something more real-time, if so, does that mean SST is instrumenting the code in some way ?
t
95% of the console's functionality is based off of talking directly to AWS APIs and showing the information in a way that's (hopefully) better than the AWS console
So the logs feature is just tailing cloudwatch apis
The other 5% are the local development features like seeing local invocations or the deploy button to redeploy stacks on changes
r
Ok, makes sense, thanks. Was curious from a security perspective.
t
Yeah it just piggybacks on whatever credentials you start sst console with
r
Just giving it a try but it doesn't seem to be able to get past Syncing Metadata
are there any logs I can share?
t
how many stacks do you have in the account?
yeah can you share the network logs on what's happening in the browser
I had this happen when I had some old unused stacks in there without the sst metadata
r
In terms of SST stacks, just one. Pretty sparse account
console looks like
Might be a region thing
t
Can I see the network tab?
It should be scanning through your stacks to find the right sst ones
r
Stack is in eu-central-1, eu-south-1 is in sst.json but here we override it via the CLI - can we pass --region to the console command?
ha, that worked
t
🤷🏽 lol
I think the console by default goes off of what your aws credentials are configured to use
r
It seemed to pull it from sst.json but I could be wrong
I only see the logs tailed, not the actual invocations, is that right?
t
Yeah this is just talking to cloudwatch logs so we don't know what the payload or response was
r
ok, ta
s
@thdxr can you elaborate on what the “cloudwatch logs” part means, in PR #1322?
t
If you use the
sst console
command with a stage that isn't running locally, it'll show function logs from cloudwatch instead of local
s
whaaaaat. no way! so if I run
console --stage=prod
, I can basically see all logs in real-time from production?
I assume it has to rewire all the Lambda functions to do this
t
It doesn't 🙂
it won't give you request payload or response payload, it's just showing you what data cloudwatch logs has
s
I warned you guys about messing around with mysterious magic 😆
t
I would never!
s
that’s awesome! that’s a huuuuuge time saver.
you obviously know how many clicks it takes to get into AWS, go into CloudWatch, click into the log group, etc
very cool, can’t wait to try this out!
s
This is just frikken amazing ya'll. Excited to show this off to my team. ♥️
j
Just updated the docs with all this feedback: https://docs.serverless-stack.com/packages/cli#console
s
ya'll...this is cool as hell!