flight-metrics

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2024 License: MIT Imports: 19 Imported by: 0

README

Flight Metrics

A flight price metrics monitor exporting by prometheus.

Grafana Dashboard

grafana-dashboard.json

Usage

Configure the monitoring flights

Config file example:

The default config file is configs/config.yml. You can modify it by yourself.

currency: CNY
lang: zh-cn
flights:
  - cron: '43 * * * *' # See https://crontab.guru/ for more details
    outboundDate: 2024-09-28
    returnDate: 2024-10-07
    departureAirport: 'XMN'
    arrivalAirport: 'NRT'
Run with docker
docker run -d \
    --name flight-metrics \
    -p 2112:2112 \
    -v ${PWD}/configs:/configs \
    gitsang/flight-metrics:latest \
        -c /configs/config.yml

Metrics

flight_google_round_trip{
    departure_airport="XMN",
    arrival_airport="NRT",

    outbound_date="2024-09-30",
    outbound_airline_name="EVA Air & XiamenAir",
    outbound_departure_time="12:55:00",
    outbound_duration="21h50m0s",
    outbound_arrival_time="11:45:00(+1)",

    return_date="2024-10-06",
    return_airline_name="Cathay Pacific & EVA Air",
    return_departure_time="14:25:00",
    return_duration="21h40m0s",
    return_arrival_time="11:05:00(+1)",
} 6974

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL