ignore ssl verification
This commit is contained in:
parent
aaa4f4243e
commit
26a3d5d958
|
@ -2,10 +2,11 @@
|
||||||
echo "this takes some time depending on the amount of addresses in your lists …"
|
echo "this takes some time depending on the amount of addresses in your lists …"
|
||||||
for file in *-csv ; do
|
for file in *-csv ; do
|
||||||
out=$(echo "${file}"|cut -d- -f1)".geojson"
|
out=$(echo "${file}"|cut -d- -f1)".geojson"
|
||||||
if test -e "${out}" ; do
|
if test -e "${out}" ; then
|
||||||
echo "file exists: ${out}, skipping."
|
echo "file exists: ${out}, skipping."
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
echo ./lookup.py "${file}"
|
echo ./lookup.py "${file}"
|
||||||
./lookup.py "${file}" 2>/dev/null > "${out}"
|
./lookup.py "${file}" > "${out}"
|
||||||
|
#~ ./lookup.py "${file}" 2>/dev/null > "${out}"
|
||||||
done
|
done
|
||||||
|
|
|
@ -5,7 +5,14 @@ from geopy import Nominatim
|
||||||
# ~ import json
|
# ~ import json
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
import sys
|
#disable ssl verification
|
||||||
|
import ssl
|
||||||
|
import geopy.geocoders
|
||||||
|
ctx = ssl.create_default_context()
|
||||||
|
ctx.check_hostname = False
|
||||||
|
ctx.verify_mode = ssl.CERT_NONE
|
||||||
|
geopy.geocoders.options.default_ssl_context = ctx
|
||||||
|
#/
|
||||||
|
|
||||||
# debug print to stderr, https://stackoverflow.com/questions/5574702/how-to-print-to-stderr-in-python
|
# debug print to stderr, https://stackoverflow.com/questions/5574702/how-to-print-to-stderr-in-python
|
||||||
def eprint(*args, **kwargs):
|
def eprint(*args, **kwargs):
|
||||||
|
|
|
@ -14,12 +14,12 @@ fi
|
||||||
if test -e ct-csv ; then
|
if test -e ct-csv ; then
|
||||||
echo "$fae"
|
echo "$fae"
|
||||||
else
|
else
|
||||||
curl -o ct-csv "https://${auth}doku.ccc.de/Spezial:Semantische_Suche/-5B-5BKategorie:Chaostreffs-5D-5D-20-5B-5BChaostreff-2DIs-2DErfa::falsch-5D-5D-20-5B-5BChaostreff-2DActive::wahr-5D-5D/-3FChaostreff-2DCity%3DLabel/-3FChaostreff-2DPhysical-2DAddress%3DAdresse/-3FChaostreff-2DPhysical-2DHousenumber%3DHausnummer/-3FChaostreff-2DPhysical-2DPostcode%3DPLZ/-3FChaostreff-2DPhysical-2DCity%3DStadt/-3FChaostreff-2DCountry%3DLand/mainlabel%3D/limit%3D100/order%3DASC/sort%3DChaostreff-2DCity/offset%3D0/format%3Dcsv/headers%3Dshow/searchlabel%3DCSV/sep%3D,/filename%3Dct-2Dbesuchsadressen.csv"
|
curl -k -o ct-csv "https://${auth}doku.ccc.de/Spezial:Semantische_Suche/-5B-5BKategorie:Chaostreffs-5D-5D-20-5B-5BChaostreff-2DIs-2DErfa::falsch-5D-5D-20-5B-5BChaostreff-2DActive::wahr-5D-5D/-3FChaostreff-2DCity%3DLabel/-3FChaostreff-2DPhysical-2DAddress%3DAdresse/-3FChaostreff-2DPhysical-2DHousenumber%3DHausnummer/-3FChaostreff-2DPhysical-2DPostcode%3DPLZ/-3FChaostreff-2DPhysical-2DCity%3DStadt/-3FChaostreff-2DCountry%3DLand/mainlabel%3D/limit%3D100/order%3DASC/sort%3DChaostreff-2DCity/offset%3D0/format%3Dcsv/headers%3Dshow/searchlabel%3DCSV/sep%3D,/filename%3Dct-2Dbesuchsadressen.csv"
|
||||||
fi
|
fi
|
||||||
if test -e erfa-csv ; then
|
if test -e erfa-csv ; then
|
||||||
echo "$fae"
|
echo "$fae"
|
||||||
else
|
else
|
||||||
curl -o erfa-csv "https://${auth}doku.ccc.de/Spezial:Semantische_Suche/-5B-5BKategorie:Erfa-2DKreise-5D-5D-20-5B-5BChaostreff-2DActive::wahr-5D-5D/-3FChaostreff-2DCity%3DLabel/-3FChaostreff-2DPhysical-2DAddress%3DAdresse/-3FChaostreff-2DPhysical-2DHousenumber%3DHausnummer/-3FChaostreff-2DPhysical-2DPostcode%3DPLZ/-3FChaostreff-2DPhysical-2DCity%3DStadt/-3FChaostreff-2DCountry%3DLand/mainlabel%3D/limit%3D100/order%3DASC/sort%3DChaostreff-2DCity/offset%3D0/format%3Dcsv/headers%3Dshow/searchlabel%3DCSV/sep%3D,/filename%3Derfa-2Dbesuchsadressen.csv"
|
curl -k -o erfa-csv "https://${auth}doku.ccc.de/Spezial:Semantische_Suche/-5B-5BKategorie:Erfa-2DKreise-5D-5D-20-5B-5BChaostreff-2DActive::wahr-5D-5D/-3FChaostreff-2DCity%3DLabel/-3FChaostreff-2DPhysical-2DAddress%3DAdresse/-3FChaostreff-2DPhysical-2DHousenumber%3DHausnummer/-3FChaostreff-2DPhysical-2DPostcode%3DPLZ/-3FChaostreff-2DPhysical-2DCity%3DStadt/-3FChaostreff-2DCountry%3DLand/mainlabel%3D/limit%3D100/order%3DASC/sort%3DChaostreff-2DCity/offset%3D0/format%3Dcsv/headers%3Dshow/searchlabel%3DCSV/sep%3D,/filename%3Derfa-2Dbesuchsadressen.csv"
|
||||||
fi
|
fi
|
||||||
# preprocess csv data
|
# preprocess csv data
|
||||||
for file in ct-csv erfa-csv ; do
|
for file in ct-csv erfa-csv ; do
|
||||||
|
|
Loading…
Reference in New Issue