Skip to content

ONSdigital/blaise-dashboard

Repository files navigation

blaise-dashboard

Web-based dashboard to view the status of various aspects of the data within a Blaise environment.

This project is a React.js application which when built is rendered by a Node.js express server.

The application is being deployed to Google App Engine.

Components

Completed case information

Shows count, percentage, and progress bar of the cases completed for all installed questionnaires. It's currently filtered to OPN only until questionnaire logic is updated for all surveys.

A collapsible element shows the definition of completed cases, as this could be misconstrued depending on the context.

The component has a configurable refresh, currently set to 10 seconds.

Local Setup

Prerequisites:

Clone the repository:

git clone https://github.com/ONSdigital/blaise-dashboard

Create an .env file in the root of the project and add the following variables:

Variable Description Example
BLAISE_API_URL The RESTful API URL the application will use to get questionnaire data. localhost:90
SERVER_PARK The name of the Blaise server park. gusty

Example .env file:

BLAISE_API_URL="localhost:8011"
SERVER_PARK="gusty"

Install the project dependencies:

yarn install

Running yarn or yarn install will install the required modules specified in the yarn.lock file.

The versions of these modules are fixed in the yarn.lock files, so to avoid unwanted upgrades or instability caused by incorrect modifications, DO NOT DELETE THE LOCK FILE.

More information about yarn (https://confluence.ons.gov.uk/x/zdwACQ)

Authenticate with GCP:

gcloud auth login

Set your GCP project:

gcloud config set project ons-blaise-v2-dev-sandbox123

Open a tunnel to our Blaise RESTful API in your GCP project:

gcloud compute start-iap-tunnel restapi-1 80 --local-host-port=localhost:8011 --zone europe-west2-a

Run Node.js server and React.js client via the following package.json script:

yarn dev

The UI should now be accessible via:

http://localhost:3000/

Tests can be run via the following package.json script:

yarn test

Test snapshots can be updated via:

yarn test -u

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Languages