From 2d95020da7ae0dccf5e3e1390bfb84b586422a1d Mon Sep 17 00:00:00 2001 From: Samuel Smith Date: Mon, 29 Aug 2016 12:23:25 -0500 Subject: [PATCH] NOAA decommissioned weather.noaa.gov Change weather.noaa.gov -> tgftp.nws.noaa.gov --- plugins/weather/temperature_ | 6 +++--- plugins/weather/temperatures | 6 +++--- plugins/weather/weather_press_ | 6 +++--- plugins/weather/weather_temp_ | 6 +++--- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/plugins/weather/temperature_ b/plugins/weather/temperature_ index f7187f7c..e81e6740 100755 --- a/plugins/weather/temperature_ +++ b/plugins/weather/temperature_ @@ -2,7 +2,7 @@ # # Copyright (C) 2006 Lars Strand # -# Plugin to fetch temperature from weather.noaa.gov +# Plugin to fetch temperature from tgftp.nws.noaa.gov # # Parameters supported: # @@ -16,7 +16,7 @@ use strict; my $usehum = $ENV{humidity} || undef; # set to "yes" to enable humidity -my $wcode = $ENV{wcode} || "ENGM"; # Find areacode here http://weather.noaa.gov/ +my $wcode = $ENV{wcode} || "ENGM"; # Find areacode here http://tgftp.nws.noaa.gov/ my $unit = $ENV{unit} || "C"; # "C" = Celsius, "F" = Fahrenheit my $proxy = $ENV{proxy} || undef; # Example: "http://proxy.foo.bar:8080/" @@ -41,7 +41,7 @@ if ($0 =~ /^(?:|.*\/)temperature_([^_]+)$/) { } -my $datasource = "http://weather.noaa.gov/pub/data/observations/metar/decoded/$wcode.TXT"; +my $datasource = "http://tgftp.nws.noaa.gov/data/observations/metar/decoded/$wcode.TXT"; my $ua = LWP::UserAgent->new(timeout => 30); $ua->agent('Munin'); diff --git a/plugins/weather/temperatures b/plugins/weather/temperatures index 18808faa..52711c8b 100755 --- a/plugins/weather/temperatures +++ b/plugins/weather/temperatures @@ -2,7 +2,7 @@ # # Copyright (C) 2006 Lars Strand # -# Plugin to fetch temperature from weather.noaa.gov +# Plugin to fetch temperature from tgftp.nws.noaa.gov # # Parameters supported: # @@ -15,7 +15,7 @@ use strict; -# Find areacodes here http://weather.noaa.gov/ +# Find areacodes here http://tgftp.nws.noaa.gov/ my @wcode = undef; if (defined($ENV{wcode})) { @@ -43,7 +43,7 @@ if (defined $ARGV[0] and $ARGV[0] eq "autoconf") { } } -my $datasource = "http://weather.noaa.gov/pub/data/observations/metar/decoded/"; +my $datasource = "http://tgftp.nws.noaa.gov/data/observations/metar/decoded/"; my $ua = LWP::UserAgent->new(timeout => 30); $ua->agent('Munin'); diff --git a/plugins/weather/weather_press_ b/plugins/weather/weather_press_ index 28c28ba3..5dc79358 100755 --- a/plugins/weather/weather_press_ +++ b/plugins/weather/weather_press_ @@ -1,11 +1,11 @@ #!/usr/bin/env python """ -munin US NOAA weather plugin (http://weather.noaa.gov) +munin US NOAA weather plugin (http://tgftp.nws.noaa.gov) Draws pressure in hPa. Copy/link file as 'weather_pressure_CODE', like: weather_pressure_LOWW for Austria, Vienna. -Get the code by going to http://weather.noaa.gov, selecting your +Get the code by going to http://tgftp.nws.noaa.gov, selecting your location, and copying the code from the address bar of your browser; should be something like CODE.html. @@ -16,7 +16,7 @@ import sys import urllib import re -url = 'http://weather.noaa.gov/pub/data/observations/metar/decoded/%s.TXT' +url = 'http://tgftp.nws.noaa.gov/data/observations/metar/decoded/%s.TXT' re_hPa = re.compile('Pressure.*\((\d+) hPa\)') diff --git a/plugins/weather/weather_temp_ b/plugins/weather/weather_temp_ index 5cd74b55..01c57494 100755 --- a/plugins/weather/weather_temp_ +++ b/plugins/weather/weather_temp_ @@ -1,11 +1,11 @@ #!/usr/bin/env python """ -munin US NOAA weather plugin (http://weather.noaa.gov) +munin US NOAA weather plugin (http://tgftp.nws.noaa.gov) Draws temperature/dew point in C. Copy/link file as 'weather_temp_CODE', like: weather_temp_LOWW for Austria, Vienna. -Get the code by going to http://weather.noaa.gov, selecting your +Get the code by going to http://tgftp.nws.noaa.gov, selecting your location, and copying the code from the address bar of your browser; should be something like CODE.html. @@ -16,7 +16,7 @@ import sys import urllib import re -url = 'http://weather.noaa.gov/pub/data/observations/metar/decoded/%s.TXT' +url = 'http://tgftp.nws.noaa.gov/data/observations/metar/decoded/%s.TXT' re_C = re.compile('Temperature:.*\((-?\d+\.?\d?) C\)') re_DewC = re.compile('Dew.*\((-?\d+\.?\d?) C\)')