Skip to content

corasphinx/LoraWAN-transport

Repository files navigation

Aloes - LoraWan Transport

  • Decrypt and encrypt Lora packet
  • Authentification by OTAA and ABP via Aloes device-manager
  • MQTT flow triggered by LoraWan server events
  • Decode payload received/sent with CayenneLPP

Full Docs

LoraWan MQTT API build upon :


Folder structure

  • /. --> Main application configuration, dependencies list, and launch scripts

  • /deploy --> contains environment variables ( hidden files )

  • /docs --> contains static site assets and configuration ( JSDoc & Vuepress)

  • /log --> contains logs from PM2

  • /src --> contains source code

Configuration

Edit your config in .env_sample and save it as .env. You can override these by populating deploy with files corresponding to an environment ( eg: .env_production ... ), and via pm2 ecosystem.config.json .

Installation

  $ npm install -g pm2
  $ npm install

Linting

  $ npm run lint

Running the development server (REST API)

  $ npm run start:dev

Generate documentation

With JSDoc and Vuepress

$ npm run docs:dev
$ npm run docs:build
$ npm run docs:serve

Deploying project

Please remember to update .env and / or ecosystem.config.json files to match your enviroment.

  $ npm run deploy:prod

You can also launch this app with pm2 :

  • Access to server with SSH :
  $ ssh-keygen -f ~/.ssh/server_name -t rsa -C <email_address> -b 4096
  $ ssh-copy-id -i ~/.ssh/server_name user@server_uri
  • Creating environment :
  $ pm2 deploy ecosystem.config.js production setup
  • Updating environment :
  $ pm2 deploy ecosystem.config.js production update

Be sure to commit your changes on the right branch before each setup and update: ( master for production env, and staging for dev/staging env )

  $  git checkout master
  $  git add .
  $  git commit .
  $  git push

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published