Files
Nexus/docs/changelog/2026-06-05-install-1panel-docker-script.md
T
Nexus Deploy 222703d733 fix(install): allow curl-pipe bash when set -u is enabled
BASH_SOURCE[0] is unset for stdin scripts; call main directly in
install-1panel-docker.sh and quick-install.sh.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-06 02:11:40 +08:00

41 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 2026-06-05 — install-1panel-docker 一键脚本
## 摘要
新增 `deploy/install-1panel-docker.sh`,作为**重装服务器**时的官方一键入口:串联 1Panel 安装提示、Docker Compose 检测/安装、Nexus Docker 栈部署。
## 动机
-`install-1panel-docker.sh` 仅为 `nx install` 的兼容转发,名不副实。
- 用户重装 VPS 后需要明确的两层入口:全栈 vs 仅 Nexus。
- 前次事故:Agent 直接改 `/opt/1panel/apps/` 破坏 OpenResty bind mount,需在文档中禁止。
## 涉及文件
- `deploy/install-1panel-docker.sh` — 新建全栈编排脚本
- `deploy/README-1panel.md` — 更新安装说明与反代禁令
- `deploy/install-nexus-fresh.sh` — 注册 `nexus-1panel-docker` 全局命令
## 用法
```bash
# 重装服务器(全栈)
curl -fsSL "http://66.154.115.8:3000/admin/Nexus/raw/branch/main/deploy/install-1panel-docker.sh" | bash
# 已装 1Panel
curl -fsSL ".../install-1panel-docker.sh" | bash -s -- --skip-1panel
```
## 是否需迁移/重启
- 仅文档与脚本,无运行时变更;push 后新机 curl 即生效。
## 验证
- `bash -n deploy/install-1panel-docker.sh`
- 逻辑审阅:不写入 `/opt/1panel/apps/`,反代仍由用户在 1Panel UI 配置
## 补丁(同日)
- `curl | bash``BASH_SOURCE[0]``set -u` 时为 unbound → 入口改为直接 `main "$@"``install-1panel-docker.sh``quick-install.sh`