There are two ways of getting graphQL federation running locally:
Managed mode replicates our production environment by pushing things to production
Log into your PERSONAL account in https://studio.apollographql.com/
Create a new deployed graph. Give it whatever name you want. The button is in the top-right corner

On the next screen, copy the schema registration info found under the federation tab. You're going to need it later

# Generate a schema dump files— this is going to create
# graphql-schemas/private.graphql and graphql-schemas/public.graphql
$ rake graphql:dump_schemas
# Run commands to register public & private schemas with Apollo Studio
$ npx apollo service:push \\
--graph=artur-new-graph-hdd2ka \\
--key=<APOLLO_KEY> \\
--variant=private \\
--serviceName=ocean \\
--serviceURL=http://localhost:5000/graphql/federated \\
--localSchemaFile=graphql-schemas/private.graphql
$ npx apollo service:push \\
--graph=artur-new-graph-hdd2ka \\
--key=<APOLLO_KEY> \\
--variant=public \\
--serviceName=ocean \\
--serviceURL=http://localhost:5000/graphql/federated \\
--localSchemaFile=graphql-schemas/public.graphql
# Run the server
$ PUMA_METRICS_PORT=9396 WEB_CONCURRENCY=2 rails s -p 5000
useGraphQLFederation flag in Flipper# Generate a schema dump files— this is going to create
# graphql-schemas/private.graphql and graphql-schemas/public.graphql
$ rake graphql:dump_schemas
# Run commands to register public & private schemas with Apollo Studio
$ npx apollo service:push \\
--graph=artur-new-graph-hdd2ka \\
--key=<APOLLO_KEY> \\
--variant=private \\
--serviceName=embedded-dashboards \\
--serviceURL=http://localhost:2137/ \\
--localSchemaFile=graphql-schemas/private.graphql
$ npx apollo service:push \\
--graph=artur-new-graph-hdd2ka \\
--key=<APOLLO_KEY> \\
--variant=public \\
--serviceName=embedded-dashboards \\
--serviceURL=http://localhost:2137/ \\
--localSchemaFile=graphql-schemas/public.graphql
# Run the server
$ PUMA_METRICS_PORT=9397 rails s -p 2137
By this point, when you check Apollo Studio, you should have a whole federation pushed, with proper schema variants:
