-
Notifications
You must be signed in to change notification settings - Fork 15
Windows Services Config Examples
These examples demonstrate how the Services segment can handle complex real-world scenarios while maintaining portability and system stability.
To make use of the Service segment, add the section [Service1] (numerical ordering) to the Launcher.ini file.
Each entry supports the following keys:
Name - The local/portable service name.
Path - The path to the portable service executable. Supports environment variables.
Type - Specify whether you are dealing with a service, a kernel driver or a file system driver, etc.
Choose from: own, share, interact, kernel, filesys, rec, adapter
Start - Specify when the service is supposed to start.
Choose from: boot, system, auto, demand, disabled, delayed-auto
Depend - List any dependencies here separated by / (forward slash).
IfExists - If the service already exists, you can either skip it or replace it with the portable version of the service.
Choose from: skip, replace, backup
Description - Optional service description
Account - Optional service account (LocalSystem, LocalService, NetworkService, or custom)
Password - Password for custom account (if Account is specified)
Timeout - Timeout in seconds for service operations (default: 30)
Critical - If true, failure to start this service will show a warning (true/false)
[Service1]
Name=ServiceName
Path=%PAL:DataDir%\Service_driver.sys
Type=kernel
Start=system
Depend=
IfExists=replace
Description=My Portable Service
Timeout=45
Critical=true
This example shows how to configure a portable database service that runs under a specific service account with dependencies.
[Service1]
Name=PortableMySQL
Path=%PAL:AppDir%\MySQL\bin\mysqld.exe --defaults-file="%PAL:DataDir%\mysql\my.ini"
Type=own
Start=auto
Depend=tcpip
IfExists=replace
Description=Portable MySQL Database Server
Account=NT AUTHORITY\NetworkService
Password=
Timeout=60
Critical=trueKey Features:
- Uses NetworkService account for better security
- Depends on TCP/IP stack
- Marked as critical (will show warnings if it fails)
- Extended timeout for database initialization
- Replaces any existing MySQL service
This shows a VPN service that requires multiple system services to be running first.
[Service1]
Name=PortableVPN
Path=%PAL:AppDir%\VPN\vpnservice.exe
Type=own
Start=demand
Depend=RasMan/TapiSrv/PlugPlay/Ndisuio
IfExists=backup
Description=Portable VPN Connection Manager
Account=LocalSystem
Password=
Timeout=45
Critical=trueKey Features:
- Multiple dependencies separated by forward slashes
- Uses "backup" mode (stops existing service but doesn't delete it)
- Demand start (starts only when needed)
- Longer timeout for network initialization
This example shows how to install a portable device driver.
[Service1]
Name=PortableDriver
Path=%PAL:AppDir%\Drivers\mydriver.sys
Type=kernel
Start=system
Depend=
IfExists=replace
Description=Portable Hardware Driver
Account=
Password=
Timeout=30
Critical=falseKey Features:
- Kernel-mode driver service
- System start (loads during boot sequence)
- No dependencies or custom account needed
- Not marked as critical (won't show warnings)
This shows a more complex driver scenario for file system filtering.
[Service1]
Name=PortableFilter
Path=%PAL:AppDir%\Filters\fsfilter.sys
Type=filesys
Start=boot
Depend=FltMgr
IfExists=skip
Description=Portable File System Filter Driver
Account=
Password=
Timeout=20
Critical=trueKey Features:
- File system filter driver
- Boot start (loads very early in boot process)
- Depends on Filter Manager (FltMgr)
- Skip mode (won't install if already exists)
- Critical driver (important for app functionality)
This example demonstrates using a custom domain/local account.
[Service1]
Name=PortableAppService
Path=%PAL:AppDir%\Service\appservice.exe
Type=own
Start=auto
Depend=
IfExists=replace
Description=Portable Application Service
Account=DOMAIN\ServiceAccount
Password=SecurePassword123
Timeout=30
Critical=trueKey Features:
- Custom domain service account
- Password authentication
- Auto-start service
- Will replace any existing version
For older applications that need to interact with the desktop.
[Service1]
Name=PortableLegacyApp
Path=%PAL:AppDir%\Legacy\legacyservice.exe
Type=interact
Start=demand
Depend=
IfExists=skip
Description=Legacy Interactive Service
Account=LocalSystem
Password=
Timeout=60
Critical=falseKey Features:
- Interactive service type (deprecated but sometimes needed)
- Demand start for on-demand usage
- LocalSystem account for desktop interaction
- Skip if already exists (don't interfere with existing installs)
For applications that install virtual network adapters.
[Service1]
Name=PortableAdapter
Path=%PAL:AppDir%\Network\netadapter.exe
Type=adapter
Start=demand
Depend=Tcpip/AFD
IfExists=replace
Description=Portable Network Adapter Service
Account=LocalSystem
Password=
Timeout=40
Critical=trueKey Features:
- Adapter service type for network components
- Depends on TCP/IP and Ancillary Function Driver
- Demand start (activated when network is used)
- Replace existing adapters
This shows how to configure multiple services that depend on each other.
[Service1]
Name=PortableCore
Path=%PAL:AppDir%\Core\coreservice.exe
Type=own
Start=auto
Depend=
IfExists=replace
Description=Portable Application Core Service
Account=LocalService
Password=
Timeout=45
Critical=true[Service2]
Name=PortableWorker
Path=%PAL:AppDir%\Worker\workerservice.exe
Type=own
Start=auto
Depend=PortableCore
IfExists=replace
Description=Portable Worker Service
Account=LocalService
Password=
Timeout=30
Critical=falseKey Features:
- Service2 depends on Service1
- Both use LocalService account
- Core service is critical, worker is not
- Auto-start for both services
For applications requiring elevated security.
[Service1]
Name=PortableSecure
Path=%PAL:AppDir%\Secure\secureservice.exe
Type=own
Start=demand
Depend=CryptSvc/KeyIso
IfExists=backup
Description=High-Security Portable Service
Account=NT SERVICE\PortableSecure
Password=
Timeout=90
Critical=trueKey Features:
- Virtual service account (NT SERVICE\ServiceName)
- Depends on cryptographic services
- Backup mode (preserves existing service)
- Extended timeout for security initialization
- Critical service with enhanced error reporting
Using the enhanced error handling for conditional logic.
[Service1]
Name=OptionalService
Path=%PAL:AppDir%\Optional\service.exe
Type=own
Start=disabled
Depend=
IfExists=skip
Description=Optional Portable Service
Account=LocalService
Password=
Timeout=30
Critical=falseKey Features:
- Disabled start (installed but not started automatically)
- Skip existing (won't interfere with user's choice)
- Not critical (failures won't show warnings)
- Can be started manually when needed
- Drivers: 20-30 seconds
- Database Services: 60-120 seconds
- Network Services: 30-60 seconds
- Simple Services: 15-30 seconds
- LocalSystem: Full system access (use carefully)
- LocalService: Limited local access (safest for most services)
- NetworkService: Network access with limited local rights
- Custom Account: When specific permissions are needed
- skip: For optional or user-configured services
- replace: For core application services
- backup: For services that might be shared with other apps
- Always list dependencies in order of initialization
- Use forward slashes (/) to separate multiple dependencies
- Consider both direct and indirect dependencies
- Test dependency chains thoroughly
Launcher.ini Config Examples