We have built a .NET Windows Service that we install on client PCs to monitor and upload data (via a web service) from those PCs. I am looking for a way to update the windows service on all client PCs centrally — without having to remote into each store.
Here are some specifics (although, I
don’t think this really matters):
- Windows Service: .NET version 2 (due to client PC constraints) –
VB.NET- Web Service: .NET version 4 – VB.NET
- Client PCs OS: Win2000 to Win7, POSReady, WEPOS
Some extra information
- We have a setup file that works very well, but we need to remote into each store to run it. And there are 100s of stores!
- We had considered putting the setup file on an FTP site, but was told that Windows Embedded OSes did not support FTP, so we might send the file via a web service
- Once every minute each windows service calls a web service method that returns an some XML, which can be used to send an instruction to update the web service.
This seems like a standard problem that developers would have needed to solve many times already. If anyone has any advice or can suggest a process that they use, it would really help us.
UPDATE
- I can change both the Windows service and the web service to add this new updating functionality
- Looks like I have a way to get the setup file (downloading from a web service method), but what about running it? How do I run the installer and then make sure that the Windows service has shut down? Does the installer do that or the Windows service?
If you have a web service, you can add a method for the update.
Create a little update installer or application (that you would run locally).
Then in the web service add a method that returns a Stream or byte[] array.
In the web service’s method read the binary installer file into the byte[] array or stream, and send it to the client.
Then have the client save that stream into a file, and now you have the installer on the client machine.
All that’s left to do is run that process and update the service.