Program Update Notifications

Is there a way to be notified when a new update to the program is released? CTW works so well I often forget it is there and, as such, I didn’t do the 5.5 update and ran into some issues with some devices when the R3 expiration happened.

I’ll ask a different question. What about adding some sort of auto-update feature? I hope to figure out a way to keep it updated using Datto RMM which is currently my poison of choice.

Hi,

We don’t currently have a specific way to do that actually, but it is a good idea.

Our API actually provides update information, which you could act upon: https://api.certifytheweb.com/v1/update

Alternatively perhaps there is a way to auto update based on our Chocolatey package Chocolatey Software | Certify The Web (Install) 5.5.5

@nsumner regarding auto updates, we’d be leaning towards providing a powershell (etc) script that you can set as a scheduled task, rather than building in auto update to the app (yet another service etc). It would need to check the above update API, compare the installed version and download + silent install but it would only work if the app (UI) isn’t currently in use. Stopping the service is easy, stopping the UI in a different desktop session is trickier I think. Even then you’d probably want to configure a wait time (like 1 week) after last update before auto-updating.

I just created a package for Datto RMM here is the PowerShell that I am using. Datto delivers the file but it wouldn’t be hard at all to make the Script fetch the file. I would need to figure out exactly how to use the API to get the version and therefore have it able to autoupdate itself etc. But this seems to work nicely to at least update to a said version.

#This script was written by Noach Sumner @ Citybook Services Ltd.

#This script was basically lifted off the Chocolately package which is maintained by the developer so hopefully it is pretty good.

#Lets specify the install file to make things easy when we need to upgrade

#To protect you from running an executible by accident PS won’t run it unless you give a path IE add .\ before the filename

$Installer = ‘.\CertifyTheWebSetup_V5.5.5.exe’

#First things first is we need to close Certify The Web in all ways possible.

Close the UI window if currently open

Get-Process | Where-Object {$.ProcessName -eq ‘Certify.UI’} | Foreach-Object { $.CloseMainWindow() | Out-Null } | stop-process -force

Stop the Certify.Service background service

Get-Service Certify.Service | Where {$_.status -eq ‘Running’} | Stop-Service

Now we can specify the arguments we wish to run on the install. Again Shamelessly stolen from Chocolatey

$SilentArgs = ‘/VERYSILENT /SUPPRESSMSGBOXES /NORESTART /SP-’

Finally we can install

Start-Process -FilePath $Installer -ArgumentList “$SilentArgs”

Yeah, so a little like our update script for choco: https://github.com/webprofusion/certify/tree/development/scripts/chocolatey/tools

Here is a quick script to parse the update info and get to a few key properties:

$updateInfo = Invoke-WebRequest -Uri https://api.certifytheweb.com/v1/update -UseBasicParsing | ConvertFrom-Json

$updateInfo.version
$updateInfo.message.downloadFileURL
$updateInfo.message.sha256

Definitely a little like the chocolately script which as I acknowledge (even for my internal use) I borrowed liberally from.

Awesome. That makes it worth refactoring the script and downloading from the Internet I think (not really that complicated obviously).

The first part of course is to convert it into a script that runs on a schedule, and just checks if it is up to date. Only shame is I can’t do that check server side as far as I know with Datto. But honestly it isn’t like that is really burning CPU cycles.

Yeah I think I’ll do a similar script to distribute with Certify that can be set as a scheduled task, that way updates can also update the updater script.

Here is a proposed script for auto updates:

The user (perhaps via the app) would create a windows scheduled task (daily etc) to run this script. The script will then:

  • Check the current release
  • Compare to the installed version

If an update is available and considered stable (available for 7 days or more):

  • Download latest update to a random temp folder, compute file hash and check it
  • Stop the current Certify processes
  • Perform the install
  • Clean up temp files