playwright-browser ناجح

Set up headless browser automation in Clawdbot using Playwright Chromium. Use when configuring browser tools for WSL/Linux environments, installing browser dependencies, or enabling headless web automation. Handles Chromium installation, system library dependencies, and Clawdbot browser configuration.

60من ١٠٠
١.٠k
نجوم
٦١
تنزيلات
١٠٣
مشاهدات

// تثبيت المهارة

تثبيت المهارة

المهارات هي كود تابع لأطراف ثالثة من مستودعات GitHub العامة. يفحص SkillHub الأنماط الخبيثة المعروفة، لكنه لا يستطيع ضمان السلامة. راجع الكود المصدري قبل التثبيت.

تثبيت عام (على مستوى المستخدم):

npx skillhub install openclaw/skills/playwright-browser

تثبيت في المشروع الحالي:

npx skillhub install openclaw/skills/playwright-browser --project

skill.install.customTargetHelp

npx skillhub install openclaw/skills/playwright-browser --target-dir /path/to/skills

المسار المقترح: ~/.claude/skills/playwright-browser/

مراجعة الذكاء الاصطناعي

60
من ١٠٠
جودة التعليمات65
دقة الوصف55
الفائدة51
السلامة التقنية78

Scored 60 — well-engineered setup scripts with cross-distro support and error handling, but tightly coupled to Clawdbot/OpenClaw. Playwright installation parts are reusable but configure-clawdbot.sh has no value outside OpenClaw.

productionmoderateopenclaw-usersdevopsbrowser-automationplaywright-setupwsl-configuration
تمت المراجعة بواسطة claude-code في 25‏/3‏/2026

محتوى SKILL.md

---
name: playwright-browser
description: Set up headless browser automation in Clawdbot using Playwright Chromium. Use when configuring browser tools for WSL/Linux environments, installing browser dependencies, or enabling headless web automation. Handles Chromium installation, system library dependencies, and Clawdbot browser configuration.
---

# Playwright Browser Setup

Configure Clawdbot's browser tool to use Playwright-managed Chromium for headless automation in WSL/Linux environments.

## Quick Setup

Run the setup script to install everything:

```bash
./scripts/setup.sh
```

This will:
1. Install Playwright and Chromium
2. Install required system libraries (requires sudo)
3. Patch Clawdbot config to use the Playwright browser

## Manual Setup

### 1. Install Playwright Chromium

```bash
npx playwright install chromium
```

### 2. Install System Dependencies

Chromium requires NSS and ALSA libraries:

```bash
# Ubuntu/Debian
sudo apt-get install -y libnss3 libasound2t64

# If libasound2t64 doesn't exist (older Ubuntu):
sudo apt-get install -y libnss3 libasound2
```

### 3. Find Chromium Path

```bash
find ~/.cache/ms-playwright -name "chrome" -path "*/chrome-linux64/*" 2>/dev/null | head -1
```

### 4. Configure Clawdbot

Patch the gateway config:

```bash
clawdbot config patch '{"browser": {"executablePath": "<path-from-step-3>", "headless": true, "noSandbox": true}}'
```

Or use the provided script:

```bash
./scripts/configure-clawdbot.sh
```

## Verification

Test the browser works:

```bash
~/.cache/ms-playwright/chromium-*/chrome-linux64/chrome --headless --no-sandbox --disable-gpu --dump-dom https://example.com
```

## Notes

- `noSandbox: true` is required for WSL/container environments
- `headless: true` runs without a visible window (faster, no display needed)
- For visible browser, set `headless: false` and ensure WSLg or X11 is configured

الترخيص

الترخيص المُعلن: MIT

MIT License

Copyright (c) 2026 openclaw

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

عرض الترخيص في المستودع المصدريالنسخة المنشورة هناك هي المرجع.