Hey hey :wave: Moving over from serverless framewo...
# help
j
Hey hey 👋 Moving over from serverless framework, I'm having an issue running an Apollo GraphQL API locally via
sst start
. I'm using
sst.ApolloApi
, essentially the exact example here. The response from my lambda is a
404
, and when attempting to load the endpoint in browser, I get:
Cannot GET /
Any hints?
f
Hey @Jared Burke do you see any error in the
sst start
terminal output?
I just gave the example a try.. starting from scratch.. seems to work
j
@Frank that's a negative.
Copy code
(outputs above this don't show any errors)
==========================
 Starting Live Lambda Dev
==========================

Debug session started. Listening for requests...
8c76df73-25d3-4cf8-9ea3-70b39a4d0c58 REQUEST local-mp-federation-sst-a-AuthServiceLambdaGETF615-Q1O3s6LCNUfM [services/auth/server.handler] invoked by API GET /
Enabling inline tracing for this federated service. To disable, use ApolloServerPluginInlineTraceDisabled.
8c76df73-25d3-4cf8-9ea3-70b39a4d0c58 RESPONSE {"statusCode":404,"body":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"utf-8\">\n<title>Error</title>\n</head>\n<body>\n<... 39 more characters","multiValueHeaders":{"x-powered-by":["Express"],"content-security-policy":["default-src 'none'"],"x-content-type-options":["nosniff"],"content-type":["text/html; charset=utf-8"],"content-length":["139"]},"isBase64Encoded":false}
f
Hmm… the error seems to come from Apollo server
Btw did u make any changes to the example?
j
Sorry, I'm an idiot
I had a path specified in the server definition, and carried over the example project (which didn't specify a path)
f
Ah haha.. is it working w/ the right path?
j
Yep, lol
f
Nice!
j
Sometimes just gotta come back with fresh eyes I guess
Thanks for the help 😛
f
np 👍
j
Really awesome product btw