fix(docker): 去掉 # syntax 行(国内加速器 401 Unauthorized)并为 hub 编排加 pull_policy: build(v1.2.18)
- Dockerfile 顶部原来显式写 # syntax=docker/dockerfile:1,会让 BuildKit 额外拉 docker/dockerfile 镜像,在国内加速器(飞牛的 docker.fnnas.com)上被拦成 401,构建直接失败;该行已移除——RUN --mount=type=cache 由内建 BuildKit frontend 已支持,缓存挂载保持不变 - docker-compose.hub.yml 增加 pull_policy: build,跳过日志里那条 fonu Pulling(国内直连 Docker Hub 的超时告警) - 本轮只改 Dockerfile 与 compose,不涉及 Go 代码:安装包未重出,dist 里 1.2.17 的包仍可用
This commit is contained in:
@@ -2,6 +2,18 @@
|
|||||||
|
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
|
## [v1.2.18] - 2026-09-27
|
||||||
|
|
||||||
|
### 修复
|
||||||
|
|
||||||
|
- **国内加速器上构建失败(401 Unauthorized)**:`Dockerfile` 顶部原来显式写了 `# syntax=docker/dockerfile:1`,这会让 BuildKit 额外去拉 `docker/dockerfile` 镜像,而在飞牛的 `docker.fnnas.com` 这类加速器上会被拦成 401(`resolve image config for docker-image://docker/dockerfile:1` 失败)。该行已移除:`RUN --mount=type=cache` 由 Docker 内建的 BuildKit frontend 已支持,不需要显式指定,缓存挂载保持不变
|
||||||
|
- **compose 无谓地尝试拉镜像**:`docker-compose.hub.yml` 增加 `pull_policy: build`,跳过日志里那条 "fonu Pulling"(国内直连 Docker Hub 的超时告警),直接构建
|
||||||
|
|
||||||
|
### 变更
|
||||||
|
|
||||||
|
- 版本号提升到 1.2.18;`web/package.json` 同步对齐
|
||||||
|
- 本轮**不涉及 Go 代码**(只改 Dockerfile 与 compose),因此安装包未重出,`dist/fonu-1.2.17-linux-*.tar.gz` 仍可用;`AgentVersion` 仍为 0.12.7
|
||||||
|
|
||||||
## [v1.2.17] - 2026-09-27
|
## [v1.2.17] - 2026-09-27
|
||||||
|
|
||||||
### 新增
|
### 新增
|
||||||
|
|||||||
+3
-3
@@ -1,6 +1,6 @@
|
|||||||
# syntax=docker/dockerfile:1
|
# 不写 `# syntax=docker/dockerfile:1`:显式指定会让 BuildKit 额外去拉 docker/dockerfile 镜像,
|
||||||
# ↑ 为了能用 RUN --mount=type=cache:把 Go 模块/编译缓存与 npm 缓存跨次构建复用,
|
# 在国内加速器(如飞牛的 docker.fnnas.com)上可能直接 401 Unauthorized;
|
||||||
# 在部署机(NAS)上重复构建通常从「几分钟」降到「几十秒」。
|
# 而下面用到的 RUN --mount=type=cache 由 Docker 内建的 BuildKit frontend 已支持,无需显式指定。
|
||||||
|
|
||||||
ARG TARGETARCH
|
ARG TARGETARCH
|
||||||
# 版本单一来源:根目录 VERSION 文件,本地改版本号只需改此文件
|
# 版本单一来源:根目录 VERSION 文件,本地改版本号只需改此文件
|
||||||
|
|||||||
@@ -27,6 +27,9 @@ services:
|
|||||||
RUNTIME_IMAGE: ${RUNTIME_IMAGE:-docker.m.daocloud.io/library/debian:bookworm-slim}
|
RUNTIME_IMAGE: ${RUNTIME_IMAGE:-docker.m.daocloud.io/library/debian:bookworm-slim}
|
||||||
GOPROXY: ${GOPROXY:-https://goproxy.cn,direct}
|
GOPROXY: ${GOPROXY:-https://goproxy.cn,direct}
|
||||||
image: fonu:${FONU_VERSION:-local}
|
image: fonu:${FONU_VERSION:-local}
|
||||||
|
# 有 build 段时 compose 默认会先尝试拉同名镜像(日志里那条 "fonu Pulling" 就是),
|
||||||
|
# 国内直连 Docker Hub 会超时报警;强制走构建,跳过这一步。
|
||||||
|
pull_policy: build
|
||||||
container_name: fonu
|
container_name: fonu
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
|
|||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "fonu-web",
|
"name": "fonu-web",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "1.2.17",
|
"version": "1.2.18",
|
||||||
"packageManager": "npm@10.9.4",
|
"packageManager": "npm@10.9.4",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
Reference in New Issue
Block a user