GithubHelp home page GithubHelp logo

remmelt / openweathermap_exporter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from blackrez/openweathermap_exporter

2.0 1.0 1.0 8 KB

OpenWeatherMap current weather data exporter for Prometheus

License: MIT License

Go 75.06% Dockerfile 8.82% HCL 8.55% Makefile 7.57%

openweathermap_exporter's Introduction

Openweather exporter for prometheus

Exporter for openweather API

Quickstart

Create an API key from https://openweathermap.org/.

Install dependancies with go get and then build the binary.

go get -d -v
go build
SERVER_PORT=2112 OWM_LOCATION=LONDON,UK  OWM_API_KEY=apikey ./openweathermap_exporter

Then add the scraper in prometheus

scrape_configs:
  - job_name: 'weather'

    # Scrape is configured for free usage.
    scrape_interval: 60s

    # Port is not yet configurable
    static_configs:
      - targets: ['localhost:2112']

With Docker

The image is a multistage image, just launch as usual :

docker build -t ows .
docker run --rm -e SERVER_PORT=2112 -e OWM_LOCATION=LONDON,UK  -e OWM_API_KEY=apikey -p 2112:2112 ows

openweathermap_exporter's People

Contributors

blackrez avatar thomersch avatar

Stargazers

Johan Steenhoven avatar Benjamin DANIEL avatar

Watchers

James Cloos avatar

Forkers

haraldkoch

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.