2020-05-23 18:36:15 +00:00
|
|
|
# Console
|
|
|
|
|
|
|
|
Apollo GraphQL client.
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
2020-07-20 17:14:04 +00:00
|
|
|
Use the following command to run the server at: http://localhost:9004
|
2020-05-27 23:09:20 +00:00
|
|
|
|
|
|
|
```bash
|
|
|
|
yarn start
|
|
|
|
```
|
|
|
|
|
|
|
|
To test the Console app, the `@dxos/console-app` must be built first:
|
|
|
|
|
|
|
|
```bash
|
|
|
|
cd ../console-app
|
|
|
|
yarn build
|
|
|
|
```
|
|
|
|
|
|
|
|
Use the following command to run the client in development mode (via the `webpack-dev-server`) at http://localhost:8080
|
|
|
|
|
|
|
|
```bash
|
|
|
|
yarn dev
|
|
|
|
```
|
|
|
|
|
|
|
|
To build the client and serve it directly from the server:
|
|
|
|
|
2020-05-23 18:36:15 +00:00
|
|
|
```bash
|
2020-05-27 23:09:20 +00:00
|
|
|
yarn build
|
2020-05-23 18:36:15 +00:00
|
|
|
yarn start
|
|
|
|
```
|
|
|
|
|
2020-07-20 17:14:04 +00:00
|
|
|
Then open the app at: http://localhost:9004/console
|
2020-05-27 23:09:20 +00:00
|
|
|
|
|
|
|
|
|
|
|
## Production
|
|
|
|
|
|
|
|
When running the Console server, either set the `CONFIG_FILE` environment variable or set the `--config` option.
|
|
|
|
|
|
|
|
```bash
|
|
|
|
./bin/console.js --config ./config.yml
|
|
|
|
```
|
|
|
|
|
|
|
|
NOTE: The server passes its configuration directly to the Console app when it is loaded.
|