Windows
Of course your Remoting SDK servers can be run on Windows, in 32- and 64-bit, whether they were created using .NET or Delphi.
Installation
Remoting SDK Servers can be "xcopy-deployed", meaning that they don't need an install procedure, but instead you can just copy all the relevant files necessary to a folder of your choice (be it manually or in an automated fashion), and then run the server application from there.
.NET Servers
Delphi Servers
In most cases, deployment requires only your server executable, e.g. MyServer.exe
. If you are building with runtime packages, you may also need to deploy the relevant .bpl
files, as well. Of course, if your server app makes use of any other additional libraries, resources, configuration files or the like, outside of the scope of Remoting SDK, you will need to deploy those, too.
Running
There are three options for launching your Remoting SDK Server on a Windows system: by direct execution either from the command line or as as GUI application, or as true background "Windows NT" Service.
Running in Command Line Mode
To launch your server in command line mode, simply launch the .exe
with the --commandline
parameter from a Command Prompt (cmd.exe
) window:
MyServer.exe --commandline
Note: Delphi applications use /commandline
parameter instead of --commandline
.
Your server will start immediately, and print informational details (such as a start-up message, and any logging messages you might emit yourself) to the shell. The shell will be blocked running the server, until you quit it by pressing Enter or ^C", or until the server quits on its own.
Running in command line mode is great when testing or debugging, and to get the server up and running quickly. But the downside is that if you close the Command Prompt window, the server will be stopped, as well.
Running as GUI Application
You can also launch your server as simple Windows GUI application, by just running the .exe
without any parameters (or by double-clicking it in Explorer).
Again, your server will start immediately, and by default show a small window with the Remoting SDK Logo (of course you can customize how this looks, or provide your own UI if needed). Your server will be active as long as you keep the application running.
Running in this mode is another great way to test or debug your server app quickly.
Running as Windows NT Service
For true "head-less" deployment, you can also configure your server to run as "Windows NT" Service. In this mode, your server can start on its own in the background, even when no user is logged into the server; it can be controlled using the common mechanisms for Windows Services, such as the netctl
command line tool, and the Services Snap-in in the Management Console, available from right-clicking "(My) Computer" in Explorer and choosing "Manage".
While normally a lot of manual code is needed to make an application work as Windows Service, Remoting SDK takes care of all of this for you. You can run your .exe
with the --install
command line parameter to install it as service, and then use the above-mentioned Windows-provided tools to start, pause and stop your server, and to configure whether it will start automatically when then system boots.
MyServer.exe --install
Note: Delphi applications use /install
parameter instead of --install
.