add kylin-v10-sp3-2403 (#2897)

* add kylin-v10-sp3-2403

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* Update gen-repository-iso.yaml

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* Update gen-repository-iso.yaml

Signed-off-by: redscholar <blacktiledhouse@gmail.com>
Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>
Signed-off-by: redscholar <blacktiledhouse@gmail.com>
Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* feat: add kylin v10-sp1/sp2 (#2861)

* feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

feat: add kylin v10-sp1/sp2

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

---------

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* add kylin-v10-sp3-2403

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

* add kylin-v10-sp3-2403 (#2896)

add kylin-v10-sp3-2403

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>

---------

Signed-off-by: xuesongzuo@yunify.com <xuesongzuo@yunify.com>
Signed-off-by: redscholar <blacktiledhouse@gmail.com>
Co-authored-by: liujian <joyceliu@yunify.com>
This commit is contained in:
zuoxuesong-worker 2025-12-17 17:09:03 +08:00 committed by GitHub
parent 6033b8c540
commit 563c2907eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
17 changed files with 353 additions and 154 deletions

View File

@ -16,18 +16,28 @@ jobs:
include: include:
- name: almalinux-9.0-rpms - name: almalinux-9.0-rpms
dockerfile: dockerfile.almalinux90 dockerfile: dockerfile.almalinux90
- name: debian10-debs - name: centos-8-rpms
dockerfile: dockerfile.centos8
- name: debian-10-debs
dockerfile: dockerfile.debian10 dockerfile: dockerfile.debian10
- name: debian11-debs - name: debian-11-debs
dockerfile: dockerfile.debian11 dockerfile: dockerfile.debian11
- name: debian12-debs - name: kylin-v10SP3-2403-rpms
dockerfile: dockerfile.debian12 dockerfile: dockerfile.kylinv10sp3-2403
- name: kylin-v10SP3-rpms
dockerfile: dockerfile.kylinv10sp3
- name: kylin-v10SP2-rpms
dockerfile: dockerfile.kylinv10sp2
- name: kylin-v10SP1-rpms
dockerfile: dockerfile.kylinv10sp1
- name: ubuntu-18.04-debs - name: ubuntu-18.04-debs
dockerfile: dockerfile.ubuntu1804 dockerfile: dockerfile.ubuntu1804
- name: ubuntu-20.04-debs - name: ubuntu-20.04-debs
dockerfile: dockerfile.ubuntu2004 dockerfile: dockerfile.ubuntu2004
- name: ubuntu-22.04-debs - name: ubuntu-22.04-debs
dockerfile: dockerfile.ubuntu2204 dockerfile: dockerfile.ubuntu2204
- name: ubuntu-24.04-debs
dockerfile: dockerfile.ubuntu2404
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
@ -53,27 +63,35 @@ jobs:
mv ./output/linux_arm64/*.iso ${{ matrix.name }}-arm64.iso mv ./output/linux_arm64/*.iso ${{ matrix.name }}-arm64.iso
sha256sum *.iso > ${{ matrix.name }}.iso.sha256sum.txt sha256sum *.iso > ${{ matrix.name }}.iso.sha256sum.txt
- name: Wait for release workflow to finish
uses: lewagon/wait-on-check-action@v1.3.4
with:
ref: ${{ github.ref }}
check-name: 'create draft release'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 10
allowed-conclusions: success
- name: Release and upload packages - name: Release and upload packages
if: startsWith(github.ref, 'refs/tags/') if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@v2
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with: with:
draft: true
files: | files: |
${{ matrix.name }}.iso.sha256sum.txt ${{ matrix.name }}.iso.sha256sum.txt
${{ matrix.name }}-amd64.iso ${{ matrix.name }}-amd64.iso
${{ matrix.name }}-arm64.iso ${{ matrix.name }}-arm64.iso
- name: Synchronize artifacts to OSS
run: |
rm -rf qsctl_v2.4.3_linux_amd64.tar.gz
wget https://attack-on-titan.gd2.qingstor.com/qsctl/v2.4.3/qsctl_v2.4.3_linux_amd64.tar.gz
tar -zxvf qsctl_v2.4.3_linux_amd64.tar.gz
rm -rf qsctl_v2.4.3_linux_amd64.tar.gz
mv qsctl_v2.4.3_linux_amd64 /usr/local/bin/qsctl
echo "access_key_id: ${{secrets.KS_QSCTL_ACCESS_KEY_ID}}" > qsctl-config.yaml
echo "secret_access_key: ${{ secrets.KS_QSCTL_SECRET_ACCESS_KEY }}" >> qsctl-config.yaml
qsctl -c qsctl-config.yaml cp ${{ matrix.name }}.iso.sha256sum.txt qs://kubekey/kubesphere/kubekey/releases/download/iso-latest/${{ steps.prepare.outputs.version }}/${{ matrix.name }}.iso.sha256sum.txt
qsctl -c qsctl-config.yaml cp ${{ matrix.name }}-amd64.iso qs://kubekey/kubesphere/kubekey/releases/download/iso-latest/${{ steps.prepare.outputs.version }}/${{ matrix.name }}-amd64.iso
qsctl -c qsctl-config.yaml cp ${{ matrix.name }}-arm64.iso qs://kubekey/kubesphere/kubekey/releases/download/iso-latest/${{ steps.prepare.outputs.version }}/${{ matrix.name }}-arm64.iso
rm -rf qsctl-config.yaml
build-harbor: build-harbor:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: github.repository == 'kubesphere/kubekey' if: github.repository == 'kubesphere/kubekey'

View File

@ -14,6 +14,8 @@
SP2 SP2
{{- else if .os.release.VERSION | contains "Lance" }} {{- else if .os.release.VERSION | contains "Lance" }}
SP3 SP3
{{- else if .os.release.VERSION | contains "Halberd" }}
SP3-2403
{{- end -}} {{- end -}}
when: .os.release.ID | unquote | eq "kylin" when: .os.release.ID | unquote | eq "kylin"

View File

@ -2,7 +2,7 @@ FROM almalinux:9.0 as almalinux90
ARG TARGETARCH ARG TARGETARCH
ARG BUILD_TOOLS="dnf-plugins-core createrepo mkisofs epel-release" ARG BUILD_TOOLS="dnf-plugins-core createrepo mkisofs epel-release"
ARG DIR=almalinux-9.0-${TARGETARCH}-rpms ARG DIR=almalinux-9.0-${TARGETARCH}-rpms
ARG PKGS=.common[],.rpms[],.almalinux[],.almalinux90[] ARG PKGS=".common[],.rpms[]"
RUN dnf install -q -y ${BUILD_TOOLS} \ RUN dnf install -q -y ${BUILD_TOOLS} \
&& dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo \ && dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo \

View File

@ -1,22 +1,43 @@
FROM centos:7 as centos7 FROM centos:7 as centos7
ARG TARGETARCH ARG TARGETARCH
ENV OS=centos ARG CENTOS_VERSION=7.9.2009
ENV OS_VERSION=7 ARG DIR=centos7-amd64-rpms
ARG BUILD_TOOLS="yum-utils createrepo mkisofs epel-release" ARG PKGS=".common[],.rpms[]"
ARG DIR=${OS}${OS_VERSION}-${TARGETARCH}-rpms ARG BUILD_TOOLS="createrepo genisoimage"
RUN yum install -q -y ${BUILD_TOOLS} \ ENV LANG=en_US.UTF-8
&& yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo \ ENV LC_ALL=en_US.UTF-8
&& yum makecache
WORKDIR package RUN if [ "$TARGETARCH" = "amd64" ]; then \
echo "[base]" > /etc/yum.repos.d/CentOS-Base.repo && \
echo "name=CentOS-Base" >> /etc/yum.repos.d/CentOS-Base.repo && \
echo "baseurl=http://vault.centos.org/${CENTOS_VERSION}/os/x86_64/" >> /etc/yum.repos.d/CentOS-Base.repo && \
echo "enabled=1" >> /etc/yum.repos.d/CentOS-Base.repo && \
echo "gpgcheck=0" >> /etc/yum.repos.d/CentOS-Base.repo && \
yum clean all && yum makecache && \
yum install -y $BUILD_TOOLS && yum clean all; \
else \
echo "Skipping yum setup for $TARGETARCH"; \
fi
WORKDIR /package
COPY packages.yaml . COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN yq eval ".common[],.rpms[],.${OS}[],.${OS}${OS_VERSION}[]" packages.yaml > packages.list
RUN sort -u packages.list | xargs repotrack -p ${DIR} \ RUN if [ "$TARGETARCH" = "amd64" ]; then \
&& createrepo -d ${DIR} \ mkdir -p ${DIR} && \
&& mkisofs -r -o ${DIR}.iso ${DIR} yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Processing $pkg..."; \
yum install -y --downloadonly --downloaddir=${DIR} $pkg || echo "not found: $pkg"; \
fi; \
done && \
createrepo ${DIR} && \
genisoimage -r -o ${DIR}.iso ${DIR}; \
else \
echo "Skipping package download for $TARGETARCH"; \
fi
FROM scratch FROM scratch
COPY --from=centos7 /package/*.iso / COPY --from=centos7 /package/*.iso /

View File

@ -0,0 +1,52 @@
FROM centos:8 as centos8
ARG TARGETARCH
ARG DIR=centos8-${TARGETARCH}-rpms
ARG PKGS=".common[],.rpms[]"
ARG BUILD_TOOLS="createrepo_c genisoimage dnf-plugins-core"
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
RUN rm -f /etc/yum.repos.d/CentOS-*.repo \
&& if [ "$TARGETARCH" = "amd64" ]; then \
BASEOS="http://vault.centos.org/8.5.2111/BaseOS/x86_64/os/"; \
APPSTREAM="http://vault.centos.org/8.5.2111/AppStream/x86_64/os/"; \
else \
BASEOS="http://vault.centos.org/8.5.2111/BaseOS/aarch64/os/"; \
APPSTREAM="http://vault.centos.org/8.5.2111/AppStream/aarch64/os/"; \
fi \
&& echo "[BaseOS]" > /etc/yum.repos.d/centos8-vault.repo \
&& echo "name=CentOS-8 BaseOS" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "baseurl=$BASEOS" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "[AppStream]" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "name=CentOS-8 AppStream" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "baseurl=$APPSTREAM" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/centos8-vault.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/centos8-vault.repo \
&& dnf --disablerepo="*" --enablerepo="BaseOS,AppStream" clean all \
&& dnf --disablerepo="*" --enablerepo="BaseOS,AppStream" makecache
RUN dnf install -y --setopt=tsflags=nodocs --disablerepo="*" --enablerepo="BaseOS,AppStream" $BUILD_TOOLS \
&& dnf clean all
WORKDIR /package
COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN mkdir -p ${DIR} \
&& yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Downloading $pkg..."; \
dnf install -y --downloadonly --downloaddir=${DIR} --disablerepo="*" --enablerepo="BaseOS,AppStream" $pkg || echo "not found: $pkg"; \
fi; \
done
RUN createrepo_c ${DIR} \
&& genisoimage -r -o ${DIR}.iso ${DIR}
FROM scratch
COPY --from=centos8 /package/*.iso /

View File

@ -1,33 +1,28 @@
FROM debian:10 as debian10 FROM debian:10 as debian10
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=buster
ARG OS_VERSION=10
ARG DIR=debian-10-${TARGETARCH}-debs ARG DIR=debian-10-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.debian[],.debian10[] ARG PKGS=.common[],.debs[],.debian[],.debian10[]
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage dirmngr" ARG BUILD_TOOLS="apt-transport-https ca-certificates curl wget gnupg dpkg-dev genisoimage dirmngr"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
# dump system package list RUN sed -i 's|deb.debian.org|archive.debian.org|g' /etc/apt/sources.list \
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list && sed -i '/security.debian.org/d' /etc/apt/sources.list \
RUN ARCH=$(dpkg --print-architecture) \ && echo 'Acquire::Check-Valid-Until "false";' > /etc/apt/apt.conf.d/99no-check-valid-until \
&& apt update -qq \ && apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ && apt install -y --no-install-recommends $BUILD_TOOLS \
&& if [ "$TARGETARCH" = "amd64" ]; then \
curl -fsSL https://download.gluster.org/pub/gluster/glusterfs/7/rsa.pub | apt-key add - ; \
echo deb https://download.gluster.org/pub/gluster/glusterfs/7/LATEST/Debian/${OS_VERSION}/amd64/apt ${OS_RELEASE} main > /etc/apt/sources.list.d/gluster.list ; \
fi \
&& curl -fsSL "https://download.docker.com/linux/debian/gpg" | apt-key add -qq - \ && curl -fsSL "https://download.docker.com/linux/debian/gpg" | apt-key add -qq - \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/debian ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list \ && echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/debian buster stable" > /etc/apt/sources.list.d/docker.list \
&& apt update -qq && apt update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN yq eval "${PKGS}" packages.yaml >> packages.list \
&& sort -u packages.list | xargs apt-get install --yes --reinstall --print-uris | awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls
RUN mkdir -p ${DIR} \ RUN yq eval "${PKGS}" packages.yaml >> packages.list \
&& sort -u packages.list | xargs -n1 apt-get install --yes --reinstall --print-uris | awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls \
&& mkdir -p ${DIR} \
&& wget -q -x -P ${DIR} -i packages.urls \ && wget -q -x -P ${DIR} -i packages.urls \
&& cd ${DIR} \ && cd ${DIR} \
&& dpkg-scanpackages ./ /dev/null | gzip -9c > ./Packages.gz && dpkg-scanpackages ./ /dev/null | gzip -9c > ./Packages.gz

View File

@ -3,7 +3,7 @@ ARG TARGETARCH
ARG OS_RELEASE=bullseye ARG OS_RELEASE=bullseye
ARG OS_VERSION=11 ARG OS_VERSION=11
ARG DIR=debian-11-${TARGETARCH}-debs ARG DIR=debian-11-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.debian[],.debian11[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage dirmngr" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage dirmngr"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive

View File

@ -0,0 +1,44 @@
FROM hxsoong/kylin:v10-sp1 as kylinv10
ARG TARGETARCH
ARG DIR=kylin-v10-${TARGETARCH}-rpms
ARG PKGS=".common[],.rpms[]"
ARG BUILD_TOOLS="createrepo_c genisoimage"
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
RUN if [ "$TARGETARCH" = "amd64" ]; then \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP1/os/adv/lic/base/x86_64/"; \
else \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP1/os/adv/lic/base/aarch64/"; \
fi \
&& echo "[kylin-base]" > /etc/yum.repos.d/kylin.repo \
&& echo "name=Kylin Base" >> /etc/yum.repos.d/kylin.repo \
&& echo "baseurl=$BASEURL" >> /etc/yum.repos.d/kylin.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/kylin.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/kylin.repo \
&& yum clean all \
&& yum makecache --disablerepo="*" --enablerepo="kylin-base"
RUN yum install -y --disablerepo="*" --enablerepo="kylin-base" $BUILD_TOOLS \
&& yum clean all
WORKDIR /package
COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN mkdir -p ${DIR} \
&& yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Downloading $pkg..."; \
yum install -y --downloadonly --downloaddir=${DIR} --disablerepo="*" --enablerepo="kylin-base" $pkg || echo "not found: $pkg"; \
fi; \
done
RUN createrepo_c ${DIR} \
&& genisoimage -r -o ${DIR}.iso ${DIR}
FROM scratch
COPY --from=kylinv10 /package/*.iso /

View File

@ -0,0 +1,44 @@
FROM hxsoong/kylin:v10-sp2 as kylinv10
ARG TARGETARCH
ARG DIR=kylin-v10-${TARGETARCH}-rpms
ARG PKGS=".common[],.rpms[]"
ARG BUILD_TOOLS="createrepo_c genisoimage"
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
RUN if [ "$TARGETARCH" = "amd64" ]; then \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP2/os/adv/lic/base/x86_64/"; \
else \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP2/os/adv/lic/base/aarch64/"; \
fi \
&& echo "[kylin-base]" > /etc/yum.repos.d/kylin.repo \
&& echo "name=Kylin Base" >> /etc/yum.repos.d/kylin.repo \
&& echo "baseurl=$BASEURL" >> /etc/yum.repos.d/kylin.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/kylin.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/kylin.repo \
&& yum clean all \
&& yum makecache --disablerepo="*" --enablerepo="kylin-base"
RUN yum install -y --disablerepo="*" --enablerepo="kylin-base" $BUILD_TOOLS \
&& yum clean all
WORKDIR /package
COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN mkdir -p ${DIR} \
&& yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Downloading $pkg..."; \
yum install -y --downloadonly --downloaddir=${DIR} --disablerepo="*" --enablerepo="kylin-base" $pkg || echo "not found: $pkg"; \
fi; \
done
RUN createrepo_c ${DIR} \
&& genisoimage -r -o ${DIR}.iso ${DIR}
FROM scratch
COPY --from=kylinv10 /package/*.iso /

View File

@ -0,0 +1,44 @@
FROM hxsoong/kylin:v10-sp3 as kylinv10
ARG TARGETARCH
ARG DIR=kylin-v10-${TARGETARCH}-rpms
ARG PKGS=".common[],.rpms[]"
ARG BUILD_TOOLS="createrepo_c genisoimage"
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
RUN if [ "$TARGETARCH" = "amd64" ]; then \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP3/os/adv/lic/base/x86_64/"; \
else \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP3/os/adv/lic/base/aarch64/"; \
fi \
&& echo "[kylin-base]" > /etc/yum.repos.d/kylin.repo \
&& echo "name=Kylin Base" >> /etc/yum.repos.d/kylin.repo \
&& echo "baseurl=$BASEURL" >> /etc/yum.repos.d/kylin.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/kylin.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/kylin.repo \
&& yum clean all \
&& yum makecache --disablerepo="*" --enablerepo="kylin-base"
RUN yum install -y --disablerepo="*" --enablerepo="kylin-base" $BUILD_TOOLS \
&& yum clean all
WORKDIR /package
COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN mkdir -p ${DIR} \
&& yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Downloading $pkg..."; \
yum install -y --downloadonly --downloaddir=${DIR} --disablerepo="*" --enablerepo="kylin-base" $pkg || echo "not found: $pkg"; \
fi; \
done
RUN createrepo_c ${DIR} \
&& genisoimage -r -o ${DIR}.iso ${DIR}
FROM scratch
COPY --from=kylinv10 /package/*.iso /

View File

@ -0,0 +1,44 @@
FROM hxsoong/kylin:v10-sp3 as kylinv10
ARG TARGETARCH
ARG DIR=kylin-v10-${TARGETARCH}-rpms
ARG PKGS=".common[],.rpms[]"
ARG BUILD_TOOLS="createrepo_c genisoimage"
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
RUN if [ "$TARGETARCH" = "amd64" ]; then \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP3-2403/os/adv/lic/base/x86_64/"; \
else \
BASEURL="https://update.cs2c.com.cn/NS/V10/V10SP3-2403/os/adv/lic/base/aarch64/"; \
fi \
&& echo "[kylin-base]" > /etc/yum.repos.d/kylin.repo \
&& echo "name=Kylin Base" >> /etc/yum.repos.d/kylin.repo \
&& echo "baseurl=$BASEURL" >> /etc/yum.repos.d/kylin.repo \
&& echo "enabled=1" >> /etc/yum.repos.d/kylin.repo \
&& echo "gpgcheck=0" >> /etc/yum.repos.d/kylin.repo \
&& yum clean all \
&& yum makecache --disablerepo="*" --enablerepo="kylin-base"
RUN yum install -y --disablerepo="*" --enablerepo="kylin-base" $BUILD_TOOLS \
&& yum clean all
WORKDIR /package
COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN mkdir -p ${DIR} \
&& yq eval "${PKGS}" packages.yaml | while read pkg; do \
if [ -n "$pkg" ]; then \
echo "Downloading $pkg..."; \
yum install -y --downloadonly --downloaddir=${DIR} --disablerepo="*" --enablerepo="kylin-base" $pkg || echo "not found: $pkg"; \
fi; \
done
RUN createrepo_c ${DIR} \
&& genisoimage -r -o ${DIR}.iso ${DIR}
FROM scratch
COPY --from=kylinv10 /package/*.iso /

View File

@ -2,18 +2,14 @@ FROM ubuntu:16.04 as ubuntu1604
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=xenial ARG OS_RELEASE=xenial
ARG DIR=ubuntu-16.04-${TARGETARCH}-debs ARG DIR=ubuntu-16.04-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.ubuntu[],.ubuntu1604[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
# dump system package list # dump system package list
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list
RUN apt update -qq \ RUN apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ && apt install -y --no-install-recommends $BUILD_TOOLS
&& add-apt-repository ppa:gluster/glusterfs-7 -y \
&& curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | apt-key add -qq - \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list\
&& apt update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .

View File

@ -2,18 +2,24 @@ FROM ubuntu:18.04 as ubuntu1804
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=bionic ARG OS_RELEASE=bionic
ARG DIR=ubuntu-18.04-${TARGETARCH}-debs ARG DIR=ubuntu-18.04-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.ubuntu[],.ubuntu1804[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
# dump system package list
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list
RUN apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ RUN apt-get update -qq \
&& add-apt-repository ppa:gluster/glusterfs-7 -y \ && apt-get install -y --no-install-recommends ca-certificates apt-transport-https curl wget gnupg \
&& curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | apt-key add -qq - \ && sed -i 's|http://archive.ubuntu.com/ubuntu/|https://mirrors.huaweicloud.com/ubuntu/|g' /etc/apt/sources.list \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list\ && sed -i 's|http://security.ubuntu.com/ubuntu/|https://mirrors.huaweicloud.com/ubuntu/|g' /etc/apt/sources.list \
&& apt update -qq && apt-get update -qq \
&& apt-get install -y --no-install-recommends software-properties-common dpkg-dev genisoimage \
&& add-apt-repository ppa:gluster/glusterfs-7 -y || true \
&& curl -fsSL https://mirrors.huaweicloud.com/docker-ce/linux/ubuntu/gpg | apt-key add - \
&& echo "deb [arch=${TARGETARCH}] https://mirrors.huaweicloud.com/docker-ce/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list \
&& apt-get update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .
@ -21,7 +27,8 @@ COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN yq eval "${PKGS}" packages.yaml >> packages.list \ RUN yq eval "${PKGS}" packages.yaml >> packages.list \
&& dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 >> packages.list \ && dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 >> packages.list \
&& sort -u packages.list | xargs apt-get install --yes --reinstall --print-uris | awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls && sort -u packages.list | xargs apt-get install --yes --reinstall --print-uris \
| awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls
RUN mkdir -p ${DIR} \ RUN mkdir -p ${DIR} \
&& wget -q -x -P ${DIR} -i packages.urls \ && wget -q -x -P ${DIR} -i packages.urls \

View File

@ -1,28 +1,24 @@
FROM ubuntu:20.04 as ubuntu2004 FROM ubuntu:20.04 as ubuntu2004
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=focal
ARG DIR=ubuntu-20.04-${TARGETARCH}-debs ARG DIR=ubuntu-20.04-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.ubuntu[],.ubuntu2004[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
ENV LANG=en_US.UTF-8
ENV LC_ALL=en_US.UTF-8
# dump system package list
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list
RUN apt update -qq \ RUN apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ && apt install -y --no-install-recommends $BUILD_TOOLS
&& add-apt-repository ppa:gluster/glusterfs-7 -y \
&& curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | apt-key add -qq - \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list\
&& apt update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .
COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq COPY --from=mikefarah/yq:4.11.1 /usr/bin/yq /usr/bin/yq
RUN yq eval "${PKGS}" packages.yaml >> packages.list \
&& sort -u packages.list | xargs apt-get install --yes --reinstall --print-uris | awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls
RUN mkdir -p ${DIR} \ RUN yq eval "${PKGS}" packages.yaml >> packages.list \
&& sort -u packages.list | xargs -n1 apt-get install --yes --reinstall --print-uris | awk -F "'" '{print $2}' | grep -v '^$' | sort -u > packages.urls \
&& mkdir -p ${DIR} \
&& wget -q -x -P ${DIR} -i packages.urls \ && wget -q -x -P ${DIR} -i packages.urls \
&& cd ${DIR} \ && cd ${DIR} \
&& dpkg-scanpackages ./ /dev/null | gzip -9c > ./Packages.gz && dpkg-scanpackages ./ /dev/null | gzip -9c > ./Packages.gz

View File

@ -2,18 +2,14 @@ FROM ubuntu:22.04 as ubuntu2204
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=jammy ARG OS_RELEASE=jammy
ARG DIR=ubuntu-22.04-${TARGETARCH}-debs ARG DIR=ubuntu-22.04-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.ubuntu[],.ubuntu2204[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
# dump system package list # dump system package list
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list
RUN apt update -qq \ RUN apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ && apt install -y --no-install-recommends $BUILD_TOOLS
#&& add-apt-repository ppa:gluster/glusterfs-7 -y \
&& curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | apt-key add -qq - \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list\
&& apt update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .

View File

@ -2,18 +2,15 @@ FROM ubuntu:24.04 as ubuntu2404
ARG TARGETARCH ARG TARGETARCH
ARG OS_RELEASE=lunar ARG OS_RELEASE=lunar
ARG DIR=ubuntu-24.04-${TARGETARCH}-debs ARG DIR=ubuntu-24.04-${TARGETARCH}-debs
ARG PKGS=.common[],.debs[],.ubuntu[],.ubuntu2404[] ARG PKGS=".common[],.debs[]"
ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage" ARG BUILD_TOOLS="apt-transport-https software-properties-common ca-certificates curl wget gnupg dpkg-dev genisoimage"
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
# dump system package list # dump system package list
RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list RUN dpkg --get-selections | grep -v deinstall | cut -f1 | cut -d ':' -f1 > packages.list
RUN apt update -qq \ RUN apt update -qq \
&& apt install -y --no-install-recommends $BUILD_TOOLS \ && apt install -y --no-install-recommends $BUILD_TOOLS
&& curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | apt-key add -qq - \
&& echo "deb [arch=$TARGETARCH] https://download.docker.com/linux/ubuntu ${OS_RELEASE} stable" > /etc/apt/sources.list.d/docker.list \
&& apt update -qq
WORKDIR /package WORKDIR /package
COPY packages.yaml . COPY packages.yaml .

View File

@ -1,92 +1,35 @@
---
common: common:
- curl - bash-completion
- ceph-common
- net-tools
- lvm2
- telnet
- tcpdump
- socat
- openssl
- chrony - chrony
- conntrack - conntrack
- curl - curl
- ipvsadm
- ipset
- psmisc
- bash-completion
- ebtables - ebtables
- git
- haproxy - haproxy
- ipset
- ipvsadm
- keepalived - keepalived
- lvm2
- net-tools
- openssl
- psmisc
- socat
- sudo
- tcpdump
- telnet
rpms: rpms:
- nfs-utils
- yum-utils
- bind-utils - bind-utils
- glusterfs-fuse - conntrack-tools
- lz4 - lz4
- nfs-utils
- nss - nss
- nss-sysinit - nss-sysinit
- nss-tools - nss-tools
- conntrack-tools
debs: debs:
- apt-transport-https - apt-transport-https
- ca-certificates - ca-certificates
- dnsutils - dnsutils
- git
- glusterfs-client
- gnupg-agent - gnupg-agent
- nfs-common - nfs-common
- openssh-server - openssh-server
- software-properties-common - software-properties-common
- sudo
centos:
- containerd.io
centos7:
- libselinux-python
- docker-ce-20.10.8
- docker-ce-cli-20.10.8
debian:
- containerd.io
debian10:
- docker-ce=5:20.10.8~3-0~debian-buster
- docker-ce-cli=5:20.10.8~3-0~debian-buster
debian11:
- docker-ce=5:20.10.8~3-0~debian-bullseye
- docker-ce-cli=5:20.10.8~3-0~debian-bullseye
ubuntu:
- containerd.io
ubuntu1604:
- docker-ce=5:20.10.8~3-0~ubuntu-xenial
- docker-ce-cli=5:20.10.8~3-0~ubuntu-xenial
ubuntu1804:
- docker-ce=5:20.10.8~3-0~ubuntu-bionic
- docker-ce-cli=5:20.10.8~3-0~ubuntu-bionic
ubuntu2004:
- docker-ce=5:20.10.8~3-0~ubuntu-focal
- docker-ce-cli=5:20.10.8~3-0~ubuntu-focal
# The minimum version of docker-ce on ubuntu 2204 is 20.10.13
ubuntu2204:
- docker-ce=5:20.10.13~3-0~ubuntu-jammy
- docker-ce-cli=5:20.10.13~3-0~ubuntu-jammy
ubuntu2404:
- docker-ce=5:20.10.23~3-0~ubuntu-lunar
- docker-ce-cli=5:20.10.23~3-0~ubuntu-lunar
almalinux:
- containerd.io
- docker-compose-plugin
almalinux90:
- docker-ce-20.10.17
- docker-ce-cli-20.10.17