diff --git a/AI/cuda/12.1.1/23/base/Dockerfile b/AI/cuda/12.1.1/23/base/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..abfabc88de13daf5b7089b51be1b3eac34b552a7 --- /dev/null +++ b/AI/cuda/12.1.1/23/base/Dockerfile @@ -0,0 +1,11 @@ +FROM registry.openanolis.cn/openanolis/anolisos:23 + +LABEL \ + maintainer="OpenAnolis AI SIG" \ + org.opencontainers.image.title="cuda base with cudart" \ + org.opencontainers.image.version="12.1.1-23-base" + +RUN dnf install anolis-epao-release -y +RUN dnf install cuda-cudart-12-1 cuda-compat-12-1 -y + +CMD ["/bin/bash"] diff --git a/AI/cuda/README.md b/AI/cuda/README.md index 62e41b38330884251be837d4d2efcc85ee6e32cd..60b40c8bd799578be0a46af56b041328470bb16b 100644 --- a/AI/cuda/README.md +++ b/AI/cuda/README.md @@ -7,6 +7,12 @@ # Supported tags and respective `Dockerfile` links +Three flavors of cuda images are provides: +* base: includes CUDA runtime(cudart) +* runtime: based on base and includes CUDA libraries. +* devel: based on runtime and includes headers and development tools. + +- [`12.1.1-23-base`](https://gitee.com/anolis/anolis-container/AI/blob/master/cuda/12.1.1/23/base/Dockerfile) - [`12.1.1-23-runtime`](https://gitee.com/anolis/anolis-container/AI/blob/master/cuda/12.1.1/23/runtime/Dockerfile) - [`12.1.1-23-devel`](https://gitee.com/anolis/anolis-container/AI/blob/master/cuda/12.1.1/23/devel/Dockerfile) @@ -25,6 +31,7 @@ docker buildx build -t "openanolis/cuda:$VERSION" --platform linux/amd64,linux/a ## Start a cuda instance ```shell +docker run --name cuda-base-test openanolis/cuda:12.1.1-23-base docker run --name cuda-runtime-test openanolis/cuda:12.1.1-23-runtime docker run --name cuda-devel-test openanolis/cuda:12.1.1-23-devel ``` diff --git a/AI/cuda/buildspec.yml b/AI/cuda/buildspec.yml index 1dc0aca9c867a111b2656156dddeee5bf8e16551..7ee27a411880bc07b4eb8cd899fd2cd569bdb998 100644 --- a/AI/cuda/buildspec.yml +++ b/AI/cuda/buildspec.yml @@ -22,6 +22,18 @@ t-one: # 构建镜像配置 images: # 分组名称,支持自定义 + BuildCudaBaseDockerImage: + # 定义是否构建参数 + build: true + docker_file: + path: AI/cuda/12.1.1/23/base/Dockerfile + scene: + args: [] + tags: [12.1.1-23-base] + registry: [*ACR_PROD] + # 测试配置 + test_config: [*WORKSPACE, *PROJECT, *TEST_SUITE, *TEST_CONF, '', *CLOUD_SERVER_TAG[0], ''] + # 分组名称,支持自定义 BuildCudaRuntimeDockerImage: # 定义是否构建参数 build: true