Windows Service Installation

The BCP Controller can be deployed as a windows service. Please refer the Downloads and Artifacts page to locate the windows executable.

Download and extract the tar.gz into a target folder such as B:\BCPController\

Administrator Permissions Required for Service Install

You will need administrator privileges to Install the service.

Configuration and Environment

Please refer the environment configuration under the docker steps for an exhaustive list of variables you must set.

Add System variables via the control panel or associated cmd such as:

set [<variable>=[<string>]]
set [/p] <variable>=[<promptString>]
set /a <variable>=<expression>

Note

Ensure you set a LOG_DIR in the environment to ensure logs are destined for somewhere, if not they will register to Stdout and not be visible in Windows/Services.

Service Commands

The BCP Controller is integrated with the Windows Service Manager. Running the executable will provide you a list of support commands. These include.

  • Install
  • Remove
  • Debug
  • Start
  • Stop
  • Pause
  • Continue

Register the Service

bcpcontroller.exe install

Check installed services via Services.msc and look for "BCP Controller". Upon reboot, this service will automatically start based off the environment configuration.

Note

The service is not fully integrated with Windows Event logs, thus only reports status events like start/stop/failed.

Start the Service

Once the environment is configured, you can start the service via Services.msc > BCP Controller > Start

Monitor the logs folder configure before hand such as

B:\BCPController\Logs\bcpcontroller_$date.log

Windows Firewalls

Ensure that a Windows Firewall permits the following traffic:

  • TCP/8080 ( Inbound )
  • TCP/443 ( Outbound )

Next Steps

  • Deploy a load balancer, reverse proxy or API gateway to pass all traffic
  • Create a public facing DNS/endpoint such as https://mycontroller.company.com that directs all HTTP traffic

Startup Logs Example

{"Product":"BCPController","level":"info","msg":"Starting router on port: 8080","time":"2022-07-12T00:13:49+10:00"}
{"Product":"BCPController","level":"info","msg":"NewPostgresClient connected","time":"2022-07-12T00:13:49+10:00"}
{"Product":"BCPController","level":"info","msg":"HealthCheckHandler :: HealthCheck OK","time":"2022-07-12T00:14:47+10:00"}
{"Product":"BCPController","level":"info","msg":"DeepHealthCheckHandler :: HealthCheck OK","time":"2022-07-12T00:14:47+10:00"}