From 4a1492fa99051697a403ea8c630a1946e717b307 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Fri, 19 Nov 2021 15:11:22 +0100 Subject: [PATCH 1/4] Bump post 2.7.0 release Signed-off-by: Evan Lezar --- Makefile | 8 ++++---- debian/changelog.old | 3 +++ rpm/SPECS/nvidia-docker2.spec | 5 ++++- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index fb2dfbaf..e4007846 100644 --- a/Makefile +++ b/Makefile @@ -13,11 +13,11 @@ # limitations under the License. LIB_NAME := nvidia-docker2 -LIB_VERSION := 2.7.0 -LIB_TAG ?= +LIB_VERSION := 2.8.0 +LIB_TAG ?= rc.1 -TOOLKIT_VERSION ?= 1.6.0 -TOOLKIT_TAG ?= +TOOLKIT_VERSION ?= 1.7.0 +TOOLKIT_TAG ?= $(LIB_TAG) # By default run all native docker-based targets docker-native: diff --git a/debian/changelog.old b/debian/changelog.old index b8e85691..6bb6cb73 100644 --- a/debian/changelog.old +++ b/debian/changelog.old @@ -1,3 +1,6 @@ +# Note: as of 2.7.0-1 this file is no longer updated, with a changelog +# entry for a given release generated as part of the packaging step. + nvidia-docker2 (2.7.0-1) UNRELEASED; urgency=medium * Promote 2.7.0~rc.3-1 to 2.7.0-1 diff --git a/rpm/SPECS/nvidia-docker2.spec b/rpm/SPECS/nvidia-docker2.spec index 240d0229..16e3ddc9 100644 --- a/rpm/SPECS/nvidia-docker2.spec +++ b/rpm/SPECS/nvidia-docker2.spec @@ -37,7 +37,10 @@ install -m 644 -t %{buildroot}/etc/docker daemon.json %config /etc/docker/daemon.json %changelog -* Wed Nov 17 2021 NVIDIA CORPORATION 3.6.0-1 +* Fri Nov 19 2021 NVIDIA CORPORATION 2.8.0-0.1.rc.1 +- [Placeholder for 2.8.0-0.1.rc.1 development] + +* Wed Nov 17 2021 NVIDIA CORPORATION 2.7.0-1 - Promote 2.7.0-0.1.rc.3 to 2.7.0-1 * Mon Nov 08 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.3 From a25921bf4c115d550ca5634ee27272beb65196f1 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Wed, 24 Nov 2021 10:24:43 +0100 Subject: [PATCH 2/4] Require that TOOLKIT_VERSION be set externally This change removes the default value for TOOLKIT_VERSION and checks that this is set. A warning is also issued if the package TAGS do not match. Signed-off-by: Evan Lezar --- Makefile | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index e4007846..bf0b9b48 100644 --- a/Makefile +++ b/Makefile @@ -16,8 +16,18 @@ LIB_NAME := nvidia-docker2 LIB_VERSION := 2.8.0 LIB_TAG ?= rc.1 -TOOLKIT_VERSION ?= 1.7.0 -TOOLKIT_TAG ?= $(LIB_TAG) +# Define the nvidia-container-toolkit version on which the nvidia-docker2 +# package depends. It is recommended that the TOOLKIT_TAG and the LIB_TAG match. +TOOLKIT_VERSION ?= # Set by CI +TOOLKIT_TAG ?= # Set by CI + +ifeq ($(strip $(TOOLKIT_VERSION)),) +$(error TOOLKIT_VERSION must be specified) +endif + +ifneq ($(TOOLKIT_TAG),$(LIB_TAG)) +$(warning TOOLKIT_TAG=$(TOOLKIT_TAG) and LIB_TAG=$(LIB_TAG) do not match) +endif # By default run all native docker-based targets docker-native: From 312528d84473716104a447a4d8ebc7a902e06839 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Wed, 24 Nov 2021 10:38:27 +0100 Subject: [PATCH 3/4] Specify dummy TOOLKIT_* values in CI Signed-off-by: Evan Lezar --- .gitlab-ci.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6cdc18c3..8a7ef543 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -4,6 +4,12 @@ stages: - build-one - build-all +variables: + # We specify the TOOLKIT_VERSION and TOOLKIT_TAG variable to allow packages + # to be built. + TOOLKIT_VERSION: 999.999.999 + TOOLKIT_TAG: dummy + .build-setup: &build-setup image: docker:19.03.8 From 960632292d0b87dbf30451666cf00200dce647d6 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Fri, 19 Nov 2021 15:21:36 +0100 Subject: [PATCH 4/4] Generate rpm changelog automatically This change adds a dummy entry that can be updated automatically to the rpm changelog. The existing changelog is moved to a changelog.old file. Signed-off-by: Evan Lezar --- docker/Dockerfile.amazonlinux | 1 + docker/Dockerfile.centos | 1 + docker/Dockerfile.opensuse-leap | 1 + rpm/SPECS/nvidia-docker2.spec | 37 ++++----------------------------- rpm/changelog.old | 31 +++++++++++++++++++++++++++ 5 files changed, 38 insertions(+), 33 deletions(-) create mode 100644 rpm/changelog.old diff --git a/docker/Dockerfile.amazonlinux b/docker/Dockerfile.amazonlinux index ca3b2de3..12cdae2e 100644 --- a/docker/Dockerfile.amazonlinux +++ b/docker/Dockerfile.amazonlinux @@ -33,6 +33,7 @@ RUN sed -i "s;@VERSION@;${PKG_VERS};" $DIST_DIR/nvidia-docker CMD rpmbuild --clean -bb \ -D "_topdir $PWD" \ + -D "release_date $(date +'%a %b %d %Y')" \ -D "version $VERSION" \ -D "release $RELEASE" \ -D "docker_version $DOCKER_VERSION" \ diff --git a/docker/Dockerfile.centos b/docker/Dockerfile.centos index 964eef59..ab26040d 100644 --- a/docker/Dockerfile.centos +++ b/docker/Dockerfile.centos @@ -33,6 +33,7 @@ RUN sed -i "s;@VERSION@;${PKG_VERS};" $DIST_DIR/nvidia-docker CMD rpmbuild --clean -bb \ -D "_topdir $PWD" \ + -D "release_date $(date +'%a %b %d %Y')" \ -D "version $VERSION" \ -D "release $RELEASE" \ -D "docker_version $DOCKER_VERSION" \ diff --git a/docker/Dockerfile.opensuse-leap b/docker/Dockerfile.opensuse-leap index 8309dcac..8c4f06e9 100644 --- a/docker/Dockerfile.opensuse-leap +++ b/docker/Dockerfile.opensuse-leap @@ -33,6 +33,7 @@ RUN sed -i "s;@VERSION@;${PKG_VERS};" $DIST_DIR/nvidia-docker CMD rpmbuild --clean -bb \ -D "_topdir $PWD" \ + -D "release_date $(date +'%a %b %d %Y')" \ -D "version $VERSION" \ -D "release $RELEASE" \ -D "docker_version $DOCKER_VERSION" \ diff --git a/rpm/SPECS/nvidia-docker2.spec b/rpm/SPECS/nvidia-docker2.spec index 16e3ddc9..e70b64e2 100644 --- a/rpm/SPECS/nvidia-docker2.spec +++ b/rpm/SPECS/nvidia-docker2.spec @@ -37,37 +37,8 @@ install -m 644 -t %{buildroot}/etc/docker daemon.json %config /etc/docker/daemon.json %changelog -* Fri Nov 19 2021 NVIDIA CORPORATION 2.8.0-0.1.rc.1 -- [Placeholder for 2.8.0-0.1.rc.1 development] - -* Wed Nov 17 2021 NVIDIA CORPORATION 2.7.0-1 -- Promote 2.7.0-0.1.rc.3 to 2.7.0-1 - -* Mon Nov 08 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.3 - -* Thu Nov 04 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.2 +# As of 2.7.0-1 we generate the release information automatically +* %{release_date} NVIDIA CORPORATION %{version}-%{release} +- As of 2.7.0-1 the package changelog is generated automatically. This means that releases since 2.7.0-1 all contain this same changelog entry updated for the version being released. - Bump nvidia-container-toolkit dependency to %{toolkit_version} -- Allow the toolkit version to be specified as a variable - -* Mon Sep 06 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.1 -- Add AARCH64 package for Amazon Linux 2 -- [BUILD] Allow for TAG to be specified in Makfile to match other projects -- Replace nvidia-container-runtime dependence with nvidia-container-toolit > 1.5.1 - -* Thu Apr 29 2021 NVIDIA CORPORATION 2.6.0-1 -- Add dependence on nvidia-container-runtime >= 3.5.0 -- Add Jenkinsfile for building packages - -* Wed Sep 16 2020 NVIDIA CORPORATION 2.5.0-1 -- Bump version to v2.5.0 -- Add dependence on nvidia-container-runtime >= 3.4.0 -- Update readme to point to the official documentatio -- Add %config directive to daemon.json for RPM installations - -* Wed Jul 08 2020 NVIDIA CORPORATION 2.4.0-1 -- 09a01276 Update package license to match source license -- b9c70155 Update dependence on nvidia-container-runtime to 3.3.0 - -* Fri May 15 2020 NVIDIA CORPORATION 2.3.0-1 -- 0d3b049a Update build system to support multi-arch builds -- 8557216d Require new MIG changes +- Docker dependency to %{docker_version} diff --git a/rpm/changelog.old b/rpm/changelog.old new file mode 100644 index 00000000..366d848a --- /dev/null +++ b/rpm/changelog.old @@ -0,0 +1,31 @@ +* Wed Nov 17 2021 NVIDIA CORPORATION 2.7.0-1 +- Promote 2.7.0-0.1.rc.3 to 2.7.0-1 + +* Mon Nov 08 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.3 + +* Thu Nov 04 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.2 +- Bump nvidia-container-toolkit dependency to %{toolkit_version} +- Allow the toolkit version to be specified as a variable + +* Mon Sep 06 2021 NVIDIA CORPORATION 2.7.0-0.1.rc.1 +- Add AARCH64 package for Amazon Linux 2 +- [BUILD] Allow for TAG to be specified in Makfile to match other projects +- Replace nvidia-container-runtime dependence with nvidia-container-toolit > 1.5.1 + +* Thu Apr 29 2021 NVIDIA CORPORATION 2.6.0-1 +- Add dependence on nvidia-container-runtime >= 3.5.0 +- Add Jenkinsfile for building packages + +* Wed Sep 16 2020 NVIDIA CORPORATION 2.5.0-1 +- Bump version to v2.5.0 +- Add dependence on nvidia-container-runtime >= 3.4.0 +- Update readme to point to the official documentatio +- Add %config directive to daemon.json for RPM installations + +* Wed Jul 08 2020 NVIDIA CORPORATION 2.4.0-1 +- 09a01276 Update package license to match source license +- b9c70155 Update dependence on nvidia-container-runtime to 3.3.0 + +* Fri May 15 2020 NVIDIA CORPORATION 2.3.0-1 +- 0d3b049a Update build system to support multi-arch builds +- 8557216d Require new MIG changes