From c06abcda5761d9fa4af23671b93b5fa59136d47a Mon Sep 17 00:00:00 2001 From: Charles Short Date: Wed, 18 Aug 2021 13:39:48 -0400 Subject: [PATCH] Update debian packaging for cgts-client - Update the dependencies for python3. - Made sure that the package is buildable and installable. - Added missing files. Story: 2009101 Task: 43047 Signed-off-by: Charles Short Change-Id: Ia76b0da93cce737ed00b0b1545717ba127f00c44 --- sysinv/cgts-client/debian/control | 29 ---------- .../debian/deb_folder/cgts-client.dirs | 1 + .../debian/deb_folder/cgts-client.install | 2 + .../cgts-client/debian/deb_folder/changelog | 5 ++ sysinv/cgts-client/debian/deb_folder/control | 55 +++++++++++++++++++ .../cgts-client/debian/deb_folder/copyright | 42 ++++++++++++++ sysinv/cgts-client/debian/deb_folder/rules | 18 ++++++ .../debian/deb_folder/source/format | 1 + .../debian/deb_folder/source/options | 1 + sysinv/cgts-client/debian/meta_data.yaml | 7 +++ sysinv/cgts-client/debian/rules | 8 --- 11 files changed, 132 insertions(+), 37 deletions(-) delete mode 100644 sysinv/cgts-client/debian/control create mode 100644 sysinv/cgts-client/debian/deb_folder/cgts-client.dirs create mode 100644 sysinv/cgts-client/debian/deb_folder/cgts-client.install create mode 100644 sysinv/cgts-client/debian/deb_folder/changelog create mode 100644 sysinv/cgts-client/debian/deb_folder/control create mode 100644 sysinv/cgts-client/debian/deb_folder/copyright create mode 100755 sysinv/cgts-client/debian/deb_folder/rules create mode 100644 sysinv/cgts-client/debian/deb_folder/source/format create mode 100644 sysinv/cgts-client/debian/deb_folder/source/options create mode 100644 sysinv/cgts-client/debian/meta_data.yaml delete mode 100644 sysinv/cgts-client/debian/rules diff --git a/sysinv/cgts-client/debian/control b/sysinv/cgts-client/debian/control deleted file mode 100644 index 297bb392d0..0000000000 --- a/sysinv/cgts-client/debian/control +++ /dev/null @@ -1,29 +0,0 @@ -Source: cgts-client -Priority: optional -Maintainer: StarlingX team -Build-Depends: python-setuptools, - python-all, - debhelper, - dh-python, - python-pbr, - python-keystoneclient, - python-fixtures, - python-dateutil, - python-httplib2, - python-dateutil, - python-six, - python-mock -Standards-Version: 3.9.6 - -Package: cgts-client -Architecture: all -Depends: ${misc:Depends}, - ${python:Depends}, - python-yaml, - python-httplib2, - python-prettytable, - bash-completion, - python-keystoneclient, - python-dateutil, - python-six -Description: This package contains the cgts-client project. diff --git a/sysinv/cgts-client/debian/deb_folder/cgts-client.dirs b/sysinv/cgts-client/debian/deb_folder/cgts-client.dirs new file mode 100644 index 0000000000..a403779ac1 --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/cgts-client.dirs @@ -0,0 +1 @@ +/etc/bash_completion.d/ diff --git a/sysinv/cgts-client/debian/deb_folder/cgts-client.install b/sysinv/cgts-client/debian/deb_folder/cgts-client.install new file mode 100644 index 0000000000..a3d9525310 --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/cgts-client.install @@ -0,0 +1,2 @@ +tools/system.bash_completion etc/bash_completion.d/ +usr diff --git a/sysinv/cgts-client/debian/deb_folder/changelog b/sysinv/cgts-client/debian/deb_folder/changelog new file mode 100644 index 0000000000..1ea4228ead --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +cgts-client (1.0-1) unstable; urgency=medium + + * Initial release. + + -- Chuck Short Wed, 18 Aug 2021 13:13:56 -0400 diff --git a/sysinv/cgts-client/debian/deb_folder/control b/sysinv/cgts-client/debian/deb_folder/control new file mode 100644 index 0000000000..d526301f3c --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/control @@ -0,0 +1,55 @@ +Source: cgts-client +Section: admin +Priority: optional +Maintainer: Starlingx Developers +Build-Depends: debhelper-compat (= 13), dh-python, python3-setuptools, python3-all, python3-pbr, python3-wheel +Build-Depends-Indep: + python3-keyring, + python3-oslo.i18n, + python3-oslo.serialization, + python3-oslo.utils, + python3-six, + python3-prettytable, + python3-requests-toolbelt, + python3-dateutil, + tsconfig, + python3-fixtures, + python3-mock, + python3-oslotest, + python3-stestr, + python3-testscenarios, + python3-testtools, + python3-testresources, + python3-httplib2, + python3-keystoneclient +Standards-Version: 4.4.1 +Homepage: https://www.starlingx.io + +Package: cgts-client +Architecture: all +Depends: ${python3:Depends}, ${misc:Depends}, + bash-completion, + python3-keystoneclient, + python3-httplib2, + python3-keyring, + python3-oslo.i18n, + python3-oslo.serialization, + python3-oslo.utils, + python3-six, + python3-prettytable, + python3-requests-toolbelt, + python3-dateutil, + tsconfig +Description: StarlingX - sysctem client and cli + system client and cli + . + This is the python3 version of the package + +Package: cgts-client-wheel +Architecture: all +Depends: ${python3:Depends}, ${misc:Depends}, python3-wheel +Description: StarlingX - system client and cli + Starlingx Config Info + . + This is the support package for the PEP 427 wheel version of the package, + required for using pip inside a virtual environment. diff --git a/sysinv/cgts-client/debian/deb_folder/copyright b/sysinv/cgts-client/debian/deb_folder/copyright new file mode 100644 index 0000000000..c5eac456bb --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/copyright @@ -0,0 +1,42 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: cgts-client +Source: https://opendev.org/starlingx/config + +Files: * +Copyright: (c) 2013-2021 Wind River Systems, Inc + (c) Others (See individual files for more details) +License: Apache-2 + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + . + https://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + . + On Debian-based systems the full text of the Apache version 2.0 license + can be found in `/usr/share/common-licenses/Apache-2.0'. + +# If you want to use GPL v2 or later for the /debian/* files use +# the following clauses, or change it to suit. Delete these two lines +Files: debian/* +Copyright: 2021 Wind River Systems, Inc +License: Apache-2 + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + . + https://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + . + On Debian-based systems the full text of the Apache version 2.0 license + can be found in `/usr/share/common-licenses/Apache-2.0'. diff --git a/sysinv/cgts-client/debian/deb_folder/rules b/sysinv/cgts-client/debian/deb_folder/rules new file mode 100755 index 0000000000..1ac009145c --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/rules @@ -0,0 +1,18 @@ +#!/usr/bin/make -f +#export DH_VERBOSE = 1 + +export PYBUILD_NAME=cgts-client +# (chuck) - workaround for pbr version detection when running install +export PBR_VERSION=1.0.0 + +%: + dh $@ --with python3 --buildsystem=pybuild + +override_dh_install: + python3 setup.py install -f --install-layout=deb \ + --root=$(CURDIR)/debian/tmp + python3 setup.py bdist_wheel \ + --universal\ + -d $(CURDIR)/debian/cgts-client-wheel/usr/share/python-wheels + dh_install + diff --git a/sysinv/cgts-client/debian/deb_folder/source/format b/sysinv/cgts-client/debian/deb_folder/source/format new file mode 100644 index 0000000000..163aaf8d82 --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/sysinv/cgts-client/debian/deb_folder/source/options b/sysinv/cgts-client/debian/deb_folder/source/options new file mode 100644 index 0000000000..cb61fa5267 --- /dev/null +++ b/sysinv/cgts-client/debian/deb_folder/source/options @@ -0,0 +1 @@ +extend-diff-ignore = "^[^/]*[.]egg-info/" diff --git a/sysinv/cgts-client/debian/meta_data.yaml b/sysinv/cgts-client/debian/meta_data.yaml new file mode 100644 index 0000000000..06cbecb927 --- /dev/null +++ b/sysinv/cgts-client/debian/meta_data.yaml @@ -0,0 +1,7 @@ +--- +debname: cgts-client +debver: 1.0-1 +src_path: cgts-client +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/sysinv/cgts-client/debian/rules b/sysinv/cgts-client/debian/rules deleted file mode 100644 index fb92e9db0a..0000000000 --- a/sysinv/cgts-client/debian/rules +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/make -f - -export PYBUILD_INSTALL_ARGS=--install-data=/usr/share --prefix=/usr -export PBR_VERSION=1.0 - -%: - dh $@ --with python2 --buildsystem=pybuild -