Installer
This directory contains installer packages and build scripts for deploying Colibri Server as a system service on Linux, macOS, and Windows.
Overview
The installer system provides:
Configuration file support:
server.conffor easy configuration managementSystem service integration: systemd (Linux), LaunchDaemon (macOS), Windows Service
Automatic startup: Server starts automatically on system boot
Security: Services run with restricted permissions
Firewall rules: Automatic configuration for the server port
Directory Structure
installer/
├── config/
│ ├── server.conf.template # Template with placeholders
│ └── server.conf.default # Default configuration
├── scripts/
│ ├── systemd/ # Linux systemd service
│ ├── launchd/ # macOS LaunchDaemon
│ └── windows/ # Windows service scripts
├── linux/
│ ├── debian/ # Debian/Ubuntu package files
│ ├── rpm/ # RPM package specs
│ ├── build_deb.sh # Build Debian package
│ └── build_rpm.sh # Build RPM package
├── macos/
│ ├── scripts/ # Pre/post-install scripts
│ └── build_pkg.sh # Build macOS .pkg
└── windows/
├── colibri.wxs # WiX installer definition
├── build_installer.ps1 # Build MSI installer
└── install_service.ps1 # Manual service installationConfiguration File
The server can be configured via server.conf file in addition to environment variables and command-line arguments.
Priority order (lowest to highest):
Default values (hardcoded)
Config file (
/etc/colibri/server.confon Linux)Environment variables
Command-line arguments
Config file locations:
Linux:
/etc/colibri/server.confmacOS:
/usr/local/etc/colibri/server.confWindows:
%PROGRAMDATA%\Colibri\server.conf(usuallyC:\ProgramData\Colibri\server.conf)
Configuration Parameters
See config/server.conf.default for all available options:
PORT- HTTP server port (default: 8090)CHAIN_ID- Blockchain ID (1=Mainnet, 11155111=Sepolia, 17000=Holesky)RPC- Comma-separated RPC endpointsBEACON- Comma-separated Beacon API endpointsMEMCACHED_HOST/MEMCACHED_PORT- Memcached configurationAnd many more...
CMake Build Flag
The INSTALLER Flag
Installer packages are built using a dedicated CMake flag that is disabled by default to avoid unnecessary builds during regular development.
Usage
Requirements
INSTALLER=ONrequiresHTTP_SERVER=ONIf
INSTALLER=ONbutHTTP_SERVER=OFF, a warning is shown and installer targets are skipped
What Gets Enabled
When INSTALLER=ON is set:
CPack configuration is loaded
Installer-specific targets are created
Platform-specific package metadata is configured
Installation rules are set up
Default Behavior
By default (INSTALLER=OFF):
Regular server builds work normally
No installer-specific configuration is loaded
Build times are faster for development
No CPack dependencies required
Why This Design?
Faster developer builds: Developers don't need installer dependencies
Explicit intent: Installer builds are only created when explicitly requested
CI optimization: Avoids unnecessary work in non-installer workflows
Cleaner separation: Clear distinction between development and distribution builds
Example Workflows
Developer building for testing:
Packaging for distribution:
CI/CD automated build:
Note: All build scripts in installer/linux/, installer/macos/, and installer/windows/ automatically set -DINSTALLER=ON, so you don't need to set it manually when using those scripts.
Building Installers
Linux (Debian/Ubuntu)
Requirements:
dpkg-dev,debhelper,cmake,gcc,g++
Output: ../colibri-server_1.0.0-1_amd64.deb
Install:
Linux (RPM - RedHat/CentOS/Fedora)
Requirements:
rpm-build,rpmdevtools,cmake,gcc,gcc-c++
Output: ~/rpmbuild/RPMS/x86_64/colibri-server-1.0.0-1.x86_64.rpm
Install:
macOS
Requirements:
Xcode Command Line Tools
CMake
Output: ../../colibri-server-1.0.0.pkg
Install:
Windows
Requirements:
Visual Studio 2022 (or newer)
WiX Toolset v3.11+ (https://wixtoolset.org/)
CMake
Output: ..\..\build\colibri-server-1.0.0.msi
Install:
Service Management
Linux (systemd)
macOS (LaunchDaemon)
Windows (Service)
Uninstallation
Linux (Debian/Ubuntu)
Linux (RPM)
macOS
Recommended: Use the uninstall script
The script will:
Stop and unload the service
Remove the binary and LaunchDaemon
Ask if you want to keep or remove config files and logs
See macos/UNINSTALL.md for manual uninstallation instructions.
Windows
Customizing the Configuration
After installation, edit the configuration file:
Linux:
macOS:
Windows:
Troubleshooting
Service won't start
Check logs:
Linux:
journalctl -u colibri-server -n 50macOS:
tail -n 50 /var/log/colibri-server.error.logWindows: Event Viewer → Application logs
Verify configuration:
Check for syntax errors in
server.confEnsure RPC/Beacon endpoints are accessible
Verify port is not already in use
Check permissions:
Linux: Ensure
/var/lib/colibriis owned bycolibriusermacOS: Ensure log files are writable
Windows: Ensure service has necessary permissions
Port already in use
Edit the config file and change PORT to a different value:
Then restart the service.
Network connectivity issues
Ensure firewall rules allow incoming connections:
Linux:
macOS:
Windows:
CI/CD - Automated Installer Builds
Installer packages are automatically built via GitHub Actions on every push to main or dev branches, as well as on release tags.
Workflow Triggers
On push to main/dev: Builds all installers and uploads them as artifacts (dev version)
On version tags (v..*):** Builds release versions and creates a GitHub Release with all installer packages
Manual trigger: Can be triggered manually via GitHub UI with custom version
Version Handling
Release tags (e.g.,
v1.2.3): Version extracted from tag →colibri-server-1.2.3.pkgBranch pushes: Uses commit SHA →
colibri-server-dev-abc1234.pkgManual builds: Uses provided version number
Downloading Pre-built Installers
From GitHub Releases:
From GitHub Actions Artifacts:
Go to Actions tab → "Build Installers" workflow
Select the workflow run
Download artifacts (requires GitHub login)
Building Locally
To build installers locally with a custom version:
Development & Testing
To test the server without installing:
License
The Colibri core library is licensed under the MIT License.
The server component (src/server/) is dual-licensed:
PolyForm Noncommercial License 1.0.0 for non-commercial use
Commercial License required for commercial use (contact jork@corpus.io)
Support
For issues, questions, or feature requests:
GitHub: https://github.com/corpus-core/colibri-stateless/issues
Email: jork@corpus.io
Documentation: https://corpus-core.gitbook.io/specification-colibri-stateless
Last updated