create-openclaw-bot 5.5.0 → 5.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/README.md +18 -17
  2. package/README.vi.md +18 -17
  3. package/{cli.js → dist/cli.js} +295 -224
  4. package/dist/setup/shared/install-gen.js +485 -0
  5. package/{setup/shared/scaffold-gen.js → dist/setup/shared/workspace-gen.js} +247 -25
  6. package/{setup.js → dist/setup.js} +771 -1158
  7. package/package.json +10 -7
  8. package/.github/workflows/check-openclaw-update.yml +0 -106
  9. package/CHANGELOG.md +0 -602
  10. package/CHANGELOG.vi.md +0 -588
  11. package/docs/SETUP.md +0 -532
  12. package/docs/SETUP.vi.md +0 -439
  13. package/docs/ai-providers.md +0 -144
  14. package/docs/ai-providers.vi.md +0 -144
  15. package/docs/browser-automation-guide.md +0 -207
  16. package/docs/faq.md +0 -63
  17. package/docs/faq.vi.md +0 -63
  18. package/docs/hardware-guide.md +0 -55
  19. package/docs/hardware-guide.vi.md +0 -55
  20. package/docs/install-docker.md +0 -161
  21. package/docs/install-docker.vi.md +0 -161
  22. package/docs/install-native.md +0 -96
  23. package/docs/install-native.vi.md +0 -96
  24. package/docs/preview.png +0 -0
  25. package/docs/skills-plugins-guide.md +0 -126
  26. package/index.html +0 -589
  27. package/old_v510.js +0 -0
  28. package/setup/shared/runtime-gen.js +0 -710
  29. package/style.css +0 -1653
  30. package/upgrade.ps1 +0 -90
  31. package/upgrade.sh +0 -93
  32. /package/{setup → dist/setup}/data/channels.js +0 -0
  33. /package/{setup → dist/setup}/data/header.js +0 -0
  34. /package/{setup → dist/setup}/data/index.js +0 -0
  35. /package/{setup → dist/setup}/data/plugins.js +0 -0
  36. /package/{setup → dist/setup}/data/providers.js +0 -0
  37. /package/{setup → dist/setup}/data/skills.js +0 -0
  38. /package/{setup → dist/setup}/shared/common-gen.js +0 -0
  39. /package/{setup → dist/setup}/shared/docker-gen.js +0 -0
@@ -1,161 +0,0 @@
1
- # Docker Installation Guide
2
-
3
- Docker is the recommended deployment method for OpenClaw. It encapsulates all dependencies — Node.js, Chromium, and Ollama — into isolated containers that are reproducible and easy to manage.
4
-
5
- ---
6
-
7
- ## ⚡ Before you start: Is Docker the right choice for you?
8
-
9
- Docker works well, but it has a learning curve. Review this table before proceeding:
10
-
11
- | Your situation | Recommendation |
12
- | --- | --- |
13
- | **Ubuntu on your own machine (no critical data)** | ✅ Run OpenClaw directly without Docker. Simpler setup, better performance. See [Native Guide](install-native.md). |
14
- | **Ubuntu VPS or cloud server** | ✅ Docker is the best choice. Easy to update and manage. |
15
- | **Windows or macOS desktop** | ✅ Docker Desktop works well. WSL2 required on Windows. |
16
- | **Not comfortable with the terminal** | ⚠️ Docker may be frustrating. Consider using the Web Wizard with the Native option instead. |
17
- | **Shared hosting (cPanel)** | ❌ Docker is not available. Use [Native Mode](install-native.md). |
18
-
19
- ---
20
-
21
- ## 🔧 System Requirements
22
-
23
- Before installing Docker, ensure the following:
24
-
25
- - **Node.js 20/22/24**: [nodejs.org](https://nodejs.org/)
26
- - Node.js 20 is the minimum recommended version. Node.js 22 and 24 are also fine.
27
- - Avoid Node.js 25 for now; there are reports of OpenClaw failing on it.
28
- - Verify: `node -v`
29
- - **Docker Engine with Compose v2 plugin**: Instructions below.
30
- - Verify Compose v2: `docker compose version` (Note: `docker compose`, not `docker-compose`)
31
-
32
- > [!IMPORTANT]
33
- > OpenClaw requires **Docker Compose V2** (the `docker compose` plugin), not the legacy standalone `docker-compose` command. The installation instructions below install the correct version.
34
-
35
- ---
36
-
37
- ## 🐧 Ubuntu / Linux Server
38
-
39
- Ubuntu is the preferred environment for production deployments.
40
-
41
- ### Step 1 — Install Node.js 20 LTS
42
-
43
- ```bash
44
- curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
45
- sudo apt-get install -y nodejs
46
- node -v # Confirm: v20.x.x or newer
47
- ```
48
-
49
- ### Step 2 — Install Docker Engine with Compose V2 Plugin
50
-
51
- ```bash
52
- # Install prerequisites
53
- sudo apt-get update
54
- sudo apt-get install -y ca-certificates curl
55
-
56
- # Add Docker's official GPG key
57
- sudo install -m 0755 -d /etc/apt/keyrings
58
- sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
59
- sudo chmod a+r /etc/apt/keyrings/docker.asc
60
-
61
- # Add Docker's package repository
62
- echo \
63
- "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
64
- $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
65
- sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
66
-
67
- # Install Docker Engine and Compose plugin
68
- sudo apt-get update
69
- sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
70
-
71
- # Verify Compose V2
72
- docker compose version
73
- ```
74
-
75
- ### Step 3 — Run Docker without sudo (Recommended)
76
-
77
- ```bash
78
- sudo usermod -aG docker $USER
79
- newgrp docker
80
- ```
81
-
82
- ### Step 4 — Install and run OpenClaw
83
-
84
- ```bash
85
- npx create-openclaw-bot
86
- # Select "Docker" when prompted for Deploy Mode
87
- # Follow all other prompts
88
-
89
- cd your-bot-folder
90
- docker compose up -d
91
- ```
92
-
93
- ---
94
-
95
- ## 🪟 Windows Desktop
96
-
97
- ### Step 1 — Install Node.js 20 LTS
98
-
99
- Download the installer from [nodejs.org/en/download](https://nodejs.org/en/download/). Select **LTS** and run the installer.
100
-
101
- Verify in PowerShell: `node -v`
102
-
103
- ### Step 2 — Install Docker Desktop
104
-
105
- 1. Download [Docker Desktop for Windows](https://www.docker.com/products/docker-desktop/)
106
- 2. Run the installer. Select **Use WSL 2 instead of Hyper-V** when prompted.
107
- 3. After installation, open PowerShell as Administrator and install WSL2:
108
- ```powershell
109
- wsl --install
110
- ```
111
- 4. Restart your computer when prompted.
112
- 5. Start Docker Desktop and wait for it to show **Running** status.
113
-
114
- ### Step 3 — Install and run OpenClaw
115
-
116
- ```powershell
117
- npx create-openclaw-bot
118
- # Select "Docker" when prompted
119
-
120
- cd your-bot-folder
121
- docker compose up -d
122
- ```
123
-
124
- ---
125
-
126
- ## 🍏 macOS
127
-
128
- ### Step 1 — Install Node.js 20 LTS
129
-
130
- Download from [nodejs.org](https://nodejs.org/) or use Homebrew:
131
- ```bash
132
- brew install node@20
133
- ```
134
-
135
- ### Step 2 — Install Docker Desktop
136
-
137
- Download for [Apple Silicon (M1/M2/M3)](https://www.docker.com/products/docker-desktop/) or Intel and run the `.dmg` installer.
138
-
139
- ### Step 3 — Install and run OpenClaw
140
-
141
- ```bash
142
- npx create-openclaw-bot
143
- cd your-bot-folder
144
- docker compose up -d
145
- ```
146
-
147
- ---
148
-
149
- ## 🔧 Managing your containers
150
-
151
- | Task | Command |
152
- | --- | --- |
153
- | Start the bot | `docker compose up -d` |
154
- | Stop the bot | `docker compose down` |
155
- | Restart the bot | `docker compose restart` |
156
- | View live logs | `docker compose logs -f` |
157
- | Rebuild after code changes | `docker compose up --build -d` |
158
- | Check container status | `docker compose ps` |
159
-
160
- > [!TIP]
161
- > When using Ollama, the first `docker compose up -d` may take several minutes while the model is downloaded. Run `docker compose logs -f ollama` to monitor download progress.
@@ -1,161 +0,0 @@
1
- # Hướng dẫn Cài đặt Docker
2
-
3
- Docker là phương thức triển khai được khuyên dùng cho OpenClaw. Nó đóng gói toàn bộ các thành phần phụ thuộc — Node.js, Chromium, Ollama — vào các container độc lập, dễ quản lý và tái tạo.
4
-
5
- ---
6
-
7
- ## ⚡ Trước khi bắt đầu: Docker có phù hợp với bạn không?
8
-
9
- Docker hiệu quả nhưng có yêu cầu kỹ thuật nhất định. Hãy xem bảng này trước:
10
-
11
- | Tình huống của bạn | Khuyến nghị |
12
- | --- | --- |
13
- | **Ubuntu trên máy tính riêng (không có dữ liệu quan trọng)** | ✅ Nên chạy OpenClaw trực tiếp, không cần Docker. Setup đơn giản hơn, hiệu năng tốt hơn. Xem [Hướng dẫn Native](install-native.vi.md). |
14
- | **Ubuntu VPS hoặc máy chủ cloud** | ✅ Docker là lựa chọn tốt nhất. Dễ cập nhật và quản lý. |
15
- | **Windows hoặc macOS desktop** | ✅ Docker Desktop hoạt động tốt. Windows yêu cầu WSL2. |
16
- | **Không quen với command line (terminal)** | ⚠️ Docker có thể gây khó chịu. Hãy cân nhắc dùng Web Wizard với tùy chọn Native thay thế. |
17
- | **Shared hosting (cPanel)** | ❌ Docker không khả dụng trên Shared Hosting. Dùng [Native Mode](install-native.vi.md). |
18
-
19
- ---
20
-
21
- ## 🔧 Yêu cầu hệ thống
22
-
23
- Trước khi cài Docker, hãy đảm bảo có đủ:
24
-
25
- - **Node.js 20/22/24**: [nodejs.org](https://nodejs.org/)
26
- - Node.js 20 là mức tối thiểu khuyên dùng. Node.js 22 và 24 cũng ổn.
27
- - Tạm tránh Node.js 25 vì đã có report OpenClaw lỗi trên bản này.
28
- - Kiểm tra: `node -v`
29
- - **Docker Engine kèm plugin Compose V2**: Hướng dẫn cài bên dưới.
30
- - Kiểm tra Compose V2: `docker compose version` (Lưu ý: `docker compose`, không phải `docker-compose`)
31
-
32
- > [!IMPORTANT]
33
- > OpenClaw yêu cầu **Docker Compose V2** (plugin `docker compose`), không phải lệnh độc lập `docker-compose` cũ. Các hướng dẫn bên dưới sẽ cài đúng phiên bản.
34
-
35
- ---
36
-
37
- ## 🐧 Ubuntu / Linux Server
38
-
39
- Ubuntu là môi trường tốt nhất cho triển khai thực tế (production).
40
-
41
- ### Bước 1 — Cài Node.js 20 LTS
42
-
43
- ```bash
44
- curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
45
- sudo apt-get install -y nodejs
46
- node -v # Xác nhận: v20.x.x trở lên
47
- ```
48
-
49
- ### Bước 2 — Cài Docker Engine kèm plugin Compose V2
50
-
51
- ```bash
52
- # Cài các gói phụ thuộc
53
- sudo apt-get update
54
- sudo apt-get install -y ca-certificates curl
55
-
56
- # Thêm GPG key chính thức của Docker
57
- sudo install -m 0755 -d /etc/apt/keyrings
58
- sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
59
- sudo chmod a+r /etc/apt/keyrings/docker.asc
60
-
61
- # Thêm kho package của Docker
62
- echo \
63
- "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
64
- $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
65
- sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
66
-
67
- # Cài Docker Engine và plugin Compose
68
- sudo apt-get update
69
- sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
70
-
71
- # Kiểm tra Compose V2
72
- docker compose version
73
- ```
74
-
75
- ### Bước 3 — Chạy Docker không cần sudo (Khuyên làm)
76
-
77
- ```bash
78
- sudo usermod -aG docker $USER
79
- newgrp docker
80
- ```
81
-
82
- ### Bước 4 — Cài và chạy OpenClaw
83
-
84
- ```bash
85
- npx create-openclaw-bot
86
- # Chọn "Docker" khi được hỏi về Deploy Mode
87
- # Làm theo các bước còn lại
88
-
89
- cd thu-muc-bot-cua-ban
90
- docker compose up -d
91
- ```
92
-
93
- ---
94
-
95
- ## 🪟 Windows Desktop
96
-
97
- ### Bước 1 — Cài Node.js 20 LTS
98
-
99
- Tải installer từ [nodejs.org/en/download](https://nodejs.org/en/download/). Chọn **LTS** và chạy file cài đặt.
100
-
101
- Kiểm tra trong PowerShell: `node -v`
102
-
103
- ### Bước 2 — Cài Docker Desktop
104
-
105
- 1. Tải [Docker Desktop cho Windows](https://www.docker.com/products/docker-desktop/)
106
- 2. Chạy installer. Chọn **Use WSL 2 instead of Hyper-V** khi được hỏi.
107
- 3. Sau khi cài xong, mở PowerShell với quyền Administrator và cài WSL2:
108
- ```powershell
109
- wsl --install
110
- ```
111
- 4. Khởi động lại máy tính khi được yêu cầu.
112
- 5. Khởi động Docker Desktop và chờ đến khi hiển thị trạng thái **Running**.
113
-
114
- ### Bước 3 — Cài và chạy OpenClaw
115
-
116
- ```powershell
117
- npx create-openclaw-bot
118
- # Chọn "Docker" khi được hỏi
119
-
120
- cd thu-muc-bot-cua-ban
121
- docker compose up -d
122
- ```
123
-
124
- ---
125
-
126
- ## 🍏 macOS
127
-
128
- ### Bước 1 — Cài Node.js 20 LTS
129
-
130
- Tải từ [nodejs.org](https://nodejs.org/) hoặc dùng Homebrew:
131
- ```bash
132
- brew install node@20
133
- ```
134
-
135
- ### Bước 2 — Cài Docker Desktop
136
-
137
- Tải bản dành cho [Apple Silicon (M1/M2/M3) hoặc Intel](https://www.docker.com/products/docker-desktop/) và chạy file `.dmg`.
138
-
139
- ### Bước 3 — Cài và chạy OpenClaw
140
-
141
- ```bash
142
- npx create-openclaw-bot
143
- cd thu-muc-bot-cua-ban
144
- docker compose up -d
145
- ```
146
-
147
- ---
148
-
149
- ## 🔧 Quản lý container
150
-
151
- | Thao tác | Lệnh |
152
- | --- | --- |
153
- | Khởi động bot | `docker compose up -d` |
154
- | Dừng bot | `docker compose down` |
155
- | Khởi động lại bot | `docker compose restart` |
156
- | Xem log trực tiếp | `docker compose logs -f` |
157
- | Rebuild sau khi thay đổi code | `docker compose up --build -d` |
158
- | Kiểm tra trạng thái container | `docker compose ps` |
159
-
160
- > [!TIP]
161
- > Khi dùng Ollama, lần chạy `docker compose up -d` đầu tiên có thể mất vài phút để tải model về. Chạy `docker compose logs -f ollama` để theo dõi tiến trình tải.
@@ -1,96 +0,0 @@
1
- # Native Installation Guide (No Docker)
2
-
3
- Native installation is designed for users who cannot or prefer not to use Docker. This includes deployments on Shared Hosting (cPanel), low-tier VPS environments, or Windows desktops for direct access.
4
-
5
- OpenClaw v5.1.0+ natively supports deployment script generation for Windows, Linux, VPS, and Hosting environments.
6
-
7
- ---
8
-
9
- ## 🛑 Prerequisites for Native Mode
10
-
11
- Unlike Docker mode which bundles everything, Native mode requires you to have the environment prepared beforehand:
12
-
13
- 1. **Node.js (v18.0 or newer)**
14
- - Download from [nodejs.org](https://nodejs.org/).
15
- - Verify by running `node -v` in your terminal.
16
- 2. **Ollama (Optional)**
17
- - Only required if you intend to use Local LLMs (like Gemma 4).
18
- - Install manually from [ollama.com](https://ollama.com/).
19
- 3. **PM2 (Optional, but auto-installed)**
20
- - Required for background processes on VPS and Hosting. The setup scripts will automatically install PM2 globally via npm.
21
-
22
- ---
23
-
24
- ## 🪟 1. Windows Desktop
25
-
26
- Perfect for local development without the memory overhead of Docker Desktop/WSL2.
27
-
28
- 1. **Setup OpenClaw:**
29
- ```powershell
30
- npx create-openclaw-bot
31
- ```
32
- *At the `Select Deployment Mode` prompt, choose `Native`, then choose `Windows`.*
33
-
34
- 2. **Run the Bot:**
35
- - The CLI will generate a file named `setup-openclaw-win.bat`.
36
- - Double-click this file. It will automatically run `npm install` and start the bot in the terminal window.
37
-
38
- ---
39
-
40
- ## 🖥️ 2. VPS / Ubuntu / Linux Server
41
-
42
- This method uses PM2 to run the bot stably in the background and ensure it automatically restarts if your server reboots.
43
-
44
- 1. **Setup OpenClaw:**
45
- ```bash
46
- npx create-openclaw-bot
47
- ```
48
- *At the `Select Deployment Mode` prompt, choose `Native`, then choose `VPS / Ubuntu`.*
49
-
50
- 2. **Run the Bot:**
51
- - The CLI generates a `setup-openclaw-vps.sh` script.
52
- - Run the script:
53
- ```bash
54
- chmod +x setup-openclaw-vps.sh
55
- ./setup-openclaw-vps.sh
56
- ```
57
- - This script will install PM2 globally if missing, install dependencies, and start OpenClaw using PM2.
58
-
59
- 3. **Manage the Bot with PM2:**
60
- - Status: `pm2 status`
61
- - Logs: `pm2 logs openclaw`
62
- - Stop: `pm2 stop openclaw`
63
- - Restart: `pm2 restart openclaw`
64
-
65
- ---
66
-
67
- ## 🏠 3. Shared Hosting (cPanel)
68
-
69
- Shared hosting is restrictive because you do not have `sudo` access, and ports are usually blocked. OpenClaw supports this by running entirely through PM2 in your local user space.
70
-
71
- 1. **Setup Node.js App in cPanel:**
72
- - Go to your cPanel -> **Setup Node.js App**.
73
- - Create an application (Select Node 18+).
74
- - Enter your application root folder (e.g., `openclaw_app`).
75
- - Click **Start App** to ensure the environment is active.
76
-
77
- 2. **Access SSH Terminal:**
78
- - Open the **Terminal** feature in cPanel.
79
- - Navigate to your app folder: `cd openclaw_app`
80
-
81
- 3. **Setup OpenClaw:**
82
- ```bash
83
- npx create-openclaw-bot
84
- ```
85
- *Choose `Native`, then choose `Shared Hosting`.*
86
-
87
- 4. **Run the Bot:**
88
- - The CLI will generate `setup-openclaw-hosting.sh` AND an `ecosystem.config.cjs` file configured for strict hosting limits.
89
- - Run the script:
90
- ```bash
91
- chmod +x setup-openclaw-hosting.sh
92
- ./setup-openclaw-hosting.sh
93
- ```
94
-
95
- > [!WARNING]
96
- > Shared Hosting is generally not powerful enough to run Local LLMs (Ollama) or Heavy Browser Automation tasks concurrently. We highly recommend using API providers like Gemini, Claude, or 9Router if you are on Shared Hosting.
@@ -1,96 +0,0 @@
1
- # Hướng dẫn Cài đặt Native (Không dùng Docker)
2
-
3
- Chế độ Native được thiết kế dành cho những ai không thể hoặc không muốn cài Docker. Chế độ này thường tối ưu cho Shared Hosting (cPanel), các gói VPS cấu hình rất thấp, hoặc cài trực tiếp trên máy Window để chạy cá nhân.
4
-
5
- OpenClaw v5.1.0+ tự động sinh sẵn các script cài đặt dành riêng cho Windows, Linux, VPS và Hosting.
6
-
7
- ---
8
-
9
- ## 🛑 Yêu cầu bắt buộc cho Native Mode
10
-
11
- Khác với Docker (tự cấu hình mọi thứ), ở Native Mode, bạn phải tự chuẩn bị sẵn môi trường:
12
-
13
- 1. **Node.js (Bản v18.0 trở lên)**
14
- - Tải về từ [nodejs.org](https://nodejs.org/).
15
- - Kiểm tra bằng lệnh `node -v` trong Terminal/PowerShell.
16
- 2. **Ollama (Tùy chọn)**
17
- - Chỉ cần thiết nếu bạn muốn chạy các Model AI Local (như Gemma 4).
18
- - Tải và cài đặt thủ công tại [ollama.com](https://ollama.com/).
19
- 3. **PM2**
20
- - Rất cần thiết để chạy ngầm bot trên VPS và Hosting. Các script của OpenClaw sẽ tự động cài PM2 cho bạn.
21
-
22
- ---
23
-
24
- ## 🪟 1. Máy tính cá nhân Window (Desktop)
25
-
26
- Hoàn hảo cho việc chạy test local mà không bị cắn RAM của Docker hay WSL2.
27
-
28
- 1. **Sinh file cấu hình OpenClaw:**
29
- ```powershell
30
- npx create-openclaw-bot
31
- ```
32
- *Tại bước `Select Deployment Mode`, hãy chọn `Native`, sau đó chọn tiếp `Windows`.*
33
-
34
- 2. **Chạy Bot:**
35
- - Wizard sẽ sinh cho bạn một file tên là `setup-openclaw-win.bat`.
36
- - Chỉ cần double-click (nhấn đúp) vào file này. Nó sẽ tự động `npm install` và chạy bot hiển thị log trực tiếp ra cửa sổ đen của CMD/PowerShell.
37
-
38
- ---
39
-
40
- ## 🖥️ 2. Môi trường VPS / Ubuntu / Linux Server
41
-
42
- Cách này sử dụng PM2 để chạy bot ngầm tĩnh lặng ở background, và đặc biệt là tự động chạy lại bot mỗi khi VPS bị sập nguồn (reboot).
43
-
44
- 1. **Sinh file cấu hình OpenClaw:**
45
- ```bash
46
- npx create-openclaw-bot
47
- ```
48
- *Tại bước `Select Deployment Mode`, chọn `Native`, sau đó chọn tiếp `VPS / Ubuntu`.*
49
-
50
- 2. **Chạy Bot:**
51
- - Wizard sẽ đẻ ra một file tên là `setup-openclaw-vps.sh`.
52
- - Chạy lệnh sau trong thư mục:
53
- ```bash
54
- chmod +x setup-openclaw-vps.sh
55
- ./setup-openclaw-vps.sh
56
- ```
57
- - Script này sẽ cài PM2 nếu thiếu, update thư viện, và nhét bot vào danh sách chạy ngầm của PM2.
58
-
59
- 3. **Quản lý Bot bằng lệnh PM2:**
60
- - Xem bot đang sống hay chết: `pm2 status`
61
- - Xem log của bot: `pm2 logs openclaw`
62
- - Dừng bot: `pm2 stop openclaw`
63
- - Khởi động lại: `pm2 restart openclaw`
64
-
65
- ---
66
-
67
- ## 🏠 3. Shared Hosting (cPanel)
68
-
69
- Shared Hosting rất gắt gao vì bạn không có quyền `sudo` (Admin), và các port mạng thường bị khóa. OpenClaw hỗ trợ chạy thẳng trên cPanel bằng PM2 trong local user space của bạn.
70
-
71
- 1. **Mở App Node.js trên cPanel:**
72
- - Tìm ứng dụng **Setup Node.js App** trên bảng điều khiển cPanel.
73
- - Bấm Create Application (Chọn Node.js bản 18 trở lên).
74
- - Đặt đường dẫn Application root (vidụ: `bot_folder`).
75
- - Bấm **Start App** để đảm bảo môi trường Node hoạt động.
76
-
77
- 2. **Truy cập Terminal:**
78
- - Dùng tính năng **Terminal** có sẵn trên cPanel.
79
- - Gõ lệnh đi vào thư mục vừa điền: `cd bot_folder`
80
-
81
- 3. **Sinh file cấu hình OpenClaw:**
82
- ```bash
83
- npx create-openclaw-bot
84
- ```
85
- *Chọn `Native`, và chọn OS là `Shared Hosting`.*
86
-
87
- 4. **Chạy Bot:**
88
- - Bạn sẽ nhận được file `setup-openclaw-hosting.sh` VÀ một file `ecosystem.config.cjs` chuyên trị các giới hạn của Hosting.
89
- - Chạy lệnh cài:
90
- ```bash
91
- chmod +x setup-openclaw-hosting.sh
92
- ./setup-openclaw-hosting.sh
93
- ```
94
-
95
- > [!WARNING]
96
- > Shared Hosting thường có cấu hình CPU/RAM cực kỳ thấp nên **KHÔNG đủ sức** để chạy Local Ollama hay các kỹ năng duyệ web nặng (Browser Automation). Bắt buộc phải dùng API ngoài (Gemini/Claude/9Router) nếu cài bot trên Shared Hosting.
package/docs/preview.png DELETED
Binary file
@@ -1,126 +0,0 @@
1
- # OpenClaw Skills & Plugins — Hướng dẫn sử dụng
2
-
3
- ## Tổng quan
4
-
5
- OpenClaw có 2 hệ thống mở rộng:
6
-
7
- | | Skills 🧠 | Plugins 🔌 |
8
- |---|---|---|
9
- | **Là gì** | Kỹ năng cho bot AI | Kênh chat / runtime extension |
10
- | **Registry** | ClawHub | npm |
11
- | **Cài bằng** | `openclaw skills install <slug>` | `openclaw plugins install @openclaw/<pkg>` |
12
- | **Ví dụ** | Web Search, Browser, Memory | Voice Call, Matrix, MS Teams |
13
-
14
- ---
15
-
16
- ## Skills có sẵn
17
-
18
- ### 🔍 Web Search
19
- - **Chức năng:** Bot tìm kiếm web và trả kết quả realtime
20
- - **Cần:** API key Tavily (miễn phí 1000 queries/tháng)
21
- - **Setup:** Thêm vào `.env`:
22
- ```
23
- TAVILY_API_KEY=tvly-xxxxxxxxxxxxxx
24
- ```
25
- - **Lấy key:** [app.tavily.com](https://app.tavily.com/) → Create API Key
26
-
27
- ### 🌐 Browser Automation
28
- - **Chức năng:** Bot điều khiển Chrome thật trên máy bạn
29
- - **Cần:** Chrome Debug Mode bật trên máy host
30
- - **Setup:** Xem [browser-automation-guide.md](browser-automation-guide.md)
31
- - **Không cần API key** — dùng Chrome có sẵn
32
-
33
- ### 🧠 Long-term Memory
34
- - **Chức năng:** Bot nhớ hội thoại xuyên phiên, context dài hạn
35
- - **Cần:** Không cần cấu hình thêm ✅
36
- - **Tự động:** Lưu trữ trong `.openclaw/memory/`
37
-
38
- ### 📚 RAG / Knowledge Base
39
- - **Chức năng:** Chat với tài liệu, file PDF, codebase
40
- - **Cần:** Đặt file vào thư mục `.openclaw/docs/`
41
- - **Setup:** Copy file PDF/TXT/MD vào folder sau rồi restart:
42
- ```
43
- .openclaw/docs/
44
- ├── tai-lieu-1.pdf
45
- ├── huong-dan.md
46
- └── data.csv
47
- ```
48
-
49
- ### 🎨 Image Generation
50
- - **Chức năng:** Bot tạo ảnh bằng AI (DALL·E, Flux)
51
- - **Cần:** API key (dùng chung OPENAI_API_KEY hoặc thêm FLUX_API_KEY)
52
- - **Setup:** Nếu đã chọn OpenAI provider → không cần thêm gì. Nếu dùng Flux:
53
- ```
54
- FLUX_API_KEY=flx-xxxxxxxxxxxxxx
55
- ```
56
-
57
- ### ⏰ Bot Scheduler
58
- - **Chức năng:** Bot tự nhắc nhở, lên lịch gửi tin nhắn
59
- - **Cần:** Không cần cấu hình thêm ✅
60
- - **Ví dụ:** "Nhắc tôi lúc 5h chiều mỗi ngày uống nước"
61
-
62
- ### 💻 Code Interpreter
63
- - **Chức năng:** Chạy code Python/JS trong sandbox an toàn
64
- - **Cần:** Không cần cấu hình thêm ✅
65
- - **Ví dụ:** "Viết script Python tính toán chi phí tháng này"
66
-
67
- ### 📧 Email Assistant
68
- - **Chức năng:** Quản lý, soạn, tóm tắt email
69
- - **Cần:** Cấu hình SMTP trong `.env`:
70
- ```
71
- SMTP_HOST=smtp.gmail.com
72
- SMTP_PORT=587
73
- SMTP_USER=your.email@gmail.com
74
- SMTP_PASS=your_app_password
75
- ```
76
- - **Lưu ý:** Gmail cần tạo [App Password](https://myaccount.google.com/apppasswords)
77
-
78
- ---
79
-
80
- ## Plugins có sẵn
81
-
82
- ### 📞 Voice Call
83
- - **Chức năng:** Gọi thoại AI qua điện thoại
84
- - **Package:** `@openclaw/voice-call`
85
-
86
- ### 💬 Matrix Chat
87
- - **Chức năng:** Kết nối kênh Matrix/Element
88
- - **Package:** `@openclaw/matrix`
89
-
90
- ### 🏢 MS Teams
91
- - **Chức năng:** Kết nối Microsoft Teams
92
- - **Package:** `@openclaw/msteams`
93
-
94
- ### 🟣 Nostr
95
- - **Chức năng:** Kết nối mạng xã hội Nostr
96
- - **Package:** `@openclaw/nostr`
97
-
98
- ---
99
-
100
- ## Thêm / Bỏ sau khi setup
101
-
102
- Không cần chạy lại wizard. Dùng lệnh trực tiếp:
103
-
104
- ```bash
105
- # Vào container
106
- docker exec -it openclaw-bot sh
107
-
108
- # Thêm skill
109
- openclaw skills install memory
110
- openclaw skills install web-search
111
-
112
- # Xóa skill
113
- openclaw skills uninstall web-search
114
-
115
- # Thêm plugin
116
- openclaw plugins install @openclaw/voice-call
117
-
118
- # Xóa plugin
119
- openclaw plugins uninstall @openclaw/voice-call
120
-
121
- # Thoát và restart
122
- exit
123
- docker restart openclaw-bot
124
- ```
125
-
126
- > 💡 **Persist qua rebuild:** Nếu muốn thay đổi lâu dài, sửa `Dockerfile` → `docker compose build && docker compose up -d`.