Installation
BWS can be installed in several ways. Choose the method that best fits your needs.
From crates.io (Recommended for Development)
The easiest way to install BWS is using Cargo:
cargo install bws-web-server
This will install the latest stable version from crates.io. The package name is bws-web-server
, but the installed binary is named bws
.
Prerequisites
- Rust: Version 1.70 or later
- Cargo: Comes with Rust installation
From Docker (Recommended for Production)
Docker is the recommended deployment method for production environments:
# Pull and run the latest version
docker run -d -p 8080:8080 ghcr.io/benliao/bws:latest
# Or with custom configuration
docker run -d \
-p 8080:8080 \
-v $(pwd)/config.toml:/app/config.toml:ro \
-v $(pwd)/static:/app/static:ro \
ghcr.io/benliao/bws:latest
Available Docker Tags
latest
- Latest stable releasev0.1.5
- Specific version (recommended for production)main
- Latest development build
From Source
For development or custom builds:
# Clone the repository
git clone https://github.com/benliao/bws.git
cd bws
# Build in debug mode
cargo build
# Build optimized release
cargo build --release
# The binary will be in target/release/bws
Pre-built Binaries
Download pre-built binaries from GitHub Releases:
Linux (x86_64)
wget https://github.com/benliao/bws/releases/latest/download/bws-linux-x86_64.tar.gz
tar -xzf bws-linux-x86_64.tar.gz
chmod +x bws
macOS (x86_64)
wget https://github.com/benliao/bws/releases/latest/download/bws-macos-x86_64.tar.gz
tar -xzf bws-macos-x86_64.tar.gz
chmod +x bws
macOS (ARM64/Apple Silicon)
wget https://github.com/benliao/bws/releases/latest/download/bws-macos-aarch64.tar.gz
tar -xzf bws-macos-aarch64.tar.gz
chmod +x bws
Windows (x86_64)
wget https://github.com/benliao/bws/releases/latest/download/bws-windows-x86_64.exe
# Note: Windows executable is directly usable
Verification
After installation, verify BWS is working:
# Check version
bws --version
# Display help
bws --help
Next Steps
Once installed, proceed to the Quick Start guide to set up your first BWS server!