Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Deploy web application as a standalone executable

I have a web application that I developed with the Google Web Toolkit (GWT), it is a utility application that helps make calculations when planning specific server deployments. I want to be able to offer this application as a download on my website for people that want to use the application but don't always have internet access.

I was previously able to achieve this by packaging all of files that GWT compiles (html and js) into a Nullsoft Installer Script (NSIS) that would just extract them to a temp directory and then tell Windows to open the main html file with whatever browser was the default.

Recently this has given me problems, it seems that some browsers don't mind this at all while others have their own quirks and problems rendering the application useless.

This application only makes 1 server call to fetch a xml file that contains the configuration data for how the calculations should be made. There is a small php component that allows the user to save and load previous configurations but it is not a problem to disable this feature for offline standalone executable deployment.

So my question is this, is there an existing framework that would allow my to package my application along with an embedded webserver so that when the application is ran it actually is running on a local web server? Or is there an existing framework to embed a web application into a redistributable browser, so that when the user tries to open the application it automatically opens the packaged browser, that way I could be able to fine tune the offline experience to always work as desired with the packaged browser.

Thanks for any replies

like image 476
snctln Avatar asked Sep 08 '10 20:09

snctln


People also ask

How do you make an EXE file standalone?

If you want to make a standalone program, you should create a new Setup project in your solution. Include the Primary Output from your application project, and the setup should include the required DLL's automatically. Once you build the setup project, you can install your application as a standalone software.

What is ClickOnce deployment?

ClickOnce is a deployment technology that enables you to create self-updating Windows-based applications that can be installed and run with minimal user interaction.

How does App_offline HTM work?

The App Offline file ( app_offline. htm ) is used by the ASP.NET Core Module to shut down an app. If a file with the name app_offline. htm is detected in the root directory of an app, the ASP.NET Core Module attempts to gracefully shut down the app and stop processing incoming requests.


2 Answers

If IE is not one of the trouble browsers, you could create a small .NET app that embeds a web browser control and opens it to the desired page.

You might even be able to achieve this using Gecko:

http://code.google.com/p/geckofx/

like image 78
webbiedave Avatar answered Nov 07 '22 04:11

webbiedave


I upvoted this as it's something I'd be very interested in finding a solution for. This was literally just on my mind a day ago. From what I figured, deploying a web app that requires some type of stand-alone web server to process the files just isn't possible. You said it's mainly in JavaScript and you wouldn't mind killing the PHP functionality - in this case Adobe AIR might be a simple solution (syntax is very similar to JS, should be a quick conversion if you're familiar with it). Basically though - from my understanding - you'll have to port it.

like image 40
Mahdi.Montgomery Avatar answered Nov 07 '22 04:11

Mahdi.Montgomery