Skip to content

A Node.js Application that provides a rest API to retrieve solar data from the NOAA/NWS

License

Notifications You must be signed in to change notification settings

jamie-sherriff/solar-activity-server

Repository files navigation

Solar Activity Server

What is this?

  • A Node.js Application that usesexpressjs.com to host a rest API that retrieves solar data from NOAA/NWS (National Oceanic Atmospheric Administration/National Weather Service) and outputs most of the data in JSON (JavaScript Object Notation).
  • The various sources of data has come from swpc noaa data
  • The main purpose of this service is to predict Auroras Triggered from solar activity.

Live Demo

  • The service can be viewed online at Solar Service
  • A client app that retrieves and displays the data can be viewed at Solar App

Requirements:

  • NodeJs 6+
  • A maxmind city DB for reverse geo ip lookups Source: (https://dev.maxmind.com/maxmind-db/) A helper script is located in /helpers can download this.
  • A Gmail email setup that uses OAuth2

How to run?

  • Download a maxmind db from above and extract to /static
  • Set the DEFAULT_SOLAR_PORT environment variable for production use port to host the server on
  • Email config file location is set by SOLAR_SERVICE_SECRET_CONFIG_PATH environment variable
  • Download a maxmind db from above
  • npm start which is alias for npm install && node index.js

Documentation

Running for development

  • npm run dev
  • This runs the server with nodaemon for auto restarting on code changes

Running Tests

  • npm test

Checking code style

  • npm run lint

Generate docs

  • npm run doc

Contributions

  • Always welcome

Contributing guidelines

  • Write tests
  • Check tests pass
  • Write docs if applicable
  • Check linting
  • Do a Pull request

About

A Node.js Application that provides a rest API to retrieve solar data from the NOAA/NWS

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published