Users can install all Chromium requirements with a single command:
curl -fsSL https://raw.githubusercontent.com/zk1tty/rebrowse-app/main/install-chromium.sh | bashThe installation script automatically:
- Detects Operating System (Linux/macOS)
- Installs System Dependencies:
- Python 3.11+
- System Chromium browser
- Xvfb (for headless operation)
- Required fonts and libraries
- Installs Python Dependencies:
- Playwright >= 1.40.0
- browser-use >= 0.2.4
- FastAPI and other workflow dependencies
- Installs Playwright Chromium:
- Downloads Playwright's controlled Chromium
- Installs system dependencies for Playwright
- Verifies Installation:
- Tests browser functionality
- Creates a usage example
- Provides Next Steps
- Add the
install-chromium.shscript to your repository root - Make sure the file is executable:
chmod +x install-chromium.sh
Test your hosted script:
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh | bash# Install everything with one command
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh | bash# Download the script to inspect it
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh -o install-chromium.sh
# Make it executable
chmod +x install-chromium.sh
# Run it
./install-chromium.sh# Run without interactive prompts
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh | bash -s -- --silent| Platform | Support | Package Manager |
|---|---|---|
| Ubuntu/Debian | ✅ Full | apt-get |
| CentOS/RHEL/Fedora | ✅ Full | dnf/yum |
| macOS | ✅ Full | Homebrew |
| Windows | ❌ Use WSL2 | - |
| Alpine Linux | apk |
playwright>=1.40.0- Browser automationbrowser-use>=0.2.4- Workflow browser wrapperfastapi>=0.115.0- Web frameworkuvicorn[standard]>=0.34.0- ASGI server- Additional workflow dependencies
chromium-browser- Chromium browserxvfb- Virtual display server- Font packages (
liberation-fonts,dejavu-fonts) - Graphics libraries (
libgtk-3-0,libnss3, etc.)
chromium- Chromium browser via Homebrewpython@3.11- Python (if not installed)
After installation, the script:
- Runs a test to verify browser functionality
- Creates an example file at
~/rebrowse_example.py - Provides usage instructions
Test the installation manually:
python3 ~/rebrowse_example.py"Permission denied" errors:
# Run with explicit bash interpreter
bash <(curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh)"Command not found" errors:
# Check if Python is in PATH
which python3
python3 --version
# Reinstall Playwright browsers
python3 -m playwright install chromium"Browser failed to start" errors:
# For headless environments, set display
export DISPLAY=:99
# Run with xvfb
xvfb-run -a python3 ~/rebrowse_example.pyCustom installation directory:
# Set custom Python package location
export PYTHONUSERBASE=/custom/path
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh | bashSkip system dependencies (if already installed): Edit the script and comment out the system dependency installation sections.
## 🚀 Quick Setup
Install all requirements with one command:
```bash
curl -fsSL https://raw.githubusercontent.com/YOUR_USERNAME/YOUR_REPO/main/install-chromium.sh | bashThis installs:
- ✅ Playwright Chromium browser
- ✅ Python dependencies (browser-use, playwright)
- ✅ System dependencies (fonts, libraries)
- ✅ Verification and testing tools
Supported: Ubuntu, Debian, CentOS, RHEL, Fedora, macOS
Requirements: Python 3.11+, curl, sudo access
### Alternative Installation Methods:
```markdown
## Alternative Installation
### Manual Installation
```bash
# Install Python dependencies
pip install playwright>=1.40.0 browser-use>=0.2.4
# Install Playwright Chromium
playwright install chromium
playwright install-deps chromium
FROM python:3.11-slim
RUN pip install playwright browser-use
RUN playwright install chromium
RUN playwright install-deps chromium
## 🔄 Updating the Script
To update the installation script:
1. **Modify** `install-chromium.sh`
2. **Test locally** first
3. **Commit and push** to GitHub
4. **Update version** if needed (add versioning in script comments)
Users will automatically get the latest version when they run the one-liner command.
## 🤝 Contributing
Users can contribute improvements to the installation script by:
1. Forking your repository
2. Making improvements to `install-chromium.sh`
3. Testing on their platform
4. Submitting a pull request
---
**Pro Tip:** Consider adding analytics to track installation success rates by having the script optionally report anonymized metrics.