To deploy Stonefield Query Enterprise on a web server, use the Publish Project function in the File menu.

You have two choices about where to deploy Stonefield Query:

  • FTP site: if you want to deploy to a remote web server, choose FTP site and specify the FTP settings to connect to the server: server address, the path for the Stonefield Query files, the user name, and the password.

  • Folder: if you want to deploy to a virtual directory on the current machine, choose Folder and select the directory where the Stonefield Query files should be copied to. This is also useful if you want to create a staging folder to deploy the files on another system. For example, to deploy to a Microsoft Azure server, you can publish to a local folder on your system, then copy the files to the Azure server. See the Publish to Microsoft Azure section below for details.

If you turn on the Publish only the contents of Project_Data, the publish process only copies the contents of that folder. This is a much smaller upload when the only changes are to project data, not to program files. Note that this is only useful if your data dictionary is stored in a SQLite database; see the note below.

After specifying the settings, click OK to start the publishing process.

Uploading to an FTP site may take a little while as there are lots of files to deploy.

Although the publish process also deploys your Project_Data folder, if your project's data dictionary is stored in something other than a SQLite database, you have to install that database yourself.

The publish process automatically shuts down the application pool on the web server before copying files so you don't have to do it manually. It does that by creating a file called app_offline.htm in the SQWeb folder. This file is copied from app_offline.htm in the Data subdirectory of the Stonefield Query Enterprise program folder, so you can modify the contents of that file as desired to show a custom "offline for maintenance" message. The application pool is automatically restarted the next time someone access it in their browser.

Regardless of whether the web site is on the current or a remote system, the following settings are required for the web server:

  • Turn on SSL since Stonefield Query requires that.

  • Enable read and write access to the App_Data, Licenses, and Logs folders.

  • Configure Execute Permissions to scripts and executables.

Publishing to Microsoft Azure

The simplest way to publish to a Microsoft Azure server is to publish to a local folder first, then copy the files from the local folder to the Azure server. Follow these steps:

  • Make sure the Remote Desktop Connection (RDP) to connect to the Azure server is configured to allow access to a drive on the local system. To do that, right-click the RDP file and choose Edit from the shortcut menu. Select the Local Resources tab, click the More button, and turn on one or more local drives.

  • In Studio, choose Publish Project from the File menu, select Folder, and specify a folder on one of the local drives you chose in the previous step.

  • Double-click the RDP file to connect to the Azure server.

  • Create a new site for SQWeb using IIS Manager.

  • Using Windows Explorer, copy the files from the local publish folder to the virtual directory for SQWeb on the Azure server.

Publishing to a Microsoft Azure web site

Publishing to a Microsoft Azure web site is straightforward:

  • In the Dashboard for the Azure web site, create deployment credentials. Also, make note of the FTP host name setting, which is the FTP server to upload files to.

  • In Studio, choose Publish Project and select FTP Site. Enter the FTP host name noted in the previous step (omitting the "ftp://" prefix) for Server. For Path, enter "site/wwwroot.". Enter the user name and password you specified when setting up the deployment credentials.