From 3e9e4eac821fdbc953ec31be97625e94957bc6a1 Mon Sep 17 00:00:00 2001 From: xulei Date: Fri, 21 Apr 2023 17:42:42 +0800 Subject: [PATCH] containerd: add check in spec --- apply-patch | 14 ++- containerd.spec | 17 ++- patch/0001-containerd-add-check-in-spec.patch | 24 ++++ series.conf | 103 +----------------- 4 files changed, 53 insertions(+), 105 deletions(-) create mode 100644 patch/0001-containerd-add-check-in-spec.patch diff --git a/apply-patch b/apply-patch index 24d7d0b..82384d2 100755 --- a/apply-patch +++ b/apply-patch @@ -12,6 +12,9 @@ cwd=$PWD src=$cwd/$pkg unzip v1.6.20.zip +if [[ ! -d patch ]]; then + tar zxf patch.tar.gz +fi cd $src git init @@ -21,6 +24,15 @@ git config user.email 'build@obs.com' git commit -m 'init build' cd $cwd +series=$cwd/series.conf +while IPF= read -r line +do + if [[ "$line" =~ ^patch* ]]; then + echo git apply $cwd/$line + cd $src && git apply $cwd/$line + fi +done <"$series" +cd $cwd cp -rf $src/* . mv $src/.git $src/git -rm -rf containerd-1.6.18 +rm -rf containerd-1.6.20 diff --git a/containerd.spec b/containerd.spec index 1ec8a30..f9e4377 100644 --- a/containerd.spec +++ b/containerd.spec @@ -2,12 +2,16 @@ %global debug_package %{nil} Version: 1.6.20 Name: containerd -Release: 1 +Release: 2 Summary: An industry-standard container runtime License: ASL 2.0 URL: https://containerd.io Source0: https://github.com/containerd/containerd/archive/v1.6.20.zip -Source1: apply-patch +Source1: patch.tar.gz +Source2: apply-patch +Source3: series.conf +Source4: git-commit +Source5: gen-commit.sh BuildRequires: golang glibc-static make btrfs-progs-devel git @@ -21,6 +25,9 @@ low-level storage and network attachments, etc. %prep cp %{SOURCE0} . cp %{SOURCE1} . +cp %{SOURCE2} . +cp %{SOURCE3} . +cp %{SOURCE4} . %build echo %{VERSION}.%{RELEASE} > containerd_version @@ -48,6 +55,12 @@ install -p -m 755 bin/ctr $RPM_BUILD_ROOT/%{_bindir}/ctr %{_bindir}/ctr %changelog +* Fri Apr 21 2023 xulei - 1.6.20-2 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:add check in spec + * Wed Apr 19 2023 xulei - 1.6.20-1 - Type:bugfix - ID:NA diff --git a/patch/0001-containerd-add-check-in-spec.patch b/patch/0001-containerd-add-check-in-spec.patch new file mode 100644 index 0000000..d601da5 --- /dev/null +++ b/patch/0001-containerd-add-check-in-spec.patch @@ -0,0 +1,24 @@ +From 1ee9382e8af3ff3c6f46361366bad3e4f38e0ba9 Mon Sep 17 00:00:00 2001 +From: xulei +Date: Fri, 21 Apr 2023 14:49:54 +0800 +Subject: [PATCH] containerd: add check in spec + +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 7441eea..31e96f5 100644 +--- a/Makefile ++++ b/Makefile +@@ -203,7 +203,7 @@ build: ## build the go packages + + test: ## run tests, except integration tests and tests that require root + @echo "$(WHALE) $@" +- @$(GOTEST) ${TESTFLAGS} ${PACKAGES} ++ @$(GOTEST) ${TESTFLAGS} ./gc + + root-test: ## run tests, except integration tests + @echo "$(WHALE) $@" +-- +2.33.0 diff --git a/series.conf b/series.conf index 48dc813..459d06a 100644 --- a/series.conf +++ b/series.conf @@ -1,102 +1 @@ -patch/0006-shim-optimize-shim-lock-in-runtime-v1.patch -patch/0007-shim-Increase-reaper-buffer-size-and-non-bl.patch -patch/0008-runtime-Use-named-pipes-for-shim-logs.patch -patch/0009-runtime-fix-pipe-in-broken-may-cause-shim-l.patch -patch/0010-runtime-fix-pipe-in-broken-may-cause-shim-l.patch -patch/0011-runtime-Add-timeout-and-cancel-to-shim-fifo.patch -patch/0037-containerd-Fix-fd-leak-of-shim-log.patch - -patch/0001-grpc-vendor-grpc-fix-grpc-map-panic.patch -patch/0002-sys-sys-count-steal-time-when-calculating-Sys.patch -patch/0003-oci-oci-add-files-cgroups-support.patch -patch/0004-runv-vendor-runv-compatibility.patch -patch/0005-containerd-add-spec-for-build.patch -patch/0012-bump-bump-containerd-to-1.2.0.2.patch -patch/0013-log-support-log-init-pid-to-start-event-log.patch -patch/0014-event-resend-exit-event-when-detect-container.patch -patch/0015-restore-cleanup-container-pid-1.patch -patch/0016-create-runc-delete-force-before-create.patch -patch/0017-exit-using-init.exit-indicate-container-is-ex.patch -patch/0018-containerd-shim-Dump-log-to-file-when-docker-.patch -patch/0019-restore-check-shim-alive-when-containerd-is-r.patch -patch/0020-events-resend-pending-exit-events-on-restore.patch -patch/0021-containerd-Update-the-version-info-of-contain.patch -patch/0022-containerd-bump-version-1.2.0.4.patch -patch/0023-containerd-set-create-and-exec-timeout.patch -patch/0024-create-cleanup-runc-dirty-files-on-start.patch -patch/0025-restore-skip-load-task-in-creating.patch -patch/0026-exit-optimize-init.exit-record.patch -patch/0027-log-make-tester-happy.patch -patch/0028-restore-delete-task-in-containerd-restoring.patch -patch/0029-restore-delete-task-asynchronously.patch -patch/0030-event-fix-events-lost-when-loadTask-failed.patch -patch/0031-containerd-enable-relro-flags.patch -patch/0032-containerd-enable-bep-ldflags.patch -patch/0033-containerd-fix-opened-file-not-close.patch -patch/0034-containerd-add-buildid-in-Makefile.patch -patch/0035-containerd-fix-the-path-of-containerd.spec-in.patch -patch/0036-containerd-support-container-start-timeout-se.patch -patch/0037-containerd-fix-shim-std-logs-not-close-after-.patch -patch/0038-containerd-support-kill-D-state-container.patch -patch/0039-containerd-modify-containerd-shim-to-ad.patch -patch/0040-containerd-add-shim-exit-when-bundle-dir-does.patch -patch/0041-containerd-fix-containerd-call-runv-delete-directly.patch -patch/0042-containerd-close-inherit-shim.sock-fd-to-adap.patch -patch/0043-containerd-run-state-with-timeout-10s.patch -patch/0044-containerd-add-copyright.patch -patch/0038-containerd-add-timeout-for-I-O-waitgroups.patch -patch/0039-containerd-fix-shouldKillAllOnExit-check.patch -patch/0044-containerd-change-tmpfile-directory-when-exec.patch -patch/0045-containerd-shim-disable-fast-gc-on-arm.patch -patch/0046-containerd-support-hot-upgrade.patch -patch/0047-containerd-shim-exit-initiative-after-3s.patch -patch/0048-containerd-modify-shim-initiative-exit-time.patch -patch/0049-contaienrd-modify-shim-initiative-exit-time-for-post-hook.patch -patch/0050-containerd-warp-and-process-return-errors.patch -patch/0051-containerd-add-timeout-for-containerd-shim.patch -patch/0052-containerd-modify-runtime-root-if-containe.patch -patch/0053-containerd-add-pid-check-to-avoid-poststop-ho.patch -patch/0054-containerd-clean-up-residual-container.patch -patch/0055-containerd-add-LLT-for-containerd-shim-timeou.patch -patch/0056-containerd-save-dumpstack-to-file.patch -patch/0057-containerd-add-timeout-for-delete-command.patch -patch/0058-containerd-use-git-commit-to-store-commit-ID.patch -patch/0059-containerd-add-GO_GCFLAGS-to-containerd-shim-making.patch -patch/0060-containerd-do-not-disable-cgo-in-containerd-shim-mak.patch -patch/0061-containerd-check-if-bundle-exists-before-create-bund.patch -patch/0062-containerd-use-path-based-socket-for-shims.patch -patch/0063-containerd-kill-init-directly-if-runtime-kill-failed.patch -patch/0064-containerd-add-sys-symbol-to-support-riscv.patch -patch/0065-containerd-add-blot-symbol-to-support-riscv.patch -patch/0064-containerd-check-task-list-to-avoid-unnecessary-clea.patch -patch/0065-containerd-fix-dead-loop.patch -patch/0066-containerd-cleanup-dangling-shim-by-brand-new-context.patch -patch/0067-containerd-fix-potential-panic-for-task-in-unknown-state.patch -patch/0068-containerd-compile-option-compliance.patch -patch/0069-containerd-add-check-in-spec.patch -patch/0070-containerd-kill-container-init-process-if-runc-start.patch -patch/0071-containerd-fix-containerd-shim-residual-when-kill-co.patch -patch/0072-containerd-fix-deadlock-on-commit-error.patch -patch/0073-containerd-backport-upstream-patches.patch -patch/0074-containerd-fix-exec-event-missing-due-to-pid-reuse.patch -patch/0075-containerd-fix-dm-left-when-pause-contaienr-and-kill-shim.patch -patch/0076-containerd-fix-start-container-failed-with-id-exists.patch -patch/0077-containerd-drop-opt-package.patch -patch/0078-containerd-bump-containerd-ttrpc-699c4e40d1.patch -patch/0079-containerd-fix-race-access-for-mobySubcribed.patch -patch/0080-containerd-improve-log-for-debugging.patch -patch/0081-containerd-reduce-permissions-for-bundle-di.patch -patch/0082-containerd-fix-publish-command-wait-block-for.patch -patch/0083-containerd-optimize-cgo-compile-options.patch -patch/0084-containerd-Use-fs.RootPath-when-mounting-vo.patch -patch/0085-containerd-put-get-pid-lock-after-set-process-exited-to-.patch -patch/0086-containerd-Limit-the-response-size-of-ExecSync.patch -patch/0087-containerd-treat-manifest-provided-URLs-differently.patch -patch/0088-containerd-Use-chmod-path-for-checking-symlink.patch -patch/0089-containerd-Add-lock-for-ListPids.patch -patch/0090-images-validate-document-type-before-unmarshal.patch -patch/0091-schema1-reject-ambiguous-documents.patch -patch/0092-containerd-add-CGO-sercurity-build-options.patch -patch/0093-containerd-fix-version-number-wrong.patch -patch/0094-containerd-Fix-goroutine-leak-in-Exec.patch -# end +patch/0001-containerd-add-check-in-spec.patch -- Gitee