Windows Server Setup Guide

Complete installation and configuration guide for running ContentWing on Windows Server. Includes Docker Desktop and native installation methods with IIS integration.

System Requirements

Ensure your Windows server meets these requirements before installation:

ComponentMinimumRecommendedNotes
Operating SystemWindows Server 2016 / Windows 10 ProWindows Server 2019+ / Windows 11 Pro64-bit versions only, Hyper-V capable
CPU2 cores, 2.0 GHz4+ cores, 2.5+ GHzIntel VT-x or AMD-V required for Docker
Memory (RAM)8 GB16+ GBWindows requires more RAM than Linux
Storage50 GB free space100+ GB SSDNTFS file system required
NetworkStable internet connection100+ Mbps bandwidthWindows Firewall configuration required

Choose Installation Method

Select the installation method that best fits your Windows environment:

Docker Desktop (Recommended)

Easy

Quick setup using Docker Desktop for Windows

Setup time: 20 minutes

Pros:

  • Easy installation
  • Consistent environment
  • Built-in management UI
  • Automatic updates

Cons:

  • Requires Hyper-V
  • Higher resource usage
  • Windows Pro/Enterprise only

Native Installation

Advanced

Direct installation with IIS integration

Setup time: 45-60 minutes

Pros:

  • Better performance
  • Full Windows integration
  • Works on all Windows editions
  • Custom configurations

Cons:

  • Complex setup
  • Manual dependency management
  • Requires Windows Server knowledge

Docker Desktop Installation (Recommended)

Follow these steps for a Docker-based installation on Windows:

1

Enable Required Windows Features

Enable Windows features required for Docker Desktop

PowerShell (Run as Administrator)
# Run PowerShell as Administrator
# Enable Hyper-V and Containers features
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All
Enable-WindowsOptionalFeature -Online -FeatureName Containers -All

# Restart computer when prompted
Restart-Computer
2

Install Docker Desktop

Download and install Docker Desktop for Windows

PowerShell (Run as Administrator)
# Download Docker Desktop from official website
# https://www.docker.com/products/docker-desktop

# Or use Chocolatey package manager
Set-ExecutionPolicy Bypass -Scope Process -Force
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
choco install docker-desktop -y

# Start Docker Desktop and complete setup
3

Download ContentWing Configuration

Set up the ContentWing configuration files

PowerShell (Run as Administrator)
# Create application directory
New-Item -ItemType Directory -Path 'C:\ContentWing' -Force
Set-Location 'C:\ContentWing'

# Download docker-compose.yml
Invoke-WebRequest -Uri 'https://releases.contentwing.com/latest/docker-compose.yml' -OutFile 'docker-compose.yml'

# Download environment template
Invoke-WebRequest -Uri 'https://releases.contentwing.com/latest/.env.example' -OutFile '.env.example'
Copy-Item '.env.example' '.env'
4

Configure Environment Variables

Configure the application environment settings

PowerShell (Run as Administrator)
# Edit environment file
notepad .env

# Required settings (edit in notepad):
# APP_URL=https://your-domain.com
# DATABASE_URL=postgresql://user:pass@db:5432/contentwing
# JWT_SECRET=your-super-secret-key-here
# REDIS_URL=redis://redis:6379

# Save and close notepad
5

Start ContentWing Services

Launch the ContentWing application stack

PowerShell (Run as Administrator)
# Start all services in detached mode
docker-compose up -d

# Check service status
docker-compose ps

# View application logs
docker-compose logs -f app

# Access at http://localhost:3000

Native Windows Installation

For advanced users who prefer direct Windows installation with full system integration:

1

Install Prerequisites

Install Node.js, PostgreSQL, and Redis dependencies

PowerShell (Run as Administrator)
# Install Node.js 18+ using Chocolatey
Set-ExecutionPolicy Bypass -Scope Process -Force
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
choco install nodejs -y

# Install PostgreSQL
choco install postgresql -y --params '/Password:secure_password'

# Install Redis (or use Redis on Windows)
choco install redis-64 -y

# Restart PowerShell to refresh PATH
2

Configure PostgreSQL Database

Set up the PostgreSQL database for ContentWing

PowerShell (Run as Administrator)
# Start PostgreSQL service
Start-Service postgresql-x64-14

# Connect to PostgreSQL (using installed psql)
& 'C:\Program Files\PostgreSQL\14\bin\psql.exe' -U postgres

# In PostgreSQL shell, create database:
CREATE DATABASE contentwing;
CREATE USER contentwing_user WITH PASSWORD 'secure_password';
GRANT ALL PRIVILEGES ON DATABASE contentwing TO contentwing_user;
\q
3

Install ContentWing Application

Download and install the ContentWing application

PowerShell (Run as Administrator)
# Create application directory
New-Item -ItemType Directory -Path 'C:\ContentWing' -Force
Set-Location 'C:\ContentWing'

# Download latest release
Invoke-WebRequest -Uri 'https://releases.contentwing.com/latest/contentwing-windows.zip' -OutFile 'contentwing.zip'
Expand-Archive -Path 'contentwing.zip' -DestinationPath '.' -Force
Remove-Item 'contentwing.zip'

# Install dependencies
npm install --production
4

Configure Application Settings

Configure the application settings and database

PowerShell (Run as Administrator)
# Copy configuration template
Copy-Item '.env.example' '.env'

# Edit configuration file
notepad .env

# Set database connection:
# DATABASE_URL=postgresql://contentwing_user:secure_password@localhost:5432/contentwing
# JWT_SECRET=your-super-secret-key-here
# REDIS_URL=redis://localhost:6379

# Run database migrations
npm run db:migrate
5

Install Windows Service

Set up ContentWing as a Windows service

PowerShell (Run as Administrator)
# Install PM2 process manager globally
npm install -g pm2
npm install -g pm2-windows-service

# Create PM2 service
pm2 start ecosystem.config.js
pm2 save
pm2-service-install -n ContentWing

# Start the service
Start-Service ContentWing

IIS Reverse Proxy Configuration

Configure IIS as a reverse proxy for professional Windows hosting:

Prerequisites

Install IIS with Application Request Routing (ARR) module
Install URL Rewrite module for IIS
Create a new IIS site for your domain

web.config Configuration

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.webServer>
    <rewrite>
      <rules>
        <rule name="ContentWing" stopProcessing="true">
          <match url=".*" />
          <conditions logicalGrouping="MatchAll">
            <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
            <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
          </conditions>
          <action type="Rewrite" url="http://localhost:3000/{R:0}" />
        </rule>
      </rules>
    </rewrite>
  </system.webServer>
</configuration>

Setup Instructions:

1. Save this as web.config in your IIS site root directory

2. Ensure ContentWing is running on localhost:3000

3. Configure SSL certificate in IIS Manager

4. Test the configuration by visiting your domain

Security Configuration

Secure your Windows ContentWing installation with these essential measures:

Windows Firewall

Open Windows Firewall with Advanced Security
Create inbound rule for port 3000 (HTTP)
Create inbound rule for port 443 (HTTPS)
Block unnecessary ports and services
Enable Windows Defender if not already active

SSL Certificate

Install IIS Manager and URL Rewrite module
Request SSL certificate from Certificate Authority
Install certificate in Windows Certificate Store
Configure IIS site with SSL binding
Test HTTPS connectivity

User Access Control

Create dedicated service account for ContentWing
Set appropriate file system permissions
Configure service to run as service account
Disable unnecessary Windows features
Enable Windows Security auditing

Windows Firewall Configuration

Allow ContentWing HTTP Traffic

PowerShell (Run as Administrator)
# Allow inbound HTTP traffic on port 3000
New-NetFirewallRule -DisplayName 'ContentWing HTTP' -Direction Inbound -Port 3000 -Protocol TCP -Action Allow

# Allow inbound HTTPS traffic on port 443
New-NetFirewallRule -DisplayName 'ContentWing HTTPS' -Direction Inbound -Port 443 -Protocol TCP -Action Allow

# Allow PostgreSQL traffic (local only)
New-NetFirewallRule -DisplayName 'PostgreSQL Local' -Direction Inbound -Port 5432 -Protocol TCP -RemoteAddress LocalSubnet -Action Allow

Monitoring & Maintenance

Keep your Windows ContentWing installation healthy with these monitoring commands:

Service Monitoring

Monitor ContentWing Windows service status

PowerShell
# Check service status
Get-Service -Name 'ContentWing'

# View service details
Get-WmiObject -Class Win32_Service -Filter "Name='ContentWing'"

# Check PM2 processes
pm2 list
pm2 monit

Performance Monitoring

Monitor system resources and performance

PowerShell
# Check system performance
Get-Counter '\Processor(_Total)\% Processor Time'
Get-Counter '\Memory\Available MBytes'

# Monitor disk usage
Get-WmiObject -Class Win32_LogicalDisk | Select-Object Size,FreeSpace,DeviceID

# View application logs
Get-EventLog -LogName Application -Source 'ContentWing' -Newest 50

Common Management Commands

Docker Commands

docker-compose up -d - Start services
docker-compose down - Stop services
docker-compose logs -f - View logs
docker system prune - Clean up

Service Commands

Get-Service ContentWing - Check status
Restart-Service ContentWing - Restart service
pm2 restart all - Restart PM2 processes
pm2 logs - View application logs

Common Issues & Solutions

Docker Desktop Not Starting

Docker Desktop fails to start or shows Hyper-V errors.

Get-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V-All
Enable Hyper-V if not enabled, then restart computer

Service Won't Start

ContentWing Windows service fails to start.

Get-EventLog -LogName System -Source Service*
Check Windows Event Log for service startup errors

IIS Reverse Proxy Issues

IIS not properly forwarding requests to ContentWing.

Check IIS URL Rewrite module is installed
Verify ContentWing is running on localhost:3000
Review IIS Failed Request Tracing logs

Performance Optimization

Windows Optimization

  • • Disable Windows Search indexing on server drives
  • • Configure Windows to prioritize background services
  • • Set up automatic Windows Updates during maintenance windows
  • • Configure page file on separate drive if possible
  • • Use Windows Performance Toolkit for profiling

Database Tuning

  • • Configure PostgreSQL memory settings
  • • Set up regular database maintenance tasks
  • • Monitor query performance with pg_stat_statements
  • • Configure appropriate checkpoint settings
  • • Set up database backup automation

Next Steps

Your Windows server is now ready! Continue with these guides:

Windows Server Setup Complete!

Your ContentWing server is now running on Windows. Start creating amazing content!