diff --git a/deployments/container/Dockerfile.centos b/deployments/container/Dockerfile.centos index 96b943ea..1bad4758 100644 --- a/deployments/container/Dockerfile.centos +++ b/deployments/container/Dockerfile.centos @@ -12,12 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG BASE_DIST -ARG CUDA_VERSION ARG GOLANG_VERSION=x.x.x ARG VERSION="N/A" -FROM nvidia/cuda:${CUDA_VERSION}-base-${BASE_DIST} as build +FROM nvidia/cuda:12.3.2-base-ubi8 as build RUN yum install -y \ wget make git gcc \ @@ -50,17 +48,10 @@ COPY . . RUN GOPATH=/artifacts go install -ldflags="-s -w -X 'main.Version=${VERSION}'" ./tools/... -FROM nvidia/cuda:${CUDA_VERSION}-base-${BASE_DIST} +FROM nvidia/cuda:12.3.2-base-ubi8 -ARG BASE_DIST -# See https://www.centos.org/centos-linux-eol/ -# and https://stackoverflow.com/a/70930049 for move to vault.centos.org -# and https://serverfault.com/questions/1093922/failing-to-run-yum-update-in-centos-8 for move to vault.epel.cloud -RUN [[ "${BASE_DIST}" != "centos8" ]] || \ - ( \ - sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-* && \ - sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.epel.cloud|g' /etc/yum.repos.d/CentOS-Linux-* \ - ) +RUN sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-* && \ + sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.epel.cloud|g' /etc/yum.repos.d/CentOS-Linux-* \ ENV NVIDIA_DISABLE_REQUIRE="true" ENV NVIDIA_VISIBLE_DEVICES=void diff --git a/deployments/container/Dockerfile.packaging b/deployments/container/Dockerfile.packaging index 1613c5b8..c96b028f 100644 --- a/deployments/container/Dockerfile.packaging +++ b/deployments/container/Dockerfile.packaging @@ -12,11 +12,9 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG BASE_DIST -ARG CUDA_VERSION ARG GOLANG_VERSION=x.x.x -FROM nvidia/cuda:${CUDA_VERSION}-base-${BASE_DIST} +FROM nvidia/cuda:12.3.2-base-ubuntu20.04 ARG ARTIFACTS_ROOT COPY ${ARTIFACTS_ROOT} /artifacts/packages/ @@ -24,7 +22,6 @@ COPY ${ARTIFACTS_ROOT} /artifacts/packages/ WORKDIR /artifacts/packages # build-args are added to the manifest.txt file below. -ARG BASE_DIST ARG PACKAGE_DIST ARG PACKAGE_VERSION ARG GIT_BRANCH diff --git a/deployments/container/Dockerfile.ubuntu b/deployments/container/Dockerfile.ubuntu index dd50f883..d2233252 100644 --- a/deployments/container/Dockerfile.ubuntu +++ b/deployments/container/Dockerfile.ubuntu @@ -12,12 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG BASE_DIST -ARG CUDA_VERSION ARG GOLANG_VERSION=x.x.x ARG VERSION="N/A" -FROM nvidia/cuda:${CUDA_VERSION}-base-${BASE_DIST} as build +FROM nvidia/cuda:12.3.2-base-ubuntu20.04 as build RUN apt-get update && \ apt-get install -y wget make git gcc \ @@ -49,7 +47,7 @@ COPY . . RUN GOPATH=/artifacts go install -ldflags="-s -w -X 'main.Version=${VERSION}'" ./tools/... -FROM nvcr.io/nvidia/cuda:${CUDA_VERSION}-base-${BASE_DIST} +FROM nvcr.io/nvidia/cuda:12.3.2-base-ubuntu20.04 # Remove the CUDA repository configurations to avoid issues with rotated GPG keys RUN rm -f /etc/apt/sources.list.d/cuda.list diff --git a/deployments/container/Makefile b/deployments/container/Makefile index 6e44ccd8..ee0dd2ec 100644 --- a/deployments/container/Makefile +++ b/deployments/container/Makefile @@ -96,8 +96,6 @@ $(BUILD_TARGETS): build-%: $(ARTIFACTS_ROOT) $(DOCKER_BUILD_PLATFORM_OPTIONS) \ --tag $(IMAGE) \ --build-arg ARTIFACTS_ROOT="$(ARTIFACTS_ROOT)" \ - --build-arg BASE_DIST="$(BASE_DIST)" \ - --build-arg CUDA_VERSION="$(CUDA_VERSION)" \ --build-arg GOLANG_VERSION="$(GOLANG_VERSION)" \ --build-arg PACKAGE_DIST="$(PACKAGE_DIST)" \ --build-arg PACKAGE_VERSION="$(PACKAGE_VERSION)" \ @@ -110,15 +108,12 @@ $(BUILD_TARGETS): build-%: $(ARTIFACTS_ROOT) $(CURDIR) -build-ubuntu%: BASE_DIST = $(*) build-ubuntu%: DOCKERFILE_SUFFIX := ubuntu build-ubuntu%: PACKAGE_DIST = ubuntu18.04 -build-ubi8: BASE_DIST := ubi8 build-ubi8: DOCKERFILE_SUFFIX := centos build-ubi8: PACKAGE_DIST = centos7 -build-packaging: BASE_DIST := ubuntu20.04 build-packaging: DOCKERFILE_SUFFIX := packaging build-packaging: PACKAGE_ARCH := amd64 build-packaging: PACKAGE_DIST = all diff --git a/versions.mk b/versions.mk index c9dae147..0a86da30 100644 --- a/versions.mk +++ b/versions.mk @@ -27,7 +27,6 @@ PACKAGE_REVISION := 1 NVIDIA_DOCKER_VERSION := 2.14.0 NVIDIA_CONTAINER_RUNTIME_VERSION := 3.14.0 -CUDA_VERSION := 12.3.2 GOLANG_VERSION := 1.22.1 BUILDIMAGE_TAG ?= devel-go$(GOLANG_VERSION)