Using Blinkstick to check for SSL / Domain renewals (O365) guide


#1

Hi There,
I hope you find this useful.
I brought my blinkstick square to tell me when SSL/Domain renewals are coming up.
To do this I setup the 2.0 client and setup a public access key so I can manipulate the LED via the webhook (I followed the IFTTT guide on this site).
However, O365 is now offically a pain to use with IFTTT thanks to the grid api.
So, I use microsoft Flow:
https://us.flow.microsoft.com
I find out my O365 calender ID using powershell:

Connect-MsolService

Invoke-RestMethod -Uri “https://outlook.office365.com/api/v1.0/me/calendars” -Credential $UserCredential | ForEach-Object { $_.Value } | Select-Object -Property Name, ID

As I want to use a special ‘renewals’ calendar for this to keep it clean.

Then I create a flow, that checks my calender:

Then in the yes condition I put a loop

This loop keeps checking in case the device gets unplugged, or the PC is switched off, it essentially rechecks every 15 mins (I have 1 min in the screenshot for testing), then it grabs the eventID again (checks for changes) and the escape clause up the top is when the subject does not contain the word renewal (so I can change the renewal word to done to escape the loop)

Then of course the last action is to switch off the LEDs

So no more worrying about renewals right - wrong!

What if the blinkstick/MS Flow server does down and no notification - say in 10 years?

well. Thats nice, when it works - so …

I use LEDs 0 - 4 for this, turning them red. But I use LEDs 5 to 7 via Microsoft flow, to turn them green for 1/2 hour each morning. So one morning if they are not green then I know its busted.

Why did I do this?

Notifications are too fast usually! I set this loop up to notify me 1 week in advance of the event start date (10080 minutes). So my SSL certificates are renewed on time, via a BIG RED LIGHT!

Thanks blinkstick!


#2

boring bits:

The 2 different LED sets:

image


#3

boring bits 2:

The simple is it all healthy checking tool: