A Twitter bot tracking COVID-19 Vacciation numbers in Hungary.
Nothing fancy, just a simple Twitter bot running as an Azure Function.
# just simply
go build -o hucovidtracker
Deploy as an Azure Function.
-
Create an account
-
Create a resource group
deploy_region="westeurope" deploy_group="go-custom-function" az group create -l $deploy_region -n $deploy_group
-
Build
-
Create resources for Azure Function from deployment ARM (Azure Resource Management) template.
az deployment group create --resource-group $deploy_group --template-file azuredeploy.json
-
Set API keys and secrets @ portal.azure.com.
$deploy_group > azure function > Settings|Configuration > New application settings x 4
-
Deploy
func azure functionapp publish `[function name/ID]` --no-build --force
Simple 3-step prepation and tweet
- Fetch last tweet (needs bootstrapping the account) and parse last reported number
- Fetch latest vaccincation number from country specific source
- Fetch population from wikimedia
- Tweet status update