Overview
Adding a new hub region to telemetry means registering the hub code across the distribution configuration and the build menu, then confirming the region’s timezone is available in the telemetry UI (also known as the web-app). Pushing to PROD deploys the changes.Prerequisites
- Access to the telemetry repository.
- The new hub code (region code, uppercase, for example
DE). See the naming convention. - The timezone(s) for the new region (for example
Europe/Berlinfor Germany).
Adding the Region
Add the new hub code in each of the following files.1
Add to the PROD distribution env
In
distribution/.env, append the new hub code to HUBREGIONS:2
Add to the DEV distribution env
In
distribution/.env.dev, append the new hub code to HUBREGIONS in the same way.3
Add to the build menu
In
distribution/build_application.bat, add a menu option for the new region, extend the prompt range, and add the matching branch that sets HUBREGION:4
Add to the API launch config
In
telemetry/telemetry-api/.vscode/launch.json, append the new hub code to HUB_REGIONS:Checking the Timezone
Confirm the new region’s timezone is available in the telemetry UI (web-app).1
Open the timezone list
Open
telemetry/telemetry-web-app/src/app/services/date-time.service.ts and check the commonTimeZones array.2
Add the timezone if missing
Make sure the timezone(s) for the new region are present. If a required timezone is missing, add it to the array. For example, Germany uses
Europe/Berlin:Deploying
1
Push to PROD and confirm deployment
Push the changes to PROD. This deploys the changed scripts to the S3 bucket, from which they are synced, and the changed Docker images, which are pulled when run. Confirm the deployment has completed successfully.
