Skip to content

Commit bf1d544

Browse files
committed
init
1 parent 31576a7 commit bf1d544

File tree

3 files changed

+11
-4
lines changed

3 files changed

+11
-4
lines changed

README.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Azure Logic App - Long-Term Github Stats
1+
# Azure Logic App: Long-Term Github Stats
22

33
Github only tracks 14 days worth of traffic data for each repository. There are a few other projects out there that use C#, Python and other langauges to pull the data locally but I wanted to run this serverless in Azure which is why I created this solution.
44

@@ -11,7 +11,7 @@ This ARM template will deploy the following:
1111

1212
The Logic App is triggered daily, and pulls the PAT from the key vault, queries the Github API, parses the JSON, and stores it in Table Storage.
1313

14-
After the data is loaded into Table Storage you can do whatever you'd like with it. I am visualizing it in PowerBI desktop (template in progress).
14+
After the data is loaded into Table Storage you can do whatever you'd like with it, though i've included a basic PowerBI template to visualize the data using PowerBI desktop.
1515

1616
This solution should cost less than $0.05/month (I'll update this statistic once I've run it longer, as of Dec 31, 2020 I've had it running for 4 days and it's cost me $0.01).
1717

@@ -26,5 +26,6 @@ This solution should cost less than $0.05/month (I'll update this statistic once
2626
- Once complete, you will need to open the API connection for keyvault, go to "Edit API" and click the blue bar that says "Authorize". You'll be presented with a pop-up sign-in box for a one-time authentication to link the connector to KeyVault. Click save after you're done.
2727
- Open the Logic App, and click "Run Trigger" (the first run will have failed becuase the connector wasn't authorized so you'll see that in the run history).
2828
- You can verify the data by going to the storage account and viewing the table storage using Storage Explorer.
29+
- Open the PowerBI template, enter your storage account name and account key (account keys tab on the storage account in the portal) and your data should show up on the dashboard.
2930

3031
[![Deploy To Azure](http://azuredeploy.net/deploybutton.png)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FMattHansen0%2Flogicapp-githubstats%2Fmain%2Fazuredeploy.json) [![Visualize](http://armviz.io/visualizebutton.png)](http://armviz.io/#/?load=https%3A%2F%2Fraw.githubusercontent.com%2FMattHansen0%2Flogicapp-githubstats%2Fmain%2Fazuredeploy.json)

azuredeploy.json

+8-2
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,17 @@
3939
},
4040
"clonesURI": {
4141
"type": "string",
42-
"defaultValue": "https://api.github.com/repos/matthansen0/azure-dnslb/traffic/clones"
42+
"defaultValue": "https://api.github.com/repos/matthansen0/azure-dnslb/traffic/clones",
43+
"metadata": {
44+
"description": "Replace the username and repo with yours." }
45+
4346
},
4447
"trafficURI": {
4548
"type": "string",
46-
"defaultValue": "https://api.github.com/repos/matthansen0/azure-dnslb/traffic/views"
49+
"defaultValue": "https://api.github.com/repos/matthansen0/azure-dnslb/traffic/views",
50+
"metadata": {
51+
"description": "Replace the username and repo with yours."
52+
}
4753
}
4854
},
4955
"variables": {

githubStats_template.pbit

16.3 KB
Binary file not shown.

0 commit comments

Comments
 (0)