Advice on auto-updating client-server app - Advanced Installer Community
mathieu
Posts: 14
Joined: Thu Oct 23, 2014 9:06 am

Advice on auto-updating client-server app

Hello everyone,

We're currently investigating advanced installer to replace our existing NSIS installer for our solution and additionally provide auto-update to our customers under maintenance.
Since our customers are big industrial companies with strong security policies, most of the time, the clients workstations shall not have access to internet, and thus to the "update package repository" we'd like to set up.
However, servers will have an internet connection 100% of the time.
It's a complex client-server application and here is the question I couldn't answer reading the (very nice) documentation you provide :
Is there a way, preferably integrated to the upgrade process to provide the updates to the client using the server as an "in house repository".

Here would be the scenario :
1) the server checks for updates
2) the server download the update and install it to update itself
3) the server then store everything that is necessary in an in-house shared folder for the clients to access it
4) the clients can then detect a new update "approved" by the IT since it's in the "in-house pkg repo"
5) the clients download and install the update from there without the need for an internet connection

1) and 2) are very well documented.
3) is the big question.
4) and 5) could apparently be achieved with the "-url" option to the updater ( see : http://www.advancedinstaller.com/user-g ... dater.html )

Maybe this is not the best way to do it. If any other scenarios are possible, feel free to explain it.

Thanks
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Advice on auto-updating client-server app

Hi and welcome to Advanced Installer forums.

Thank you for your interest in Advanced Installer.

When an update is downloaded and installed all the necessary files are placed in the folder specified in the "Download updates in this folder" field from the "Updater" page. By default that folder points to the following location, but it can be changed:

Code: Select all

C:\ProgramData\Your Company\Your Application\updates\
In that folder the updates configuration file will be placed with the extension ".aiu" and a folder "Updates" will be created next to it, that will contain the resources of the update.

So, when the clients will try to update their applications they will be able to use a command line like in the example below:

Code: Select all

updater.exe /checknow -url "file://C:\ProgramData\Your Company\Your Application\updates\updates.aiu"
But in the "updates.aiu" file is the URL that points to the new version of the application. That URL can be modified, manually or through a script, by the system administrator to point to the resources found in the "Updates" folder.

Let us know if this helped, otherwise give us more details about your scenario.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
mathieu
Posts: 14
Joined: Thu Oct 23, 2014 9:06 am

Re: Advice on auto-updating client-server app

Ok first thank you for your quick answer.
This is definitely the type of process I was looking for.

So the only remaining obstacle is that we would need to modify our *.aiu file in order to reference the path to the *.msi in the local network.
One question, does the "URL" key in that file support "relative paths" from the location of the *.aiu file itself?
We could then have a file structured like the following :

Code: Select all

;aiu;

[story2.0]
Name=Story 2.0
URL=/updates/story2.0.msi
Size=43256
ServerFileName=story2.0.msi
RegistryKey=HKLM\SOFTWARE\Story Teller\Long Story\Version
Version=2.0.0
Description=This fixes some spelling errors in story.txt file.
The auto updater would then automatically search the file on the local network relatively to the location of the local *.aiu file.

If it doesn't support this behaviour, is there a way to "trigger" an action after update that would modify this file.

Thanks again.
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Advice on auto-updating client-server app

Hi,

I'm afraid that the "URL" from the ".aiu" file does not support relative path. However, you can, indeed, add a custom action in your package that will modify the "updates.aiu" file after the installation.

To achieve this, you can create your own custom action that modifies the URL of that file, then add it in the "Custom Actions" page after the "Add Resources" action group.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”