Skip to content

Commit 9e83f0f

Browse files
committed
pass golang version as docker build arg and bump version to 1.22.8
Signed-off-by: Tariq Ibrahim <[email protected]>
1 parent f547761 commit 9e83f0f

File tree

6 files changed

+8
-8
lines changed

6 files changed

+8
-8
lines changed

Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ $(DRIVER_BUILD_TARGETS):
149149
$(DOCKER_BUILD_PLATFORM_OPTIONS) \
150150
--tag $(IMAGE) \
151151
--build-arg DRIVER_VERSION="$(DRIVER_VERSION)" \
152+
--build-arg GOLANG_VERSION="$(GOLANG_VERSION)" \
152153
--build-arg DRIVER_BRANCH="$(DRIVER_BRANCH)" \
153154
--build-arg CUDA_VERSION="$(CUDA_VERSION)" \
154155
--build-arg CVE_UPDATES="$(CVE_UPDATES)" \
@@ -186,6 +187,7 @@ $(BASE_BUILD_TARGETS):
186187
--tag $(IMAGE) \
187188
--target $(TARGET) \
188189
--build-arg CUDA_VERSION="$(CUDA_VERSION)" \
190+
--build-arg GOLANG_VERSION="$(GOLANG_VERSION)" \
189191
--build-arg DRIVER_BRANCH="$(DRIVER_BRANCH)" \
190192
--build-arg KERNEL_FLAVOR="$(KERNEL_FLAVOR)" \
191193
--file $(DOCKERFILE) \

rhel8/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubi8 as build
22

33
ARG TARGETARCH
4+
ARG GOLANG_VERSION
45

56
SHELL ["/bin/bash", "-c"]
67

78
RUN dnf install -y git wget
89

9-
ENV GOLANG_VERSION=1.22.7
10-
1110
# download appropriate binary based on the target architecture for multi-arch builds
1211
RUN OS_ARCH=${TARGETARCH/x86_64/amd64} && OS_ARCH=${OS_ARCH/aarch64/arm64} && \
1312
curl https://storage.googleapis.com/golang/go${GOLANG_VERSION}.linux-${OS_ARCH}.tar.gz \

rhel9/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubi9 as build
22

33
ARG TARGETARCH
4+
ARG GOLANG_VERSION
45

56
SHELL ["/bin/bash", "-c"]
67

78
RUN dnf install -y git wget
89

9-
ENV GOLANG_VERSION=1.22.7
10-
1110
# download appropriate binary based on the target architecture for multi-arch builds
1211
RUN OS_ARCH=${TARGETARCH/x86_64/amd64} && OS_ARCH=${OS_ARCH/aarch64/arm64} && \
1312
curl https://storage.googleapis.com/golang/go${GOLANG_VERSION}.linux-${OS_ARCH}.tar.gz \

ubuntu20.04/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu20.04 as build
22

33
ARG TARGETARCH
4+
ARG GOLANG_VERSION
45

56
SHELL ["/bin/bash", "-c"]
67

@@ -17,8 +18,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
1718
git && \
1819
rm -rf /var/lib/apt/lists/*
1920

20-
ENV GOLANG_VERSION=1.22.7
21-
2221
# download appropriate binary based on the target architecture for multi-arch builds
2322
RUN OS_ARCH=${TARGETARCH/x86_64/amd64} && OS_ARCH=${OS_ARCH/aarch64/arm64} && \
2423
curl https://storage.googleapis.com/golang/go${GOLANG_VERSION}.linux-${OS_ARCH}.tar.gz \

ubuntu22.04/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
FROM nvcr.io/nvidia/cuda:12.6.2-base-ubuntu22.04 as build
22

33
ARG TARGETARCH
4+
ARG GOLANG_VERSION
45

56
SHELL ["/bin/bash", "-c"]
67

@@ -17,8 +18,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
1718
git && \
1819
rm -rf /var/lib/apt/lists/*
1920

20-
ENV GOLANG_VERSION=1.22.7
21-
2221
# download appropriate binary based on the target architecture for multi-arch builds
2322
RUN OS_ARCH=${TARGETARCH/x86_64/amd64} && OS_ARCH=${OS_ARCH/aarch64/arm64} && \
2423
curl https://storage.googleapis.com/golang/go${GOLANG_VERSION}.linux-${OS_ARCH}.tar.gz \

versions.mk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@
1616
DRIVER_VERSIONS ?= 535.183.06 550.90.12 560.35.03
1717

1818
CUDA_VERSION := 12.6.0
19+
20+
GOLANG_VERSION := 1.22.8

0 commit comments

Comments
 (0)