Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Launch Stack doesn't create "working" stack #9

Open
r00t-us3r opened this issue Dec 25, 2022 · 13 comments
Open

Launch Stack doesn't create "working" stack #9

r00t-us3r opened this issue Dec 25, 2022 · 13 comments
Labels
bug Something isn't working

Comments

@r00t-us3r
Copy link

Bug report

Describe the bug

I believe this is something relating to the "NamespaceName" parameter that makes all the services link up using an internal dns name. Without any further documentation inside this repository I'm unsure whether this is the case.

Once the stack is finished launching, when accessing the project from inside Supabase Studio it gets stuck "Connecting to project"

When checking the network tab from chrome dev tools, a number of errors are indicated - 404, 503 (see screenshots)

For the 503 error, when manually accessing the url with the api key specified as a url parameter it returns a JSON response
{"message":"no Route matched with those values"}

To Reproduce

  1. Open the README.md
  2. Click on "Launch Stack"
    • I have tried both "Stable" & "Latest" for "N. Virginia" & "Ireland"
  3. Scroll down to the bottom on the CloudFormation Stack create page
  4. Check the "Acknowledge" boxes
  5. Click "Create Stack"

Expected behavior

A fully functioning stack of the supabase system to be launched and usable / accessible.

Screenshots

Screen Shot 2022-12-25 at 21 43 16

Screen Shot 2022-12-25 at 21 43 29

Screen Shot 2022-12-25 at 21 44 39

Additional context

To my understanding, this repository is essentially providing a 1-click setup to get Supabase running on AWS. Incase the specific urls for my deployment are helpful, I have listed them below.

Amplify Studio URL: https://main.d2utrizos6o5a4.amplifyapp.com/
CloudFront URL: https://d1j57i0k9sfize.cloudfront.net/

@r00t-us3r r00t-us3r added the bug Something isn't working label Dec 25, 2022
@mats16
Copy link
Collaborator

mats16 commented Dec 26, 2022

It seams that the force deployment for ECS Service Connect is not works well, also kong service can not find other services via hosts. (because it need CloudTrail enabled)

I am trying fix it, to change to use internal DNS instead of hosts.

@r00t-us3r
Copy link
Author

It seams that the force deployment for ECS Service Connect is not works well, also kong service can not find other services via hosts. (because it need CloudTrail enabled)

I am trying fix it, to change to use internal DNS instead of hosts.

Sounds like a headache, is it because of something that recently changed on the AWS end?

Is there anyway to get a stack up and running now using perhaps an older version of the template?

I appreciate your replies during the festive period :)

@mats16
Copy link
Collaborator

mats16 commented Dec 27, 2022

I released new version. Please try it.

If you have same issue using new version, please give me Kong container logs. You can see this logs at ECS console or CloudWatch Logs console.

@mats16
Copy link
Collaborator

mats16 commented Dec 27, 2022

The cause is an omission of consideration of the AWS account status, such as CloudTrail enabled.

@r00t-us3r
Copy link
Author

I've tried this in Ireland and I get a different error when launching the stack.

I have gone through all sections of the AWS dashboard and removed all existing services relating to the stack before attempting the launch but the problem still persists.

Screen Shot 2022-12-27 at 15 04 47

Resource handler returned message: "Invalid request provided: CreateService error: SC service is already used by arn:aws:servicediscovery:eu-west-1:811985029972:namespace/ns-5vv5t5blurjhvnnf (Service: AmazonECS; Status Code: 400; Error Code: InvalidParameterException; Request ID: 2b6f474e-34e7-44cd-b30c-f35369359ff0; Proxy: null)" (RequestToken: 771661f2-034d-7681-1a09-acf94c4659ec, HandlerErrorCode: InvalidRequest)

I have gone through the same process in N. Virginia and the stack has launched successfully - The dashboard has launched successfull, ideally I'd be able to get this launched in Ireland but unsure on the above error.

@SteveChurch
Copy link

Just come across your problems, I am also seeing this issue in Ireland. I will try N Virginia now.

@gpalaci-carflow
Copy link

image

Same Ireland just auto deletes itself unless there is something I'm missing

@gpalaci-carflow
Copy link

Doesn't work in N.Virginia either, are there certain variables that must be changed or set on the template script init, otherwise it rolls-back and deletes itself?

@umuthopeyildirim
Copy link
Contributor

umuthopeyildirim commented Jun 2, 2023

Will try another region but this happens on Ireland(Stable and Latest)
Update: Another region didn't fix the problem.

@umuthopeyildirim
Copy link
Contributor

Do you wish to deploy these changes (y/n)? y
Supabase: deploying... [1/1]
Supabase: creating CloudFormation changeset...
[████▉·····················································] (19/226)
9:45:45 PM | CREATE_FAILED        | AWS::Lambda::Function                         | Studio/Repository/ImportFunction
Resource handler returned message: "'MemorySize' value failed to satisfy constraint: Member must have value less than or equal to 3008 (Service: Lambda, Status Code: 400, Request ID: 3f0c0bd7-ef8c-49d4-92af-00da1e3ef0bb)" (RequestToken: 520bcdb1-c1f5-0373-fa10-edffa890cc44, HandlerErrorCode: InvalidRequest)
9:45:47 PM | ROLLBACK_IN_PROGRESS | AWS::CloudFormation::Stack                    | Supabase
The following resource(s) failed to create: [ClusterDefaultServiceDiscoveryNamespaceC336F9B4, SmtpGenPasswordProviderframeworkonEventServiceRoleDefaultPolicy2D91E6D6, StudioRepositoryImportFunctionF87C7D62, SmtpSendEmailPolicyCCA0AA9B, VPCPublicSubnet3DefaultRouteA0D29D46, CloudFrontPrefixList22014EFD, CdnCacheManagerQueue786D7FA2, CdnWebAclNestedStackWebAclN
estedStackResourceFDB876C0, DatabaseCluster5B53A178, JwtSecretGenerateTokenFunctionB37EE16F, VPCPublicSubnet1DefaultRoute91CEF279, VPCPublicSubnet2DefaultRouteB7481BBA]. Rollback requested by user.
9:45:47 PM | ROLLBACK_IN_PROGRESS | AWS::CloudFormation::Stack                    | Supabase
The following resource(s) failed to create: [ClusterDefaultServiceDiscoveryNamespaceC336F9B4, SmtpGenPasswordProviderframeworkonEventServiceRoleDefaultPolicy2D91E6D6, StudioRepositoryImportFunctionF87C7D62, SmtpSendEmailPolicyCCA0AA9B, VPCPublicSubnet3DefaultRouteA0D29D46, CloudFrontPrefixList22014EFD, CdnCacheManagerQueue786D7FA2, CdnWebAclNestedStackWebAclN
estedStackResourceFDB876C0, DatabaseCluster5B53A178, JwtSecretGenerateTokenFunctionB37EE16F, VPCPublicSubnet1DefaultRoute91CEF279, VPCPublicSubnet2DefaultRouteB7481BBA]. Rollback requested by user.
9:46:02 PM | DELETE_IN_PROGRESS   | AWS::RDS::DBCluster                           | Database/Cluster

I also tried launching a stack through terminal didn't work either.

@umuthopeyildirim
Copy link
Contributor

Nevermind it seems like they put artifical limit on my account and I need to increase it with AWS Support. I hope you have Technical support that can expatiate this request.
https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html

@y4my4my4m
Copy link

y4my4my4m commented Jan 14, 2024

@mats16
うまくいけないね

Resource handler returned message: "'MemorySize' value failed to satisfy constraint: Member must have value less than or equal to 3008 (Service: Lambda, Status Code: 400, Request ID: 80317eb7-c2f0-4ea8-ae8e-f5e8d2bd53ff)" (RequestToken: 1311acd8-06bf-ba0c-c6fa-ad778659644c, HandlerErrorCode: InvalidRequest)

Edit:
I changed the max memory to 3008 and it worked.

Supabase.template.json

However, it NEEDS ecs to run.. (set everything to micro for lowest cost)

Also, am getting WSS errors for realtime...

@y4my4my4m
Copy link

The WSS really doesn't work

The webpage at wss://XXXXXX.cloudfront.net/realtime/v1/websocket?apikey=XXXXXXX&vsn=1.0.0 might be temporarily down or it may have moved permanently to a new web address.
ERR_UNKNOWN_URL_SCHEME

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants