Publishes the weather conditions of Umuttepe and the live camera frames from kocaeliyiseyret.com on Twitter.
Uses Serverless Framework and deployed to Azure Function App.
In prod. Twitter account: @umuttepedehava
Kocaeli University's central campus is located in Umuttepe. Umuttepe is one of the places that have unstable weather conditions compared to Izmit Centre because of its 1276 feet (389 meters) altitude.
- Serverless Framework
- OpenCV
- m3u8
- tweepy
In v1, the app was refactored with Serverless Framework.
OpenCV
helps to convert m3u8 stream segments to frames.
The tweet contains a weather summary from umuttepe-hava.vercel.app/api/weather and two frames from the live camera data from kocaeliyiseyret.com. Tweets are published using tweepy
.
umuttepe-hava-botu requires Python 3.8+ with dependencies to run. It needs a Twitter Developer account and a Redis service.
Clone git repo
git clone https://github.com/sinanbekar/umuttepe-hava-botu
cd umuttepe-hava-botu
Rename .env.example to .env, edit Twitter Developer API keys and Redis environment variables.
Install the dependencies
yarn install
poetry install
For testing
poetry run test
To deploy to Azure, see: https://www.serverless.com/framework/docs/providers/azure/guide/quick-start https://www.serverless.com/framework/docs/providers/azure/guide/credentials
yarn deploy # dev stage
yarn deploy --stage production # production
kocaeliyiseyret.com's contents are copyrighted by Kocaeli Metropolitan Municipality. weather.com crawled data are also used in this project.
Use as only for educational purposes. Use at your own risk.
Please feel free to share any ideas.
MIT