Template repository for GraphQL services using Apollo.
- Copy the .env.example file in the root of the project as .env and fill in any necessary Environment Variables
- Run
make
- App will be running at http://localhost:4000/graphql
- Run
make stop
to destroy local environment
Key | Description | Default | Required |
---|---|---|---|
GRAPHQL_PATH | The pathname to serve GraphQL requests | "/graphql" |
|
LOG_FORMAT | The morgan log format | "combined" |
|
PORT | The application port | 4000 |
|
REDIS_HOST | The Redis cache hostname | ✅ | |
REDIS_PORT | The Redis cache port | 6379 |
Run yarn generate
to generate TypeScript definitions for GraphQL resolvers with GraphQL Code Generator.
In Visual Studio Code, codegen can be run as a background task by executing Tasks: Run Task and selecting npm: generate.
Run yarn test
to run Jest tests.
Terraform configurations are located in the .iac directory.
Continuous integration and deployment workflows are run via GitHub Actions. See .github/workflows for workflow configurations.
- Runs build and test on all branches
- Runs build, test, and deploy on version tags (v*).
- Deploys to dev on every prerelease tag (v1.2.4-pre.0, v2.0.0-rc.5)
- Deploys to dev, staging, and prod on every release tag (v3.4.5)