Skip to content

build(ci): migrate CI from Docker image to devcontainers/ci#196

Merged
MRNIU merged 1 commit intoSimple-XX:mainfrom
MRNIU:fix/ci-devcontainer
Mar 19, 2026
Merged

build(ci): migrate CI from Docker image to devcontainers/ci#196
MRNIU merged 1 commit intoSimple-XX:mainfrom
MRNIU:fix/ci-devcontainer

Conversation

@MRNIU
Copy link
Member

@MRNIU MRNIU commented Mar 19, 2026

Summary

  • 将 CI 从 addnab/docker-run-action + ptrnull233/simple_kernel:latest(GCC 13)迁移到 devcontainers/ci@v0.3
  • CI 现在使用项目的 .devcontainer/Dockerfile(GCC 14),与本地开发环境一致

Motivation

PR #195 合入后 CI 构建失败,因为代码使用了 C++23 deducing this(this auto self)语法,需要 GCC 14+,但旧 Docker 镜像仅包含 GCC 13。

Changes

Before After
addnab/docker-run-action@v3 devcontainers/ci@v0.3
ptrnull233/simple_kernel:latest (GCC 13) .devcontainer/Dockerfile (GCC 14)
环境变量传递 CMAKE_BUILD_TYPE 使用 preset 默认配置

Replace addnab/docker-run-action with devcontainers/ci@v0.3 to use
the project's .devcontainer/Dockerfile (GCC 14) instead of the outdated
ptrnull233/simple_kernel:latest image (GCC 13).

Fixes build failures caused by C++23 deducing-this requiring GCC 14+.

Signed-off-by: Niu Zhihong <zhihong@nzhnb.com>
Copilot AI review requested due to automatic review settings March 19, 2026 07:09
@MRNIU MRNIU merged commit e675be7 into Simple-XX:main Mar 19, 2026
4 checks passed
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the GitHub Actions CI workflow to build inside the repository’s Dev Container (GCC 14) instead of a prebuilt Docker image (GCC 13), aligning CI with the local development environment and unblocking C++23 builds (e.g., “deducing this”).

Changes:

  • Replace addnab/docker-run-action@v3 + external image with devcontainers/ci@v0.3.
  • Run the existing CMake presets (build_x86_64, build_riscv64, build_aarch64) inside the devcontainer.
  • Remove workflow-level CMAKE_BUILD_TYPE / DOCKER_IMAGE env config (relying on preset configuration).

Comment on lines 24 to 30
- name: x86_64
uses: addnab/docker-run-action@v3
uses: devcontainers/ci@v0.3
with:
image: ${{ env.DOCKER_IMAGE }}
options: -v ${{ github.workspace }}:/root -e CMAKE_BUILD_TYPE=${{ env.CMAKE_BUILD_TYPE }}
run: |
runCmd: |
cmake --preset=build_x86_64
cmake --build build_x86_64 --target SimpleKernel unit-test coverage docs

Comment on lines +25 to 29
uses: devcontainers/ci@v0.3
with:
image: ${{ env.DOCKER_IMAGE }}
options: -v ${{ github.workspace }}:/root -e CMAKE_BUILD_TYPE=${{ env.CMAKE_BUILD_TYPE }}
run: |
runCmd: |
cmake --preset=build_x86_64
cmake --build build_x86_64 --target SimpleKernel unit-test coverage docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants