|
| 1 | +# BFF Service Troubleshooting Guide |
| 2 | + |
| 3 | +## Common Issues and Solutions |
| 4 | + |
| 5 | +- Make sure that you are running the `dev` script and not `start` script. For example when running the service portal you should run: |
| 6 | + `yarn dev service-portal` and not `yarn start service-portal`. |
| 7 | + |
| 8 | +- Make sure to install dependencies and run code generation with the following command: |
| 9 | + `yarn install && yarn codegen`. |
| 10 | + |
| 11 | +- Make sure to login to the correct AWS account and region: |
| 12 | + |
| 13 | + - Run `aws sso login --profile islandis-dev` to login to the correct AWS account. |
| 14 | + |
| 15 | +- Not necessary but a nice to have is to have Redis server running: |
| 16 | + |
| 17 | + - Run `yarn dev-services services-bff` to start Redis server. |
| 18 | + - This is necessary if you want the sessions to persist. |
| 19 | + |
| 20 | +- Make sure that you are not running the same service twice, since you could already be running a service like API. |
| 21 | + Lets take `yarn dev application-system-form` as an example. This script starts the following services: |
| 22 | + |
| 23 | + - `yarn get-secrets application-system-api` |
| 24 | + - `yarn nx run application-system-api:dev-services` |
| 25 | + - `yarn nx run application-system-api:migrate` |
| 26 | + - `yarn nx codegen/backend-schema api` |
| 27 | + - `yarn nx run services-user-profile:dev-init` |
| 28 | + - `yarn nx run service-portal:start-bff` |
| 29 | + - `yarn start application-system-form` |
| 30 | + So make sure that you are not running the same service twice. |
| 31 | + |
| 32 | +- If you are running the service on Windows, we recommend using [WSL2](https://docs.microsoft.com/en-us/windows/wsl/install) for running the services within the repo. |
| 33 | + This is because all of the scripts generated by the `infra` package are not tested on Windows and may not work as expected. |
| 34 | + |
| 35 | +- On macOS, the AirPlay Receiver is listening on the same port as the Redis server, e.g. 7000. Either change the port or disable the AirPlay Receiver. |
| 36 | + |
| 37 | +- If everything fails, then a good old computer restart might do the trick. |
0 commit comments