Skip to content

Commit ad111f3

Browse files
tariq1890shivakunv
authored andcommitted
ubuntu24.04 precompile image support
Signed-off-by: shiva kumar <[email protected]>
1 parent eea136d commit ad111f3

File tree

11 files changed

+364
-51
lines changed

11 files changed

+364
-51
lines changed

.common-ci.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,13 @@ trigger-pipeline:
8888
- DRIVER_BRANCH: [535, 550]
8989
KERNEL_FLAVOR: [aws, azure, generic, nvidia, oracle]
9090

91+
# Define the matrix of precompiled jobs that can be run in parallel for ubuntu24.04
92+
.driver-versions-precompiled-ubuntu24.04:
93+
parallel:
94+
matrix:
95+
- DRIVER_BRANCH: [550]
96+
KERNEL_FLAVOR: [aws, azure, generic, nvidia, oracle]
97+
9198
# Define the distribution targets
9299
.dist-ubuntu20.04:
93100
variables:
@@ -304,3 +311,14 @@ release:staging-precompiled-ubuntu22.04:
304311
- .release:staging-precompiled
305312
needs:
306313
- image-precompiled-ubuntu22.04
314+
315+
# Precompiled Ubuntu24.04 release
316+
release:staging-precompiled-ubuntu24.04:
317+
variables:
318+
DIST: signed_ubuntu24.04
319+
BASE_TARGET: noble
320+
extends:
321+
- .driver-versions-precompiled-ubuntu24.04
322+
- .release:staging-precompiled
323+
needs:
324+
- image-precompiled-ubuntu24.04

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
4141
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
4242
aws_ssh_key: ${{ secrets.AWS_SSH_KEY }}
43-
holodeck_config: "tests/holodeck.yaml"
43+
holodeck_config: "tests/holodeck_ubuntu22.04.yaml"
4444

4545
- name: Get public dns name
4646
id: get_public_dns_name

.github/workflows/precompiled.yaml

Lines changed: 156 additions & 41 deletions
Large diffs are not rendered by default.

.gitlab-ci.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,3 +120,12 @@ image-precompiled-ubuntu22.04:
120120
extends:
121121
- .driver-versions-precompiled-ubuntu22.04
122122
- .image-build-precompiled
123+
124+
image-precompiled-ubuntu24.04:
125+
variables:
126+
DIST: signed_ubuntu24.04
127+
BASE_TARGET: noble
128+
CVE_UPDATES: "curl libc6"
129+
extends:
130+
- .driver-versions-precompiled-ubuntu24.04
131+
- .image-build-precompiled

.nvidia-ci.yml

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,30 @@ variables:
7777
- !reference [.image-pull-rules, rules]
7878

7979

80+
.image-pull-ubuntu24.04:
81+
# Perform for each DRIVER_VERSION
82+
extends:
83+
- .driver-versions
84+
- .image-pull-generic
85+
rules:
86+
- if: $CI_PIPELINE_SOURCE == "schedule"
87+
when: never
88+
- !reference [.image-pull-rules, rules]
89+
90+
image-precompiled-ubuntu24.04:
91+
variables:
92+
DIST: signed_ubuntu24.04
93+
BASE_TARGET: noble
94+
PRECOMPILED: "true"
95+
CVE_UPDATES: "curl libc6"
96+
rules:
97+
- when: delayed
98+
start_in: 30 minutes
99+
extends:
100+
- .driver-versions-precompiled-ubuntu24.04
101+
- .image-pull-generic
102+
103+
80104
.image-pull-ubuntu22.04:
81105
# Perform for each DRIVER_VERSION
82106
extends:
@@ -196,6 +220,18 @@ image-rhel8:
196220
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
197221
- !reference [.pipeline-trigger-rules, rules]
198222

223+
.scan-precompiled-ubuntu24.04:
224+
variables:
225+
DIST: signed_ubuntu24.04
226+
BASE_TARGET: noble
227+
PRECOMPILED: "true"
228+
extends:
229+
- .driver-versions-precompiled-ubuntu24.04
230+
- .scan-generic
231+
rules:
232+
- !reference [.scan-rules-common, rules]
233+
- when: always
234+
199235
.scan-precompiled-ubuntu22.04:
200236
variables:
201237
DIST: signed_ubuntu22.04
@@ -306,6 +342,26 @@ release:ngc-ubuntu22.04:
306342
- .dist-ubuntu22.04
307343
- .driver-versions
308344

345+
# TODO will be enabled after QA
346+
# release:ngc-ubuntu24.04:
347+
# extends:
348+
# - .release:ngc
349+
# - .dist-ubuntu24.04
350+
# - .driver-versions
351+
352+
# release:ngc-precompiled-ubuntu24.04:
353+
# variables:
354+
# DIST: signed_ubuntu24.04
355+
# BASE_TARGET: noble
356+
# PRECOMPILED: "true"
357+
# extends:
358+
# - .driver-versions-precompiled-ubuntu24.04
359+
# - .release-generic
360+
# - .release:ngc-variables
361+
# rules:
362+
# # Only run NGC release job on scheduled pipelines
363+
# - if: $CI_PIPELINE_SOURCE == "schedule"
364+
309365
release:ngc-precompiled-ubuntu22.04:
310366
variables:
311367
DIST: signed_ubuntu22.04
@@ -433,6 +489,23 @@ release:ngc-rhel8.10:
433489
- 'echo "Signing the image ${IMAGE_NAME}:${IMAGE_TAG}"'
434490
- ngc-cli/ngc registry image publish --source ${IMAGE_NAME}:${IMAGE_TAG} ${IMAGE_NAME}:${IMAGE_TAG} --public --discoverable --allow-guest --sign --org nvidia
435491

492+
sign:ngc-precompiled-ubuntu24.04:
493+
extends:
494+
- .driver-versions-precompiled-ubuntu24.04
495+
- .dist-ubuntu22.04
496+
- .release-generic
497+
- .release:ngc-variables
498+
- .sign:ngc
499+
variables:
500+
DIST: signed_ubuntu24.04
501+
BASE_TARGET: noble
502+
PRECOMPILED: "true"
503+
needs:
504+
- release:ngc-precompiled-ubuntu24.04
505+
rules:
506+
# Only run NGC release job on scheduled pipelines
507+
- if: $CI_PIPELINE_SOURCE == "schedule"
508+
436509
sign:ngc-precompiled-ubuntu22.04:
437510
extends:
438511
- .driver-versions-precompiled-ubuntu22.04
@@ -455,6 +528,9 @@ sign:ngc-ubuntu-rhel-rhcos:
455528
- .sign:ngc
456529
parallel:
457530
matrix:
531+
- SIGN_JOB_NAME: ["ubuntu"]
532+
VERSION: ["24.04"]
533+
DRIVER_VERSION: ["550.127.08"]
458534
- SIGN_JOB_NAME: ["ubuntu"]
459535
VERSION: ["22.04"]
460536
DRIVER_VERSION: ["535.216.03", "550.127.08"]

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ OUT_IMAGE = $(OUT_IMAGE_NAME):$(OUT_IMAGE_TAG)
5656
##### Public rules #####
5757
DISTRIBUTIONS := ubuntu18.04 ubuntu20.04 ubuntu22.04 ubuntu24.04 signed_ubuntu20.04 signed_ubuntu22.04 signed_ubuntu24.04 rhel8 rhel9 flatcar fedora36 sles15.3 precompiled_rhcos
5858
PUSH_TARGETS := $(patsubst %, push-%, $(DISTRIBUTIONS))
59-
BASE_FROM := jammy focal
59+
BASE_FROM := noble jammy focal
6060
PUSH_TARGETS := $(patsubst %, push-%, $(DISTRIBUTIONS))
6161
DRIVER_PUSH_TARGETS := $(foreach push_target, $(PUSH_TARGETS), $(addprefix $(push_target)-, $(DRIVER_VERSIONS)))
6262
BUILD_TARGETS := $(patsubst %, build-%, $(DISTRIBUTIONS))
@@ -210,6 +210,7 @@ $(BASE_BUILD_TARGETS):
210210
--build-arg GOLANG_VERSION="$(GOLANG_VERSION)" \
211211
--build-arg DRIVER_BRANCH="$(DRIVER_BRANCH)" \
212212
--build-arg KERNEL_FLAVOR="$(KERNEL_FLAVOR)" \
213+
--build-arg LTS_KERNEL="$(LTS_KERNEL)" \
213214
--file $(DOCKERFILE) \
214215
$(CURDIR)/base
215216

base/Dockerfile

Lines changed: 43 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,51 @@
1+
# Ubuntu 24.04
2+
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu24.04 AS noble
3+
4+
SHELL ["/bin/bash", "-c"]
5+
6+
ARG DRIVER_BRANCH
7+
ARG KERNEL_FLAVOR
8+
ARG LTS_KERNEL
9+
ENV DRIVER_BRANCH=${DRIVER_BRANCH}
10+
ENV KERNEL_FLAVOR=${KERNEL_FLAVOR}
11+
ENV LTS_KERNEL=${LTS_KERNEL}
12+
13+
# Remove cuda repository to avoid GPG errors
14+
RUN rm -f /etc/apt/sources.list.d/cuda*
15+
16+
RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections
17+
18+
ENV NVIDIA_VISIBLE_DEVICES=void
19+
20+
RUN apt-get update && apt-get install -y --no-install-recommends \
21+
apt-utils git curl && \
22+
rm -rf /var/lib/apt/lists/*
23+
24+
RUN echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ noble main universe" > /etc/apt/sources.list && \
25+
echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ noble-updates main universe" >> /etc/apt/sources.list && \
26+
echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ noble-security main universe" >> /etc/apt/sources.list && \
27+
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu noble-updates main restricted" >> /etc/apt/sources.list && \
28+
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu noble-security main restricted" >> /etc/apt/sources.list && \
29+
usermod -o -u 0 -g 0 _apt
30+
31+
COPY generate-ci-config /usr/local/bin/generate-ci-config
32+
33+
RUN chmod +x /usr/local/bin/generate-ci-config && \
34+
generate-ci-config
35+
36+
ENTRYPOINT ["/usr/bin/sleep","1000"]
37+
138
# Ubuntu 22.04
2-
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu22.04 as jammy
39+
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu22.04 AS jammy
340

441
SHELL ["/bin/bash", "-c"]
542

643
ARG DRIVER_BRANCH
744
ARG KERNEL_FLAVOR
45+
ARG LTS_KERNEL
846
ENV DRIVER_BRANCH=${DRIVER_BRANCH}
947
ENV KERNEL_FLAVOR=${KERNEL_FLAVOR}
48+
ENV LTS_KERNEL=${LTS_KERNEL}
1049

1150
# Remove cuda repository to avoid GPG errors
1251
RUN rm -f /etc/apt/sources.list.d/cuda*
@@ -34,14 +73,16 @@ RUN chmod +x /usr/local/bin/generate-ci-config && \
3473
ENTRYPOINT ["/usr/bin/sleep","1000"]
3574

3675
# Ubuntu 20.04
37-
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu20.04 as focal
76+
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu20.04 AS focal
3877

3978
SHELL ["/bin/bash", "-c"]
4079

4180
ARG DRIVER_BRANCH
4281
ARG KERNEL_FLAVOR
82+
ARG LTS_KERNEL
4383
ENV DRIVER_BRANCH=${DRIVER_BRANCH}
4484
ENV KERNEL_FLAVOR=${KERNEL_FLAVOR}
85+
ENV LTS_KERNEL=${LTS_KERNEL}
4586

4687
# Remove cuda repository to avoid GPG errors
4788
RUN rm -f /etc/apt/sources.list.d/cuda*
File renamed without changes.

tests/holodeck_ubuntu24.04.yaml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
apiVersion: holodeck.nvidia.com/v1alpha1
2+
kind: Environment
3+
metadata:
4+
name: HOLODECK_NAME
5+
description: "end-to-end test infrastructure"
6+
spec:
7+
provider: aws
8+
auth:
9+
keyName: cnt-ci
10+
privateKey: HOLODECK_PRIVATE_KEY
11+
instance:
12+
type: g4dn.xlarge
13+
region: us-west-1
14+
ingressIpRanges:
15+
- 18.190.12.32/32
16+
- 3.143.46.93/32
17+
- 52.15.119.136/32
18+
- 35.155.108.162/32
19+
- 35.162.190.51/32
20+
- 54.201.61.24/32
21+
image:
22+
architecture: amd64
23+
imageId: ami-0da424eb883458071
24+
containerRuntime:
25+
install: true
26+
name: containerd
27+
version: 1.7.22
28+
kubernetes:
29+
install: true
30+
installer: kubeadm
31+
version: v1.30.0
32+
crictlVersion: v1.30.0

tests/scripts/ci-precompiled-helpers.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
get_kernel_versions_to_test() {
22
if [[ "$#" -ne 4 ]]; then
3-
echo " Error:$0 must be called with BASE_TARGET DRIVER_BRANCHES DRIVER_BRANCHES DIST" >&2
3+
echo " Error:$0 must be called with BASE_TARGET KERNEL_FLAVORS DRIVER_BRANCHES DIST" >&2
44
exit 1
55
fi
66

@@ -11,9 +11,10 @@ get_kernel_versions_to_test() {
1111

1212
kernel_versions=()
1313
for kernel_flavor in "${KERNEL_FLAVORS[@]}"; do
14-
# FIXME -- remove if condition, once azure kernel upgrade starts working
15-
if [[ "$kernel_flavor" == "azure" ]]; then
16-
continue
14+
# TODO remove this check once nvidia avaialble
15+
# currently for ubuntu24.04 flavor = nvidia-lowlatency
16+
if [[ "$DIST" == "ubuntu24.04" && "$kernel_flavor" == "nvidia" ]]; then
17+
kernel_flavor="nvidia-lowlatency"
1718
fi
1819
for DRIVER_BRANCH in "${DRIVER_BRANCHES[@]}"; do
1920
source ./tests/scripts/findkernelversion.sh "$BASE_TARGET" "${kernel_flavor}" "$DRIVER_BRANCH" "$DIST" >&2

0 commit comments

Comments
 (0)