Skip to content

Consume from website-carbon-api via Kafka queue, persist to db.

Notifications You must be signed in to change notification settings

dtm001/carbon-consumer

Repository files navigation

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications.

Description

Application for consuming website carbon data via kafka queue, persisting to db.

Require .env with following connection details:

WEB_CARBON=https://api.websitecarbon.com/site?url=

POSTGRES_HOST=SOME_HOST
POSTGRES_PORT=SOME_PORT
POSTGRES_USER=SOME_USER
POSTGRES_PASSWORD=SOME_PASS
POSTGRES_DATABASE=SOME_DB_NAME
PORT=SOME_PORT
MODE=DEV
RUN_MIGRATIONS=false

Installation

$ npm install

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

About

Consume from website-carbon-api via Kafka queue, persist to db.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published