Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions .github/workflows/database-cluster-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ on:
options: [all, mysql, postgresql, redis]
default: all
version:
description: 'Supported series (e.g. 8.4, 18, 6.2); all builds every supported series'
description: 'Supported series (e.g. 8.4, 18, 8.10); builds the full version from versions.json'
default: all
publish:
description: 'Publish to Docker Hub after both architectures pass'
Expand Down Expand Up @@ -74,8 +74,8 @@ jobs:
if name == 'redis':
variant = 'trixie' if series == '8.10' else 'bookworm'
build_args += f'\nREDIS_VARIANT={variant}'
image = f'1panel/{name}-cluster:{series}'
images.append({'image': image})
image = f'1panel/{name}-cluster:{version}'
images.append({'image': image, 'series_image': f'1panel/{name}-cluster:{series}'})
for architecture, runner in [('amd64', 'ubuntu-24.04'), ('arm64', 'ubuntu-24.04-arm')]:
builds.append({
'database': name,
Expand Down Expand Up @@ -154,4 +154,5 @@ jobs:
- name: Publish multi-platform manifest
env:
IMAGE: ${{ matrix.image }}
run: docker buildx imagetools create --tag "$IMAGE" "${IMAGE}-amd64" "${IMAGE}-arm64"
SERIES_IMAGE: ${{ matrix.series_image }}
run: docker buildx imagetools create --tag "$IMAGE" --tag "$SERIES_IMAGE" "${IMAGE}-amd64" "${IMAGE}-arm64"
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,17 @@ This repository builds and publishes container images used by 1Panel, covering A

Database image sources and supported version mappings are grouped under [database-ha/](database-ha/README.md). Their runtime checks are maintained in the shared [checks/](checks/README.md) directory.

| Image | Supported series / image tags |
| --- | --- |
| `1panel/mysql-cluster` | `8.4` |
| `1panel/postgresql-cluster` | `15`, `16`, `17`, `18` |
| `1panel/redis-cluster` | `6.2`, `7.4`, `8.10` |
| Image | Full version tags | Series aliases |
| --- | --- | --- |
| `1panel/mysql-cluster` | `8.4.13` | `8.4` |
| `1panel/postgresql-cluster` | `15.20`, `16.16`, `17.12`, `18.7` | `15`, `16`, `17`, `18` |
| `1panel/redis-cluster` | `6.2.24`, `7.4.12`, `8.10.3` | `6.2`, `7.4`, `8.10` |

Full version tags use the upstream database patch versions pinned in [versions.json](database-ha/versions.json), without an `r` revision suffix. Rebuilding the same database version reuses its full version tag and may change the digest; use a digest to pin a specific build. Series aliases follow the existing version rules: MySQL and Redis use major.minor; PostgreSQL uses the major version. Each alias points to its latest published patch. Primary and replica nodes use the same image with different replication environment variables.

Tags follow the existing 1Panel HA package version rules: MySQL and Redis use major.minor; PostgreSQL uses the major version. The exact upstream patch versions are pinned in [versions.json](database-ha/versions.json). Primary and replica nodes use the same image with different replication environment variables.
`Build Database Replication Images` builds and checks each selected series on native amd64 and arm64 runners using `<full-version>-amd64` and `<full-version>-arm64` candidate tags. Select a database and series, or use `all` to build every supported entry. Manual runs default to build and test only; enabling `publish` pushes the verified architecture images and, after all selected builds pass, publishes multi-platform manifests under both the full version tag and its series alias, for example `1panel/postgresql-cluster:17.12` and `1panel/postgresql-cluster:17`.

`Build Database Replication Images` builds and checks each selected series on native amd64 and arm64 runners. Select a database and series, or use `all` to build every supported entry. Manual runs default to build and test only; enabling `publish` pushes the verified architecture images and publishes the series manifest after all selected builds pass.
The companion new App Store packages use full database patch versions with `-master` or `-slave` suffixes and require 1Panel v2.6 through `supportVersion: 2.6`. Historical packages retain their historical images; migration of existing clusters needs a separate procedure. This minimum panel version does not mean panel-side safeguards against ordinary upgrades from old to new images or mixed-generation nodes have been implemented.

The supported list includes the existing 1Panel HA series still maintained upstream and adds PostgreSQL 18 and Redis 8.10. MySQL 5.7/8.0 and PostgreSQL 13/14 have reached EOL; Redis 8.0 is marked unsupported in the upstream security policy. See [support decisions and upstream sources](database-ha/README.md#版本维护范围).

Expand Down
16 changes: 9 additions & 7 deletions README_zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,17 @@

三类数据库的源码和版本映射放在 [database-ha/](database-ha/README.md),运行校验脚本统一维护在根目录的 [checks/](checks/README.md)。

| 镜像 | 支持系列与镜像标签 |
| --- | --- |
| `1panel/mysql-cluster` | `8.4` |
| `1panel/postgresql-cluster` | `15`、`16`、`17`、`18` |
| `1panel/redis-cluster` | `6.2`、`7.4`、`8.10` |
| 镜像 | 完整版本标签 | 系列兼容别名 |
| --- | --- | --- |
| `1panel/mysql-cluster` | `8.4.13` | `8.4` |
| `1panel/postgresql-cluster` | `15.20`、`16.16`、`17.12`、`18.7` | `15`、`16`、`17`、`18` |
| `1panel/redis-cluster` | `6.2.24`、`7.4.12`、`8.10.3` | `6.2`、`7.4`、`8.10` |

完整版本标签使用 [versions.json](database-ha/versions.json) 固定的数据库补丁版本,不添加 `r` 修订后缀。相同数据库版本重建时沿用完整版本标签,digest 可能变化;需要固定具体构建时使用 digest。系列兼容别名沿用已有版本规则:MySQL、Redis 使用主次版本号,PostgreSQL 使用主版本号,指向该系列最近发布的补丁版本。主从节点使用同一个镜像,通过复制环境变量区分角色。

版本规则沿用当前 1Panel 高可用安装包:MySQL、Redis 使用主次版本号,PostgreSQL 使用主版本号。实际构建使用的补丁版本固定在 [versions.json](database-ha/versions.json)。主从节点使用同一个镜像,通过复制环境变量区分角色。
`Build Database Replication Images` 在原生 amd64、arm64 Runner 上,以 `<完整版本>-amd64`、`<完整版本>-arm64` 候选标签构建并验证所选系列。可以选择数据库和系列,也可以使用 `all` 构建全部支持项。手动运行默认只构建测试;启用 `publish` 后推送已验证的架构镜像,并在全部选中任务通过后,为完整版本标签和系列兼容别名发布多架构 manifest,例如 `1panel/postgresql-cluster:17.12` 和 `1panel/postgresql-cluster:17`。

`Build Database Replication Images` 在原生 amd64、arm64 Runner 上构建并验证所选系列。可以选择数据库和系列,也可以使用 `all` 构建全部支持项。手动运行默认只构建测试;启用 `publish` 后推送已验证的架构镜像,并在全部选中任务通过后发布系列标签的多架构 manifest。
配套新应用商店包以完整数据库补丁版本加 `-master`、`-slave` 角色后缀命名,通过 `supportVersion: 2.6` 声明最低支持 1Panel v2.6。旧包保持历史镜像,存量集群迁移单独处理;该版本门槛不代表面板已完成旧新镜像的普通升级隔离或混合节点校验。

支持范围覆盖当前 1Panel 高可用仍有上游维护的系列,并新增 PostgreSQL 18、Redis 8.10。MySQL 5.7/8.0、PostgreSQL 13/14 已结束维护;Redis 8.0 已被上游安全政策列为不支持,详见[版本维护范围及官方来源](database-ha/README.md#版本维护范围)。

Expand Down
13 changes: 7 additions & 6 deletions checks/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,12 @@ python3 checks/check-php-eol-backport.py /path/to/source-inputs
```bash
bash checks/check-php-pecl.sh PHP_IMAGE
python3 checks/check-php-legacy-runtime.py PHP_IMAGE
bash checks/check-mysql-cluster.sh 1panel/mysql-cluster:8.4
bash checks/check-postgresql-cluster.sh 1panel/postgresql-cluster:18
bash checks/check-redis-cluster.sh 1panel/redis-cluster:8.10
bash checks/check-mysql-cluster.sh 1panel/mysql-cluster:8.4.13
bash checks/check-postgresql-cluster.sh 1panel/postgresql-cluster:18.7
bash checks/check-redis-cluster.sh 1panel/redis-cluster:8.10.3
```

将 `PHP_IMAGE` 替换为待验证的 PHP 镜像名称。数据库镜像构建方法与支持版本见 [database-ha](../database-ha/README.md)。
将 `PHP_IMAGE` 替换为待验证的 PHP 镜像名称。数据库示例使用完整版本标签,指向本地构建的待发布候选镜像;CI 传入的是同一候选的架构标签,例如 `1panel/redis-cluster:8.10.3-arm64`。校验不依赖镜像先行发布。数据库镜像构建方法与支持版本见 [database-ha](../database-ha/README.md)。

数据库校验使用唯一名称创建临时容器、网络和数据卷,结束时清理本次创建的资源。PHP 运行校验同样使用临时容器;PECL 校验会在容器中联网下载和编译扩展。

Expand All @@ -84,8 +84,8 @@ bash checks/check-redis-cluster.sh 1panel/redis-cluster:8.10
三个数据库校验脚本已接入 [Build Database Replication Images](../.github/workflows/database-cluster-release.yml):

- 涉及数据库源码或数据库校验脚本的 PR,会触发对应工作流,从版本清单生成 amd64、arm64 构建及运行校验任务。
- 每个任务先构建镜像,再调用对应的 `check-*-cluster.sh`;该项校验失败会阻止该项镜像推送。
- PR 只构建和校验。手动运行时 `publish` 默认为 `false`;启用后才推送已验证的架构镜像,并在全部选中任务通过后发布多架构标签。
- 每个任务先构建 `<完整版本>-amd64` 或 `<完整版本>-arm64` 候选镜像,再将该镜像传给对应的 `check-*-cluster.sh`;该项校验失败会阻止该项镜像推送。
- PR 只构建和校验。手动运行时 `publish` 默认为 `false`;启用后才推送已验证的完整版本架构镜像,并在全部选中任务通过后,为完整版本标签和系列兼容别名发布多架构 manifest,不添加 `r` 修订后缀。同数据库版本重建会沿用标签,digest 可能变化;固定具体构建时使用 digest。

本目录中的 Java、PHP 校验脚本目前由维护者手动执行,尚未在现有发布工作流中调用。

Expand All @@ -94,6 +94,7 @@ bash checks/check-redis-cluster.sh 1panel/redis-cluster:8.10
- 退出码 `0` 表示本次实际执行的检查项通过;非零表示失败,需要结合报错和容器日志定位。
- `SKIP` 表示该项未验证。例如没有提供 PHP 7.3.33 源码包时,其源码校验会跳过,不能据此认定该项通过。
- 源码检查通过后,仍需对构建出的镜像执行运行校验。容器检查的结论限定于本次镜像版本、架构和脚本覆盖的场景。
- 配套新数据库应用包最低支持 1Panel v2.6(`supportVersion: 2.6`),旧包保持历史镜像。镜像校验不验证面板的旧新镜像升级隔离或混合节点校验。
- 生产旧数据迁移、跨主版本升级和真实多机部署需要单独验证;一次临时环境检查不覆盖这些场景。

维护时沿用 `check-*` 命名,将共享校验集中放在本目录,并在本说明中补齐用途、输入和依赖。涉及仓库文件时,通过脚本自身位置定位仓库根目录,保持从不同工作目录执行的行为一致。
2 changes: 1 addition & 1 deletion checks/check-postgresql-cluster.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -Eeuo pipefail

image="${1:-${IMAGE:-1panel/postgresql-cluster:18}}"
image="${1:-${IMAGE:-1panel/postgresql-cluster:18.7}}"
prefix="1panel-pg-check-$(date +%s)-$$"
network="$prefix-network"
master="$prefix-master"
Expand Down
Loading
Loading