KubeOS:fix usage does not print when an error occurs in the upgrade image creation
Fix the bug that the usage does not print when the upgrade image has parameter errors Signed-off-by: liyuanr <liyuanrong1@huawei.com>
This commit is contained in:
parent
64e9a50d08
commit
89b1b50d38
@ -0,0 +1,29 @@
|
|||||||
|
From 20f66b28ea95e262f54cad1a9b65d564f91b8d12 Mon Sep 17 00:00:00 2001
|
||||||
|
From: liyuanr <liyuanrong1@huawei.com>
|
||||||
|
Date: Thu, 8 Dec 2022 15:08:52 +0800
|
||||||
|
Subject: [PATCH] KubeOS:fix usage does not print when an error occurs in the
|
||||||
|
upgrade image creation
|
||||||
|
|
||||||
|
Fix the bug that the usage does not print
|
||||||
|
when the upgrade image has parameter errors
|
||||||
|
|
||||||
|
Signed-off-by: liyuanr <liyuanrong1@huawei.com>
|
||||||
|
---
|
||||||
|
scripts/kbimg.sh | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/scripts/kbimg.sh b/scripts/kbimg.sh
|
||||||
|
index a623e3d..a860c06 100644
|
||||||
|
--- a/scripts/kbimg.sh
|
||||||
|
+++ b/scripts/kbimg.sh
|
||||||
|
@@ -125,6 +125,7 @@ function verify_upgrade_image_input() {
|
||||||
|
echo "$@" | grep -q "\-$i "
|
||||||
|
if [ "$?" -ne 0 ];then
|
||||||
|
log_error_print "option -$i is mandatory, please check input"
|
||||||
|
+ show_upgrade_image_usage
|
||||||
|
exit 3
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
--
|
||||||
|
2.33.0.windows.2
|
||||||
|
|
||||||
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Name: KubeOS
|
Name: KubeOS
|
||||||
Version: 1.0.2
|
Version: 1.0.2
|
||||||
Release: 7
|
Release: 8
|
||||||
Summary: O&M platform used to update the whole OS as an entirety
|
Summary: O&M platform used to update the whole OS as an entirety
|
||||||
License: Mulan PSL v2
|
License: Mulan PSL v2
|
||||||
Source0: https://gitee.com/openeuler/KubeOS/repository/archive/v%{version}.tar.gz
|
Source0: https://gitee.com/openeuler/KubeOS/repository/archive/v%{version}.tar.gz
|
||||||
@ -12,6 +12,7 @@ Patch3: 0003-KubeOS-fixed-the-issue-of-VMs-images-and-add-check-o.patch
|
|||||||
Patch4: 0004-KubeOS-add-the-clearing-of-space-before-the-upgrade-.patch
|
Patch4: 0004-KubeOS-add-the-clearing-of-space-before-the-upgrade-.patch
|
||||||
Patch5: 0005-KubeOS-add-the-configuration-of-etc-resolv.conf-and-.patch
|
Patch5: 0005-KubeOS-add-the-configuration-of-etc-resolv.conf-and-.patch
|
||||||
Patch6: 0006-KubeOS-remove-grub2-legacy-install-add-error-handlin.patch
|
Patch6: 0006-KubeOS-remove-grub2-legacy-install-add-error-handlin.patch
|
||||||
|
Patch7: 0007-KubeOS-fix-usage-does-not-print-when-an-error-occurs.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
BuildRequires: make
|
BuildRequires: make
|
||||||
BuildRequires: golang >= 1.13
|
BuildRequires: golang >= 1.13
|
||||||
@ -112,6 +113,12 @@ install -p -m 0600 ./files/os-release %{buildroot}/opt/kubeOS/files
|
|||||||
rm -rfv %{buildroot}
|
rm -rfv %{buildroot}
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Dec 08 2022 liyuanrong<liyuanrong1@huawei.com> - 1.0.2-8
|
||||||
|
- Type:requirement
|
||||||
|
- CVE:NA
|
||||||
|
- SUG:restart
|
||||||
|
- DESC:fix usage does not print when an error occurs in the upgrade image creation
|
||||||
|
|
||||||
* Tue Nov 29 2022 liyuanrong<liyuanrong1@huawei.com> - 1.0.2-7
|
* Tue Nov 29 2022 liyuanrong<liyuanrong1@huawei.com> - 1.0.2-7
|
||||||
- Type:requirement
|
- Type:requirement
|
||||||
- CVE:NA
|
- CVE:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user