weatherfeeder: split the former maximumdirect.net/weatherd project in two.
feedkit now contains a reusable core, while weatherfeeder is a concrete implementation that includes weather-specific functions.
This commit is contained in:
66
cmd/weatherfeeder/config.yml
Normal file
66
cmd/weatherfeeder/config.yml
Normal file
@@ -0,0 +1,66 @@
|
||||
---
|
||||
sources:
|
||||
- name: NWSObservationKSTL
|
||||
kind: observation
|
||||
driver: nws_observation
|
||||
every: 12m
|
||||
params:
|
||||
url: "https://api.weather.gov/stations/KSTL/observations/latest"
|
||||
user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
- name: OpenMeteoObservation
|
||||
kind: observation
|
||||
driver: openmeteo_observation
|
||||
every: 12m
|
||||
params:
|
||||
url: "https://api.open-meteo.com/v1/forecast?latitude=38.6239&longitude=-90.3571¤t=temperature_2m,relative_humidity_2m,weather_code,wind_speed_10m,wind_direction_10m,precipitation,surface_pressure,rain,showers,snowfall,cloud_cover,apparent_temperature,is_day,wind_gusts_10m,pressure_msl&forecast_days=1"
|
||||
user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
- name: OpenWeatherObservation
|
||||
kind: observation
|
||||
driver: openweather_observation
|
||||
every: 12m
|
||||
params:
|
||||
url: "https://api.openweathermap.org/data/2.5/weather?lat=38.6239&lon=-90.3571&appid=c954f2566cb7ccb56b43737b52e88fc6&units=metric"
|
||||
user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
# - name: NWSObservationKSUS
|
||||
# kind: observation
|
||||
# driver: nws_observation
|
||||
# every: 18s
|
||||
# params:
|
||||
# url: "https://api.weather.gov/stations/KSUS/observations/latest"
|
||||
# user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
# - name: NWSObservationKCPS
|
||||
# kind: observation
|
||||
# driver: nws_observation
|
||||
# every: 12m
|
||||
# params:
|
||||
# url: "https://api.weather.gov/stations/KCPS/observations/latest"
|
||||
# user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
# - name: NWSAlertsSTL
|
||||
# kind: alert
|
||||
# driver: nws_alerts
|
||||
# every: 1m
|
||||
# params:
|
||||
# url: "https://api.weather.gov/alerts?point=38.6239,-90.3571&limit=500"
|
||||
# user_agent: "HomeOps (eric@maximumdirect.net)"
|
||||
|
||||
sinks:
|
||||
- name: stdout
|
||||
driver: stdout
|
||||
params: {}
|
||||
|
||||
# - name: logfile
|
||||
# driver: file
|
||||
# params:
|
||||
# path: "/Users/eric/weatherd.log"
|
||||
|
||||
routes:
|
||||
- sink: stdout
|
||||
kinds: ["observation"]
|
||||
|
||||
# - sink: logfile
|
||||
# kinds: ["observation", "alert", "forecast"]
|
||||
Reference in New Issue
Block a user