docker_weather/README.md

27 lines
869 B
Markdown
Raw Normal View History

2023-09-22 08:21:01 +03:00
<h1>Säätiedot! Weather!</h1>
2023-10-18 09:57:24 +03:00
Perustuu wttrin sääpalveluun: https://github.com/chubin/wttr.in
2023-09-20 23:28:10 +03:00
2023-10-18 09:57:24 +03:00
Kloonaa kansio:
2023-10-18 12:14:28 +03:00
<code>git clone http://88.114.1.82:3000/RikuSi/docker_weather.git</code>
2023-09-21 00:41:38 +03:00
2023-10-18 09:57:24 +03:00
Mene kansioon:
2023-10-18 12:14:28 +03:00
<code>cd docker_weather</code>
2023-09-20 23:28:10 +03:00
2023-10-18 09:57:24 +03:00
Pura kansio:
2023-10-18 12:14:28 +03:00
<code>unzip weather-image.tar.zip</code>
2023-09-20 23:28:10 +03:00
2023-10-18 09:57:24 +03:00
Lataa kontti Dockeriin:
2023-10-18 12:14:28 +03:00
<code>sudo docker load -i weather-image.tar</code>
2023-09-20 23:28:10 +03:00
2023-10-18 12:18:04 +03:00
Aika tiedot (TZ) löytyy täältä: [https://en.wikipedia.org/wiki/List_of_tz_database_time_zones]
2023-09-22 08:27:57 +03:00
2023-10-18 12:14:28 +03:00
Käynnistä kontti:
<code>sudo docker run -d --name weather -e LATITUDE="61.4981" -e LONGITUDE="23.7608" -e MAX_RESULTS="10" -e TZ="Europe/Helsinki" -p 8600:80 weather-image</code>
2023-09-20 23:28:10 +03:00
2023-10-18 12:14:28 +03:00
Käynnistä kontti tietokoneen käynnistyessä:
<code>sudo docker update --restart unless-stopped weather</code>
2023-09-20 23:28:10 +03:00
2023-10-18 09:57:24 +03:00
http://localhost:8600
2023-09-20 23:28:10 +03:00
2023-10-18 09:57:24 +03:00
Scripti joka hakee tiedot päivittyy 10 min välein.
Selain päivittyy 5 min välein