How to enable application services in a Container (Service)

The Auto Packager does not configure support for services  automatically, when packaging an application that includes a service, a  run action must be configured in a Run Condition within the programs.xml

  1. Open AppAcceleratorV.clc
  2. Add the Service feature

    <Features>
      <Feature>Service</Feature>
    </Features>
  3. Open Programs.xml
  4. Add a new program and adjust the arguments to point to the executable.
  5. Set the RunCondition as Always.

    <Program ProgramOrder="1">
      <Path>%DefaultDir%\AppAcceleratorV.exe</Path>
      <Args>/f %DefaultDir%\ProgData\Service.exe</Args>
      <WorkingDirectory/>
      <RunCondition>Always</RunCondition>
      <ProcessWindowStyle>Normal</ProcessWindowStyle>
      <WaitCondition>None</WaitCondition>
    </Program>

Service APIs Hooked

  • StartServiceCtrlDispatcherA
  • StartServiceCtrlDispatcherW
  • SetServiceStatus
  • OpenSCManagerA
  • OpenSCManagerW
  • OpenServiceA
  • OpenServiceW
  • CloseServiceHandle
  • StartServiceA
  • StartServiceW
  • QueryServiceConfigA
  • QueryServiceConfigW
  • RegisterServiceCtrlHandlerA
  • RegisterServiceCtrlHandlerW
  • RegisterServiceCtrlHandlerExA
  • RegisterServiceCtrlHandlerExW
  • QueryServiceStatus
  • QueryServiceStatusEx
  • ControlService
  • GetServiceDisplayNameA
  • GetServiceDisplayNameW

Applies To

Cloudhouse Containers

Was this article helpful?

Can't find what you're looking for?

Contact Support