This repository contains the GraphQL backend, Ember frontend, and docker/compose scripts for a development environment.
This project requires Docker Compose to develop and test. The Yarn package manager is also required, and is used instead of npm
.
- Clone repository
- Override any applicable development environment variables (see Environment Variables below)
- In the project root, run
yarn start
. Also available:
yarn stop
(graceful shutdown/cleanup)yarn kill
(remove all local data)yarn terminal:app
Interactive terminal within the Emberapp
containeryarn terminal:graph
Interactive terminal within the GraphQLgraph
container
- The application is now accessible on
localhost:9905
(or whatever port you configure)
You can load an interactive terminal for the relevant container via yarn terminal:app
or yarn terminal:graph
. This will allow you to add, remove, or upgrade project dependencies using Yarn (among other things). Note: the application instances must be running via yarn start
for the terminal to load.
Application configuration is not under version control, and must be injected as environment variables. The envalid library is used to ensure the required variables have been set.
- Create a
.env
file in the project root - Set (or change) values for the following variables:
EMBER_SERVE_PORT=9905
EMBER_LIVER_PORT=9906
EMBER_TESTS_PORT=9907
GRAPH_APP_PORT=9900
GRAPH_DB_PORT=9901
GRAPHQL_URI=some-url
B4GRAPH_API_KEY=some-api-key
TENANT_KEY=some-account-group
PLATFORM_URI=https://some.domain
PLATFORM_LOGO=https://cdn.some.domain/some/path/to/some.img
NOTIFICATION_TO[email protected]
SENDGRID_FROM=root@localhost
SENDGRID_API_KEY=some-api-key
DEBUG=express:*
MONGOOSE_DEBUG=1
Note: You must specify a valid Base4Graph URI and Api Key to use this application.
The following environment variables must be set at run-time for the production deployment of this application. The development and test environments set appropriate values for those environments within the docker-compose.yml
configuration files.
# Must be configured per instance
GRAPHQL_URI=
B4GRAPH_API_KEY=
TENANT_KEY=
PLATFORM_URI=
PLATFORM_LOGO=
NOTIFICATION_TO=
SENDGRID_API_KEY=