I am working on startng the router and it is giving me an error:
Running the command gives me the error:
APOLLO_KEY=service:airlock-dwih0w:e8L2UitvsBgXjgBz_TZTgA APOLLO_GRAPH_REF=airlock-dwih0w@current
./router --config config.yaml
Apollo Router v1.38.0 // (c) Apollo Graph, Inc. // Licensed as ELv2 (Apollo FAQ on Licensing under Elastic License v2 (ELv2) - Apollo GraphQL Docs)
The Apollo Router requires a composed supergraph schema at startup.
DO ONE:
- Pass a local schema file with the ‘–supergraph’ option:$ ./router --supergraph <file_path>
- Fetch a registered schema from GraphOS by setting
these environment variables:$ APOLLO_KEY=“…” APOLLO_GRAPH_REF=“…” ./routerFor details, see the Apollo docs:
Setting up managed federation - Apollo GraphQL Docs
TESTING THINGS OUT?
- Download an example supergraph schema with Apollo-hosted subgraphs:
$ curl -L https://supergraph.demo.starstuff.dev/ > starstuff.graphql
- Run the Apollo Router in development mode with the supergraph schema:
$ ./router --dev --supergraph starstuff.graphql
How do I get around this? Do I specify the location of the schema file ?