Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

openSenseMap API

This repository contains the code of the openSenseMap API, which is the HTTP REST API used by https://opensensemap.org running at https://api.opensensemap.org. To get more information about openSenseMap and senseBox visit the before mentioned links or have a look at this video, read the API docs or the openSenseMap chapter in our documentation. openSenseMap is part of the senseBox project.

Originally, this API has been built as part of the bachelor thesis of @mpfeil at the ifgi (Institute for Geoinformatics, WWU Münster). Developers and previous maintainer include @umut0, @felixerdy, @noerw, @chk1 and @ubergesundheit.

You'll find that the repostiory uses yarn workspaces to separate the API and the database models for reuse in other projects. While the API is not published on npm, the package @sensebox/opensensemap-api-models is published from packages/models folder.

Configuration

Configuration of both the api and the models is done using mechanisms provided by lorenwest/node-config. You can find an annotated example configuration with all keys in config/config.example.json.

Development

  • Have Node.js v14, yarn, Docker and docker-compose installed
  • Start your development database (docker-compose up -d db)
  • Create branch for your feature (git checkout my-awesome-feature)
  • Run yarn install
  • Commit your changes to your branch and push it to your fork
  • Create a pull request against the master branch

See also: CONTRIBUTING

Running Tests

You can run the tests in containers using Docker and docker-compose.

# Run this the first time or every time you change dependencies in package.json
yarn build-test-env

yarn test

Related projects

Services

Libraries

Deployment

Technologies

Organization

Branches

  • master (runs on testing server)
    • Is used for container build tags
  • gh-pages

Tags and Versions

Git Tags are used for Docker hub builds (like v1). Version number is increased by one for each new version. Docker images are built automatically by the Docker hub for all tags starting with v

Versioned container images

  • Check out master branch
  • Go to root directory
  • Run tests
  • Optional: Build docker image locally
  • Commit everything needed for the container image
  • Run yarn tag-container
  • Run git push origin master

License

MIT - Matthias Pfeil 2015 - now