ubuntu: 预留 minimal 云镜像代码

This commit is contained in:
bin456789 2023-11-28 21:47:07 +08:00
parent c2dc90f8da
commit 0516250f76
No known key found for this signature in database
GPG Key ID: EE301B386DE6C11B

View File

@ -372,15 +372,28 @@ setos() {
}
setos_ubuntu() {
case "$releasever" in
20.04) codename=focal ;;
22.04) codename=jammy ;;
esac
if is_use_cloud_image; then
# cloud image
# TODO: Minimal 镜像
if is_in_china; then
ci_mirror=https://mirror.nju.edu.cn/ubuntu-cloud-images
else
ci_mirror=https://cloud-images.ubuntu.com
fi
eval ${step}_img=$ci_mirror/releases/$releasever/release/ubuntu-$releasever-server-cloudimg-$basearch_alt.img
# minimal 镜像内核风味是 kvm后台 vnc 无显示
# 没有 aarch64 minimal 镜像
# TODO: 在 trans 里安装普通内核/云内核
use_minimal_image=false
if $use_minimal_image && [ "$basearch" = x86_64 ]; then
eval ${step}_img=$ci_mirror/minimal/releases/$codename/release/ubuntu-$releasever-minimal-cloudimg-$basearch_alt.img
fi
else
# 传统安装
if is_in_china; then