This repo contains instructions (and automation) for deploying a set of proxies and resources in Apigee Edge that demonstrate the tooling provided in the graphql-authz repo.
The demo contains several components. Each component is located in its own git repo, which are added as submodules in this repo:
- apigee-graphql-demo-server
- apigee-graphql-demo-proxy
- apigee-graphql-demo-oauth
- apigee-graphql-demo-config
- apigee-graphql-demo-portal
- bash (Linux shell)
- Docker (18 or newer)
For this demo you will need to have a target backend GraphQL server. The server needs to be reachable from the internet so that Apigee edge is able to forward requests to it.
Take a look at the repo apigee-graphql-demo-server for instructions on how to deploy the demo GraphQL Server. This GraphQL server comes already loaded with a sample schema (ski resorts), as well as plugins for collecting and uploading analytics data to Apigee Edge and Stackdriver.
For this demo to work, there are several components that need to be deployed to your Apigee Edge organization.
These are graphql-proxy, graphql-oauth and graphql-config.
Rather than going to the each individual repo and installing the components separately, you can use the build.sh script and deploy all these components in one shot. To do this, follow the instructions below:
-
Clone this repo (including submodules)
$ git clone --recurse-submodules git@github.com:micovery/apigee-graphql-demo.git
-
Run the these commands:
$ export TARGET_BACKEND=https://your.backend.serveo.com/graphql $ export APIGEE_USERNAME=username@examle.com $ export APIGEE_PASSWORD=SuperSecret#123 $ export APIGEE_ORG=your-apigee-org $ export APIGEE_ENV=test
$ ./build.sh
Note, if you are using Apigee OnPrem Deployment Kit (OPDK), you must also set "APIGEE_HOSTURL" environment variable to point to the Apigee Management Server API endpoint.
After the build is complete, you should have two new proxies (graphq-proxy, graphql-server) in your Apigee Edge org.
You should also see a new Key-Value-Map (KVM) called graphql. This KVM contains metadata used by the graphql-proxy.
Once you have the Apigee Edge components, the final step is to stand up a developer portal where you
can create apps, and use the GraphQL playground to explore the schema exposed by the graphql-proxy API Proxy.
Take at the apigee-graphql-demo-portal repo for instructions.
This is not an officially supported Google product.