Vonng / pigsty

Free RDS for PostgreSQL —— Pigsty
https://pigsty.io
GNU Affero General Public License v3.0
3.38k stars 258 forks source link

TASK [node : make node local repo cache] #392

Closed hwywhywl closed 5 months ago

hwywhywl commented 5 months ago

@Vonng 你好, 我在基于Ubuntu22.04 版本衍生发行版 elementary7 : horus ,安装单机版pigsty时执行 ./install.yml ,脚本执行以下TASK 发生错误:

TASK [node : make node local repo cache] ******************************************************************************
fatal: [192.168.3.55]: FAILED! => {"changed": true, "cmd": "apt update\n", "delta": "0:00:00.011922", "end": "2024-04-15 23:45:29.161762", "msg": "non-zero return code", "rc": 100, "start": "2024-04-15 23:45:29.149840", "stderr": "\nWARNING: apt does not have a stable CLI interface. Use with caution in scripts.\n\nE: 文件 list 第 3 行的记录格式有误 /etc/apt/sources.list.d/local.list (Suite)\nE: 无法读取源列表。", "stderr_lines": ["", "WARNING: apt does not have a stable CLI interface. Use with caution in scripts.", "", "E: 文件 list 第 3 行的记录格式有误 /etc/apt/sources.list.d/local.list (Suite)", "E: 无法读取源列表。"], "stdout": "", "stdout_lines": []}
fatal: [192.168.3.57]: FAILED! => {"changed": true, "cmd": "apt update\n", "delta": "0:00:00.011194", "end": "2024-04-15 15:45:30.372001", "msg": "non-zero return code", "rc": 100, "start": "2024-04-15 15:45:30.360807", "stderr": "\nWARNING: apt does not have a stable CLI interface. Use with caution in scripts.\n\nE: Malformed entry 3 in list file /etc/apt/sources.list.d/local.list (Suite)\nE: The list of sources could not be read.", "stderr_lines": ["", "WARNING: apt does not have a stable CLI interface. Use with caution in scripts.", "", "E: Malformed entry 3 in list file /etc/apt/sources.list.d/local.list (Suite)", "E: The list of sources could not be read."], "stdout": "", "stdout_lines": []}

我看下了 /etc/apt/sources.list.d/local.list

发现pigsty 生成 local.list 内容是:

=========# [local] on elementary7 : horus deb repo

deb [trusted=yes] http://192.168.3.55/pigsty

应该改成:

deb [trusted=yes] http://192.168.3.55/pigsty ./

当我想改正以后,从新执行 ./install.yml 内容又被覆盖掉了, 但是我搜索了整个 pigsty 都没有发现生成这个 local.list 命令地方, 请问该如何修改?

Vonng commented 5 months ago

inside repo_upstream the repo with module=local

冯若航(Ruohang Feng)

在 2024年4月16日,00:04,hwywhywl @.***> 写道:



@Vonnghttps://github.com/Vonng 你好, 我在基于Ubuntu22.04 版本衍生发行版 elementary7 : horus ,安装单机版pigsty时执行 ./install.yml ,脚本执行以下TASK 发生错误:

TASK [node : make node local repo cache] ** fatal: [192.168.3.55]: FAILED! => {"changed": true, "cmd": "apt update\n", "delta": "0:00:00.011922", "end": "2024-04-15 23:45:29.161762", "msg": "non-zero return code", "rc": 100, "start": "2024-04-15 23:45:29.149840", "stderr": "\nWARNING: apt does not have a stable CLI interface. Use with caution in scripts.\n\nE: 文件 list 第 3 行的记录格式有误 /etc/apt/sources.list.d/local.list (Suite)\nE: 无法读取源列表。", "stderr_lines": ["", "WARNING: apt does not have a stable CLI interface. Use with caution in scripts.", "", "E: 文件 list 第 3 行的记录格式有误 /etc/apt/sources.list.d/local.list (Suite)", "E: 无法读取源列表。"], "stdout": "", "stdout_lines": []} fatal: [192.168.3.57]: FAILED! => {"changed": true, "cmd": "apt update\n", "delta": "0:00:00.011194", "end": "2024-04-15 15:45:30.372001", "msg": "non-zero return code", "rc": 100, "start": "2024-04-15 15:45:30.360807", "stderr": "\nWARNING: apt does not have a stable CLI interface. Use with caution in scripts.\n\nE: Malformed entry 3 in list file /etc/apt/sources.list.d/local.list (Suite)\nE: The list of sources could not be read.", "stderr_lines": ["", "WARNING: apt does not have a stable CLI interface. Use with caution in scripts.", "", "E: Malformed entry 3 in list file /etc/apt/sources.list.d/local.list (Suite)", "E: The list of sources could not be read."], "stdout": "", "stdout_lines": []}

我看下了 /etc/apt/sources.list.d/local.list

发现pigsty 生成 local.list 内容是:

=========# [local] on elementary7 : horus deb repo

deb [trusted=yes] http://192.168.3.55/pigsty

应该改成:

deb [trusted=yes] http://192.168.3.55/pigsty ./

当我想改正以后,从新执行 ./install.yml 内容又被覆盖掉了, 但是我搜索了整个 pigsty 都没有发现生成这个 local.list 命令地方, 请问该如何修改?

— Reply to this email directly, view it on GitHubhttps://github.com/Vonng/pigsty/issues/392, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ACBQRETAAX2JBVRAQFNYZNLY5P27PAVCNFSM6AAAAABGHUYOQKVHI2DSMVQWIX3LMV43ASLTON2WKOZSGI2DIMBVHA4TEMQ. You are receiving this because you were mentioned.Message ID: @.***>

Vonng commented 5 months ago

这一任务在 node_repo 子任务中执行,取决于 repo_upstream 上游定义中,module = local 的数组项。

hwywhywl commented 5 months ago

这一任务在 node_repo 子任务中执行,取决于 repo_upstream 上游定义中,module = local 的数组项。

解决了,按 https://pigsty.io/zh/docs/reference/param/#repo_remove 文档替换成 ubuntu 配置,谢谢!

lsb_release -a No LSB modules are available. Distributor ID: Elementary Description: elementary OS 7 Horus Release: 7 Codename: horus

release 添加 7 即可: