Install phlix-server on Windows โ
TL;DR โ
phlix-server is a PHP 8.3+ media server with HLS streaming, WebSocket real-time sync, DLNA, and a Smarty web portal. This guide installs it on Windows 10 21H2+ or Windows 11 in roughly 20 minutes.
Minimum requirements: Windows 10 21H2+ or Windows 11, 2 CPU / 4 GB RAM.
Quick one-liner (XAMPP): Download XAMPP โ git clone โ composer install โ start Apache โ open http://localhost:32400
Recommendation: Use WSL2 + Ubuntu for production. Use XAMPP for quick dev / non-Docker users.
Screenshots TBD
This guide is text-first. Screenshots will be added in a follow-up.
1. Choose your installation path โ
Option 1: XAMPP (for dev / non-Docker users) โ
- Full stack: Apache + PHP + MariaDB bundled together
- Easiest for users who don't want to touch WSL or containers
- Download from apachefriends.org
Option 2: WSL2 + Ubuntu (recommended for production) โ
- Runs a real Ubuntu VM inside Windows
- Native Linux experience: composer, apt, systemd scripts all work
- Requires: Windows 10 21H2+ or Windows 11 with WSL2 enabled
- See ยง3 for WSL2 setup steps
Option 3: IIS reverse-proxy to Workerman PHP โ
- For enterprise environments that already run IIS
- Requires URL Rewrite module + ARR (Application Request Routing)
- Advanced; less common
2. Option 1 โ XAMPP install โ
2a. Download and install XAMPP โ
- Download XAMPP PHP 8.3 from apachefriends.org
- Run the installer โ deselect unnecessary components (e.g., Tomcat)
- Install to default
C:\xampp - Start the XAMPP Control Panel
2b. Enable required PHP extensions โ
Edit C:\xampp\php\php.ini and ensure these lines are uncommented (no ;):
extension=curl
extension=gd
extension=mbstring
extension=mysql
extension=openssl
extension=zip
extension=xml
extension=bcmathSave and restart Apache from the XAMPP Control Panel.
2c. Verify PHP version โ
C:\xampp\php\php.exe -vExpected: PHP 8.3.x
2d. Clone phlix-server โ
git clone https://github.com/detain/phlix-server.git C:\phlix
cd C:\phlix2e. PHP dependencies (Composer) โ
C:\xampp\composer\composer.bat install --no-dev --optimize-autoloaderOr if Composer is installed globally:
composer install --no-dev --optimize-autoloader2f. Configure environment โ
copy .env.example .envEdit .env:
APP_URL=http://localhost:32400
DB_HOST=localhost
DB_DATABASE=phlix
DB_USERNAME=phlix
DB_PASSWORD=your_strong_password2g. Database setup (MariaDB via XAMPP) โ
Open phpMyAdmin at http://localhost/phpmyadmin or run:
C:\xampp\mysql\bin\mysql.exe -u root -pCREATE DATABASE phlix CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'phlix'@'localhost' IDENTIFIED BY 'your_strong_password';
GRANT ALL PRIVILEGES ON phlix.* TO 'phlix'@'localhost';
FLUSH PRIVILEGES;2h. Run migrations โ
php scripts/run-migrations.php2i. Start the server โ
php public\index.php2j. Firewall configuration โ
New-NetFirewallRule -DisplayName "Phlix HTTP" -Direction Inbound -Protocol TCP -LocalPort 32400 -Action AllowOr via Windows Defender Firewall UI: Inbound Rule โ New Rule โ Port โ 32400 โ Allow.
3. Option 2 โ WSL2 + Ubuntu (recommended) โ
3a. Enable WSL2 โ
Open PowerShell as Administrator:
wsl --install --no-distributionRestart the computer when prompted.
3b. Install Ubuntu โ
wsl --install -d Ubuntu-24.04Create a user account when prompted.
3c. Update Ubuntu โ
sudo apt update && sudo apt upgrade -y3d. Install PHP 8.3 โ
sudo apt install -y software-properties-common
sudo add-apt-repository -y ppa:ondrej/php
sudo apt install -y php8.3-fpm php8.3-mysql php8.3-curl php8.3-gd php8.3-zip php8.3-xml php8.3-mbstring php8.3-bcmath3e. Install MariaDB โ
sudo apt install -y mariadb-server
sudo mysql_secure_installation3f. Install FFmpeg โ
sudo apt install -y ffmpeg3g. Install Composer โ
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer3h. Clone phlix-server โ
sudo mkdir -p /opt/phlix
sudo chown $USER:$USER /opt/phlix
git clone https://github.com/detain/phlix-server.git /opt/phlix
cd /opt/phlix3i. PHP dependencies โ
composer install --no-dev --optimize-autoloader3j. Configure environment โ
cp .env.example .env
nano .envSet:
APP_URL=http://localhost:32400
DB_HOST=localhost
DB_DATABASE=phlix
DB_USERNAME=phlix
DB_PASSWORD=your_strong_password3k. Database setup (MariaDB) โ
sudo mysql -u root -pCREATE DATABASE phlix CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'phlix'@'localhost' IDENTIFIED BY 'your_strong_password';
GRANT ALL PRIVILEGES ON phlix.* TO 'phlix'@'localhost';
FLUSH PRIVILEGES;3l. Run migrations โ
php scripts/run-migrations.php3m. Start the server โ
php /opt/phlix/public/index.php3n. Firewall configuration (from PowerShell on Windows host) โ
New-NetFirewallRule -DisplayName "Phlix HTTP" -Direction Inbound -Protocol TCP -LocalPort 32400 -Action Allow3o. Access from Windows browser โ
Open http://localhost:32400 in your Windows browser.
4. Option 3 โ IIS reverse-proxy (advanced) โ
4a. Install URL Rewrite and ARR โ
Download and install URL Rewrite 2.1 from iis.net. Enable ARR (Application Request Routing) via IIS Manager โ Server Farm.
4b. Create a site binding โ
IIS Manager โ Sites โ Add Website:
- Site name:
phlix - Physical path:
C:\phlix\public - Binding: Host:
phlix.local, Port:80
4c. Configure reverse-proxy โ
In C:\phlix\public\web.config:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="ProxyToWorkerman" enabled="true" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{CACHE_URL}" pattern="^(https?)://" />
</conditions>
<action type="Rewrite" url="http://127.0.0.1:32400/{R:1}" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>4d. Start Workerman โ
php C:\phlix\public\index.php5. Verify the install โ
Open your browser:
http://localhost:32400Expected: phlix-server index page loads (HTTP 200).
What can go wrong โ
WSL2 not enabled or wrong version โ
- Symptom:
wsl --installfails, orwsl -l -vshows Ubuntu with version 1 - Fix: Enable Hyper-V and WSL2 via Windows Features, or run
wsl --set-version Ubuntu-24.04 2to migrate - Verify:
wsl -l -vshould show Ubuntu-24.04 with version 2
Hyper-V conflicts preventing WSL2 โ
- Symptom: WSL2 fails to start, or Ubuntu stuck at "Installing"
- Fix: Ensure Windows is fully updated (21H2 or later); disable conflicting virtualization software (e.g., older VirtualBox)
- Verify:
systeminfo | findstr /C:"Hyper-V"should show Hyper-V present
PHP version mismatch โ
- Symptom:
composer installfails with version errors, or runtime errors about missing PHP 8.3 features - Fix (XAMPP): Download PHP 8.3 version from apachefriends.org; uninstall old version first
- Fix (WSL2):
php -vshould show 8.3; if not,sudo update-alternatives --config phpor reinstall from ondrej/php PPA - Verify:
php -vshowsPHP 8.3.x
Missing Visual C++ Runtime โ
- Symptom:
php.exefails to start with "VCRUNTIME140.dll not found" - Fix: Download and install Visual C++ Redistributable 2015-2022 from Microsoft
- Verify:
php -vruns without error
Path separator issues (Windows vs Unix) โ
- Symptom: "File not found" errors, broken requires/includes
- Fix: Ensure all paths in
.envuse Windows-style separators or that the app handlesDIRECTORY_SEPARATORcorrectly; avoid hardcoded/in file paths - Verify: Set
git config --global core.autocrlf trueto handle line endings
Port 32400 already in use โ
- Symptom:
bind(): Address already in use - Fix:
netstat -ano | findstr :32400to find the conflicting process; stop it or change phlix port viaAPP_URLenv var
XAMPP Apache won't start (port 80/443 conflict) โ
- Symptom: Apache shows "Error: Apache shutdown unexpectedly"
- Fix: Check Skype, IIS, or another web server on ports 80/443; change XAMPP Apache ports in
C:\xampp\apache\conf\httpd.conf(Listen 8080, 4433) and update virtual host config
Next steps โ
- First-run wizard โ complete the browser-based setup at
http://your-server:32400 - Docker install โ alternative install method using containers
- Hardware transcoding โ configure NVENC/VAAPI for better performance (WSL2+Ubuntu only)
- Linux install โ for mixed Windows/Linux environments