Skip to content

yingzhao-1/Sia-EventUI

 
 

Repository files navigation

LICENSE Build Status Codacy Badge Coverage Status JavaScript Style Guide PRs Welcome

This is the user interface for SRE Incident Assistant (SIA)

See the Root repository for full project information and an overview of how services fit together.

SIA is built using:

SIA is configured for Wepback's hot module reloading, so changes should automatically appear in your browser.

Requirements

  • Node.js (latest LTS is preferred)

Before You Start

You will need to add const files in config for each environment you want to use; these are not tracked in git. See cfg/constExample.js for more details. Const files follow the naming convention $env.const.js (localhost.const.js is the const file loaded by localhost.js, for example).

Launch UI pointing at a local Gateway API

Use these steps to launch if you're hosting your Gateway API locally.

  • Navigate to the SIA-EventUI source directory root
  • Ensure your local copy of the gateway API is running on http://localhost:50000 (or the base URL you configured)
  • Enter these commands to launch the Event UI:
    npm install
    npm start
    
  • Navigate to http://localhost:3000

Launch UI pointing at a remote dev Gateway API

Use these steps if you're working on the Event UI and do not need to run a local copy of the gateway.

  • Create a localhost.const.js file inside the cfg folder. Use the cfg/constExample.js file as a template.
  • Navigate to the SIA-EventUI source directory root
  • Enter these commands to launch the Event UI:
    npm install
    npm run serve
    
  • Navigate to http://localhost:3000

To Test

  • Enter this command:
npm test

To create dist bundle, no server

webpack --env=dist

NPM scripts

A partial list of run scripts and what they do

Script What it does
start Launch the server and point at a gateway hosted on localhost (use localhost.const.js)
serve Launch the server and point at a gateway hosted in the dev environment (use dev.const.js)

About

User interface for SIA event timeline

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 96.7%
  • Batchfile 1.5%
  • Other 1.8%