diff --git a/debian_pkg_dirs b/debian_pkg_dirs new file mode 100644 index 00000000..af8926f2 --- /dev/null +++ b/debian_pkg_dirs @@ -0,0 +1,3 @@ +mtce-guest +nfv +nova-api-proxy diff --git a/mtce-guest/debian/deb_folder/changelog b/mtce-guest/debian/deb_folder/changelog new file mode 100644 index 00000000..e4c01db6 --- /dev/null +++ b/mtce-guest/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +mtce-guest (1.0-1) unstable; urgency=medium + + * Initial release. + + -- Tracey Bogue Wed, 15 Sep 2021 15:13:12 +0000 diff --git a/mtce-guest/debian/deb_folder/control b/mtce-guest/debian/deb_folder/control new file mode 100644 index 00000000..cd393d8f --- /dev/null +++ b/mtce-guest/debian/deb_folder/control @@ -0,0 +1,29 @@ +Source: mtce-guest +Section: admin +Priority: optional +Maintainer: StarlingX Developers +Build-Depends: debhelper-compat (= 13), + fm-common-dev, + libevent-dev, + libjson-c-dev, + libssl-dev, + libsystemd-dev, + mtce-common-dev, + uuid-dev, + cppcheck +Standards-Version: 4.5.1 +Homepage: https://www.starlingx.io + +Package: mtce-guest-agent +Architecture: any +Depends: ${misc:Depends}, ${shlibs:Depends} +Description: StarlingX Maintenance Guest Agent + The StarlingX Maintenance Guest Agent Service assists with VM guest heartbeat + control and failure reporting at the controller level. + +Package: mtce-guest-server +Architecture: any +Depends: ${misc:Depends}, ${shlibs:Depends} +Description: StarlingX Maintenance Guest Server + The StarlingX Maintenance Guest Server assists with VM guest heartbeat control + and failure reporting at the controller level. diff --git a/mtce-guest/debian/deb_folder/copyright b/mtce-guest/debian/deb_folder/copyright new file mode 100644 index 00000000..7cac4723 --- /dev/null +++ b/mtce-guest/debian/deb_folder/copyright @@ -0,0 +1,42 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: mtce-guest +Source: https://opendev.org/starlingx/nfv/ + +Files: * +Copyright: (c) 2013-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'. + +# 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/mtce-guest/debian/deb_folder/mtce-guest-agent.install b/mtce-guest/debian/deb_folder/mtce-guest-agent.install new file mode 100644 index 00000000..7990a45f --- /dev/null +++ b/mtce-guest/debian/deb_folder/mtce-guest-agent.install @@ -0,0 +1,7 @@ +usr/bin/guestAgent +usr/lib/ocf/resource.d/platform/guestAgent +lib/systemd/system/guestAgent.service +etc/init.d/guestAgent +etc/logrotate.d/guestAgent.logrotate +etc/mtc/guestAgent.ini +etc/mtc/tmp diff --git a/mtce-guest/debian/deb_folder/mtce-guest-server.install b/mtce-guest/debian/deb_folder/mtce-guest-server.install new file mode 100644 index 00000000..60ae5195 --- /dev/null +++ b/mtce-guest/debian/deb_folder/mtce-guest-server.install @@ -0,0 +1,7 @@ +usr/bin/guestServer +lib/systemd/system/guestServer.service +etc/init.d/guestServer +etc/logrotate.d/guestServer.logrotate +etc/mtc/guestServer.ini +etc/pmon.d/guestServer.conf +etc/mtc/tmp diff --git a/mtce-guest/debian/deb_folder/rules b/mtce-guest/debian/deb_folder/rules new file mode 100644 index 00000000..d5ffe296 --- /dev/null +++ b/mtce-guest/debian/deb_folder/rules @@ -0,0 +1,37 @@ +#!/usr/bin/make -f +# export DH_VERBOSE = 1 + +export ROOT=debian/tmp + +export BINDIR=/usr/bin +export INITDIR=$(ROOT)/etc/init.d +export LOGDIR=$(ROOT)/etc/logrotate.d +export MTCDIR=$(ROOT)/etc/mtc +export PMONDIR=$(ROOT)/etc/pmon.d +export SYSCONFDIR=/etc +export UNITDIR=/lib/systemd/system + +%: + dh $@ + +override_dh_auto_install: + make DESTDIR=$(ROOT) \ + PREFIX=$(ROOT)/usr/local \ + SYSCONFIGDIR=$(ROOT)/$(SYSCONFDIR) \ + LOCALBINDIR=$(ROOT)/$(BINDIR) \ + UNITDIR=$(ROOT)/$(UNITDIR) install + install -d -m 755 $(INITDIR) + install -p -D -m 700 scripts/guestAgent $(INITDIR)/guestAgent + install -p -D -m 700 scripts/guestServer $(INITDIR)/guestServer + install -d -m 755 $(LOGDIR) + install -p -D -m 644 scripts/guestAgent.logrotate $(LOGDIR)/guestAgent.logrotate + install -p -D -m 644 scripts/guestServer.logrotate $(LOGDIR)/guestServer.logrotate + install -d -m 755 $(MTCDIR) + install -d -m 755 $(MTCDIR)/tmp + install -p -D -m 644 scripts/guest.ini $(MTCDIR)/guestAgent.ini + install -p -D -m 644 scripts/guest.ini $(MTCDIR)/guestServer.ini + install -d -m 755 $(PMONDIR) + install -p -D -m 644 scripts/guestServer.pmon $(PMONDIR)/guestServer.conf + +override_dh_fixperms: + dh_fixperms -XguestAgent -XguestServer diff --git a/mtce-guest/debian/deb_folder/source/format b/mtce-guest/debian/deb_folder/source/format new file mode 100644 index 00000000..c3d9f240 --- /dev/null +++ b/mtce-guest/debian/deb_folder/source/format @@ -0,0 +1,2 @@ +3.0 (quilt) + diff --git a/mtce-guest/debian/meta_data.yaml b/mtce-guest/debian/meta_data.yaml new file mode 100644 index 00000000..6b15331d --- /dev/null +++ b/mtce-guest/debian/meta_data.yaml @@ -0,0 +1,7 @@ +--- +debname: mtce-guest +debver: 1.0 +src_path: src +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/mtce-guest/src/guestHttpSvr.cpp b/mtce-guest/src/guestHttpSvr.cpp index d8c651d2..163abf54 100644 --- a/mtce-guest/src/guestHttpSvr.cpp +++ b/mtce-guest/src/guestHttpSvr.cpp @@ -674,7 +674,7 @@ int _get_url_info ( struct evhttp_request * req, } else { - ilog ("Failed to parse URL (%s)", url_ptr); // DLOG + ilog ("Failed to parse URL"); // DLOG return (FAIL_INVALID_UUID) ; } /** @@ -1081,8 +1081,9 @@ int guestHttpSvr_init ( int port ) } else if ( guest_request.fd > 0 ) { + char* ip_addr = inet_ntoa(guest_request.addr.sin_addr); ilog ("Listening for 'http command' messages on %s:%d\n", - inet_ntoa(guest_request.addr.sin_addr), guest_request.port ); + ip_addr, guest_request.port ); rc = PASS ; break ; } diff --git a/mtce-guest/src/scripts/guestAgent b/mtce-guest/src/scripts/guestAgent index a0a7b0ec..cca8e8e5 100644 --- a/mtce-guest/src/scripts/guestAgent +++ b/mtce-guest/src/scripts/guestAgent @@ -10,8 +10,8 @@ # ### BEGIN INIT INFO # Provides: guestAgent -# Required-Start: -# Required-Stop: +# Required-Start: $local_fs +# Required-Stop: $local_fs # Default-Start: 3 5 # Default-Stop: 0 1 2 6 # Short-Description: Maintenance Client Daemon @@ -107,7 +107,7 @@ case "$1" in $0 restart ;; - *) + force-reload | *) echo "usage: $0 { start | stop | status | restart | condrestart | status }" ;; esac diff --git a/mtce-guest/src/scripts/guestAgent.ocf b/mtce-guest/src/scripts/guestAgent.ocf index 34708a87..34cbb39f 100644 --- a/mtce-guest/src/scripts/guestAgent.ocf +++ b/mtce-guest/src/scripts/guestAgent.ocf @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # # Copyright (c) 2013-2017 Wind River Systems, Inc. # diff --git a/mtce-guest/src/scripts/guestServer b/mtce-guest/src/scripts/guestServer index ace6a41e..add6496a 100644 --- a/mtce-guest/src/scripts/guestServer +++ b/mtce-guest/src/scripts/guestServer @@ -10,8 +10,8 @@ # ### BEGIN INIT INFO # Provides: guestServer -# Required-Start: -# Required-Stop: +# Required-Start: $local_fs +# Required-Stop: $local_fs # Default-Start: 3 5 # Default-Stop: 0 1 2 6 # Short-Description: Maintenance Client Daemon @@ -107,7 +107,7 @@ case "$1" in $0 restart ;; - *) + force-reload | *) echo "usage: $0 { start | stop | status | restart | condrestart | status }" ;; esac diff --git a/nfv/debian/deb_folder/changelog b/nfv/debian/deb_folder/changelog new file mode 100644 index 00000000..7fc75f1e --- /dev/null +++ b/nfv/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +nfv (1.0-1) unstable; urgency=medium + + * Initial release. + + -- Tracey Bogue Tue, 05 Oct 2021 12:35:42 +0000 diff --git a/nfv/debian/deb_folder/control b/nfv/debian/deb_folder/control new file mode 100644 index 00000000..4b6de230 --- /dev/null +++ b/nfv/debian/deb_folder/control @@ -0,0 +1,48 @@ +Source: nfv +Section: libs +Priority: optional +Maintainer: StarlingX Developers +Build-Depends: debhelper-compat (= 13), + dh-python, + python3-all, + python3-requests, + python3-setuptools +Standards-Version: 4.5.1 +Homepage: https://www.starlingx.io + +Package: nfv-client +Architecture: any +Depends: ${python3:Depends}, ${misc:Depends} +Description: StarlingX Network Function Virtualization Client + A python client library for network function virtualization. + +Package: nfv-common +Architecture: any +Depends: ${python3:Depends}, ${misc:Depends} +Description: StarlingX Network Function Virtualization Common + Common network functon virtualization classes used by other NFV libraries. + +Package: nfv-plugins +Architecture: any +Depends: ${python3:Depends}, ${misc:Depends} +Description: StarlingX Network Function Virtualization Plugins + Network function virtualization plugins use for interfacing with components + such as infrastructure, fault and patching. + +Package: nfv-tools +Architecture: any +Depends: ${python3:Depends}, ${misc:Depends} +Description: StarlingX Network Function Virtualization Tools + Developer tools for network function virtualization. + +Package: nfv-vim +Architecture: any +Depends: ${python3:Depends}, ${misc:Depends} +Description: StarlingX Virtual Infrastructure Manager + Virtual infrastructure manager for network function virtualization. + +Package: nfv-wheels +Architecture: any +Depends: ${python3-depends}, ${misc:Depends}, python3-wheel +Description: Network Function Virtualization Wheels + Contains python wheels for the Network Function Virtualization project. diff --git a/nfv/debian/deb_folder/copyright b/nfv/debian/deb_folder/copyright new file mode 100644 index 00000000..4c03dbf7 --- /dev/null +++ b/nfv/debian/deb_folder/copyright @@ -0,0 +1,42 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: nfv +Source: https://opendev.org/starlingx/nfv/ + +Files: * +Copyright: (c) 2013-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'. + +# 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/nfv/debian/deb_folder/nfv-client.install b/nfv/debian/deb_folder/nfv-client.install new file mode 100644 index 00000000..50dc88c4 --- /dev/null +++ b/nfv/debian/deb_folder/nfv-client.install @@ -0,0 +1,4 @@ +usr/bin/sw-manager +usr/lib/python3/dist-packages/nfv_client/* +usr/lib/python3/dist-packages/nfv_client-1.0.0.egg-info/* +usr/share/bash-completion/completions/sw-manager diff --git a/nfv/debian/deb_folder/nfv-common.install b/nfv/debian/deb_folder/nfv-common.install new file mode 100644 index 00000000..be2b627e --- /dev/null +++ b/nfv/debian/deb_folder/nfv-common.install @@ -0,0 +1,2 @@ +usr/lib/python3/dist-packages/nfv_common/* +usr/lib/python3/dist-packages/windriver_nfv_common_plugins-1.0.0.egg-info/* diff --git a/nfv/debian/deb_folder/nfv-plugins.install b/nfv/debian/deb_folder/nfv-plugins.install new file mode 100644 index 00000000..0e4ec393 --- /dev/null +++ b/nfv/debian/deb_folder/nfv-plugins.install @@ -0,0 +1,6 @@ +etc/logrotate.d/nfvi-plugins.logrotate +etc/nfv/nfv_plugins/alarm_handlers/config.ini +etc/nfv/nfv_plugins/event_log_handlers/config.ini +etc/nfv/nfv_plugins/nfvi_plugins/config.ini +usr/lib/python3/dist-packages/nfv_plugins/* +usr/lib/python3/dist-packages/windriver_nfv_plugins-1.0.0.egg-info/* diff --git a/nfv/debian/deb_folder/nfv-tools.install b/nfv/debian/deb_folder/nfv-tools.install new file mode 100644 index 00000000..a2465b19 --- /dev/null +++ b/nfv/debian/deb_folder/nfv-tools.install @@ -0,0 +1,4 @@ +usr/bin/nfv-forensic +usr/bin/nfv-notify +usr/lib/python3/dist-packages/nfv_tools/* +usr/lib/python3/dist-packages/nfv_tools-1.0.0.egg-info/* diff --git a/nfv/debian/deb_folder/nfv-vim.install b/nfv/debian/deb_folder/nfv-vim.install new file mode 100644 index 00000000..b89f3537 --- /dev/null +++ b/nfv/debian/deb_folder/nfv-vim.install @@ -0,0 +1,8 @@ +etc/nfv/vim/config.ini +etc/nfv/vim/debug.ini +usr/bin/nfv-vim* +usr/lib/ocf/resource.d/nfv/vim +usr/lib/ocf/resource.d/nfv/vim-api +usr/lib/ocf/resource.d/nfv/vim-webserver +usr/lib/python3/dist-packages/nfv_vim/* +usr/lib/python3/dist-packages/nfv_vim-1.0.0.egg-info/* diff --git a/nfv/debian/deb_folder/nfv-wheels.install b/nfv/debian/deb_folder/nfv-wheels.install new file mode 100644 index 00000000..180e6017 --- /dev/null +++ b/nfv/debian/deb_folder/nfv-wheels.install @@ -0,0 +1 @@ +usr/share/python-wheels/* diff --git a/nfv/debian/deb_folder/rules b/nfv/debian/deb_folder/rules new file mode 100644 index 00000000..525e609d --- /dev/null +++ b/nfv/debian/deb_folder/rules @@ -0,0 +1,74 @@ +#!/usr/bin/make -f +export DH_VERBOSE = 1 + +export PYBUILD_NAME=nfv +export PYTHONROOT=/usr/lib/python3/dist-packages +export ROOT=$(CURDIR)/debian/tmp +export SYSCONFDIR=/etc + +export BASHCONFDIR=$(ROOT)/usr/share/bash-completion/completions +export LOGDIR=$(ROOT)/etc/logrotate.d +export PLUGINDIR=$(ROOT)/etc/nfv/nfv_plugins +export RESOURCEDIR=$(ROOT)/usr/lib/ocf/resource.d/nfv +export VIMCONFDIR=$(ROOT)/etc/nfv/vim + +%: + dh $@ --with=python3 --buildsystem=pybuild + +override_dh_auto_build: + cd nfv-client && python3 setup.py build + cd nfv-common && python3 setup.py build + cd nfv-plugins && python3 setup.py build + cd nfv-tools && python3 setup.py build + cd nfv-vim && python3 setup.py build + +override_dh_auto_clean: + cd nfv-client && python3 setup.py clean + cd nfv-common && python3 setup.py clean + cd nfv-plugins && python3 setup.py clean + cd nfv-tools && python3 setup.py clean + cd nfv-vim && python3 setup.py clean + +override_dh_auto_configure: + echo "CONFIGURE NOT REQUIRED" + +override_dh_auto_install: + # Package installs. + cd nfv-client && python3 setup.py install -f --root=$(ROOT) --install-layout=deb && \ + python3 setup.py bdist_wheel --universal -d $(ROOT)/usr/share/python-wheels + cd nfv-common && python3 setup.py install -f --root=$(ROOT) --install-layout=deb && \ + python3 setup.py bdist_wheel --universal -d $(ROOT)/usr/share/python-wheels + cd nfv-plugins && python3 setup.py install -f --root=$(ROOT) --install-layout=deb && \ + python3 setup.py bdist_wheel --universal -d $(ROOT)/usr/share/python-wheels + cd nfv-tools && python3 setup.py install -f --root=$(ROOT) --install-layout=deb && \ + python3 setup.py bdist_wheel --universal -d $(ROOT)/usr/share/python-wheels + cd nfv-vim && python3 setup.py install -f --root=$(ROOT) --install-layout=deb && \ + python3 setup.py bdist_wheel --universal -d $(ROOT)/usr/share/python-wheels + # nfv-client files + install -d -m 755 $(BASHCONFDIR) + install -p -D -m 644 nfv-client/scripts/sw-manager.completion $(BASHCONFDIR)/sw-manager + # nfv-plugin files + install -d -m 755 $(LOGDIR) + install -p -D -m 644 nfv-plugins/scripts/nfvi-plugins.logrotate $(LOGDIR)/nfvi-plugins.logrotate + install -d -m 755 $(PLUGINDIR)/alarm_handlers + install -p -D -m 644 nfv-plugins/nfv_plugins/alarm_handlers/config.ini $(PLUGINDIR)/alarm_handlers/config.ini + install -d -m 755 $(PLUGINDIR)/event_log_handlers + install -p -D -m 644 nfv-plugins/nfv_plugins/event_log_handlers/config.ini $(PLUGINDIR)/event_log_handlers/config.ini + install -d -m 755 $(PLUGINDIR)/nfvi_plugins + install -p -D -m 644 nfv-plugins/nfv_plugins/nfvi_plugins/config.ini $(PLUGINDIR)/nfvi_plugins/config.ini + # nfv-vim files + sed -i -e 's|@SYSCONFDIR@|$(SYSCONFDIR)|g' nfv-vim/scripts/vim + sed -i -e 's|@SYSCONFDIR@|$(SYSCONFDIR)|g' nfv-vim/scripts/vim-api + sed -i -e 's|@SYSCONFDIR@|$(SYSCONFDIR)|g' nfv-vim/scripts/vim-webserver + sed -i -e 's|@SYSCONFDIR@|$(SYSCONFDIR)|g' nfv-vim/nfv_vim/config.ini + sed -i -e 's|@PYTHONROOT@|$(PYTHONROOT)|g' nfv-vim/nfv_vim/config.ini + install -d -m 755 $(RESOURCEDIR) + install -p -D -m 644 nfv-vim/scripts/vim $(RESOURCEDIR)/vim + install -p -D -m 644 nfv-vim/scripts/vim-api $(RESOURCEDIR)/vim-api + install -p -D -m 644 nfv-vim/scripts/vim-webserver $(RESOURCEDIR)/vim-webserver + install -d -m 755 $(VIMCONFDIR) + install -p -D -m 644 nfv-vim/nfv_vim/config.ini $(VIMCONFDIR)/config.ini + install -p -D -m 644 nfv-vim/nfv_vim/debug.ini $(VIMCONFDIR)/debug.ini + +override_dh_auto_test: + echo "AUTO TEST NOT REQUIRED" diff --git a/nfv/debian/deb_folder/source/format b/nfv/debian/deb_folder/source/format new file mode 100644 index 00000000..c3d9f240 --- /dev/null +++ b/nfv/debian/deb_folder/source/format @@ -0,0 +1,2 @@ +3.0 (quilt) + diff --git a/nfv/debian/dl_hook b/nfv/debian/dl_hook new file mode 100755 index 00000000..fbb77cb2 --- /dev/null +++ b/nfv/debian/dl_hook @@ -0,0 +1,11 @@ +#!/bin/bash +set -x + +PKG_BUILD_NAME=$1 +PKG_BUILD_ROOT=$(realpath `pwd`/${PKG_BUILD_NAME}) +STX_BASE=$(realpath ${MY_REPO}/stx) +SRC=$(realpath ${STX_BASE}/nfv/nfv) + +mkdir ${PKG_BUILD_NAME} +pushd ${PKG_BUILD_NAME} +cp -pr ${SRC}/nfv-* ${PKG_BUILD_ROOT}/ diff --git a/nfv/debian/meta_data.yaml b/nfv/debian/meta_data.yaml new file mode 100644 index 00000000..ed863263 --- /dev/null +++ b/nfv/debian/meta_data.yaml @@ -0,0 +1,7 @@ +--- +debname: nfv +debver: 1.0 +dl_hook: dl_hook +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/nova-api-proxy/debian/deb_folder/changelog b/nova-api-proxy/debian/deb_folder/changelog new file mode 100644 index 00000000..751e0227 --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +nova-api-proxy (1.0-1) unstable; urgency=medium + + * Initial release. + + -- Tracey Bogue Tue, 05 Oct 2021 09:11:42 +0000 diff --git a/nova-api-proxy/debian/deb_folder/control b/nova-api-proxy/debian/deb_folder/control new file mode 100644 index 00000000..765c106a --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/control @@ -0,0 +1,34 @@ +Source: nova-api-proxy +Section: libs +Priority: optional +Maintainer: StarlingX Developers +Build-Depends: debhelper-compat (= 13), + dh-python, + python3-all, + python3-setuptools, + python3-wheel +Standards-Version: 4.5.1 +Homepage: https://www.starlingx.io + +Package: nova-api-proxy +Section: libs +Architecture: any +Depends: ${misc:Depends}, ${python3:Depends}, + python3-eventlet, + python3-routes, + python3-webob, + python3-paste +Description: Nova Compute API Proxy + API proxy for the Nova compute instance manager. + +Package: nova-api-proxy-wheels +Section: libs +Architecture: any +Depends: ${misc:Depends}, ${python3:Depends}, + python3-eventlet, + python3-routes, + python3-webob, + python3-paste, + python3-wheel +Description: Nova Compute API Proxy Wheels + Contains python wheels for the Nova compute instance manager API proxy. diff --git a/nova-api-proxy/debian/deb_folder/copyright b/nova-api-proxy/debian/deb_folder/copyright new file mode 100644 index 00000000..2f48f3df --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/copyright @@ -0,0 +1,42 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: nova-api-proxy +Source: https://opendev.org/starlingx/nfv/ + +Files: * +Copyright: (c) 2013-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'. + +# 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/nova-api-proxy/debian/deb_folder/nova-api-proxy-wheels.install b/nova-api-proxy/debian/deb_folder/nova-api-proxy-wheels.install new file mode 100644 index 00000000..180e6017 --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/nova-api-proxy-wheels.install @@ -0,0 +1 @@ +usr/share/python-wheels/* diff --git a/nova-api-proxy/debian/deb_folder/nova-api-proxy.install b/nova-api-proxy/debian/deb_folder/nova-api-proxy.install new file mode 100644 index 00000000..1ea9b970 --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/nova-api-proxy.install @@ -0,0 +1,4 @@ +etc/init.d/api-proxy +etc/proxy/api-proxy-paste.ini +etc/proxy/nova-api-proxy.conf +lib/systemd/system/api-proxy.service diff --git a/nova-api-proxy/debian/deb_folder/rules b/nova-api-proxy/debian/deb_folder/rules new file mode 100644 index 00000000..ced00783 --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/rules @@ -0,0 +1,25 @@ +#!/usr/bin/make -f +# export DH_VERBOSE = 1 + +export PYBUILD_NAME=nova-api-proxy +export ROOT=debian/tmp + +export INITDIR=$(ROOT)/etc/init.d +export PROXYDIR=$(ROOT)/etc/proxy +export UNITDIR=$(ROOT)/lib/systemd/system + +%: + dh $@ --with=python3 --buildsystem=pybuild + +override_dh_auto_install: + install -d -m 755 $(UNITDIR) + install -p -D -m 644 nova_api_proxy/scripts/api-proxy.service $(UNITDIR)/api-proxy.service + install -d -m 755 $(INITDIR) + install -p -D -m 755 nova_api_proxy/scripts/api-proxy $(INITDIR)/api-proxy + install -d -m 755 $(PROXYDIR) + install -p -D -m 600 nova_api_proxy/nova-api-proxy.conf $(PROXYDIR)/nova-api-proxy.conf + install -p -D -m 600 nova_api_proxy/api-proxy-paste.ini $(PROXYDIR)/api-proxy-paste.ini + python3 setup.py bdist_wheel \ + --universal \ + -d $(ROOT)/usr/share/python-wheels + diff --git a/nova-api-proxy/debian/deb_folder/source/format b/nova-api-proxy/debian/deb_folder/source/format new file mode 100644 index 00000000..c3d9f240 --- /dev/null +++ b/nova-api-proxy/debian/deb_folder/source/format @@ -0,0 +1,2 @@ +3.0 (quilt) + diff --git a/nova-api-proxy/debian/meta_data.yaml b/nova-api-proxy/debian/meta_data.yaml new file mode 100644 index 00000000..f87ea023 --- /dev/null +++ b/nova-api-proxy/debian/meta_data.yaml @@ -0,0 +1,7 @@ +--- +debname: nova-api-proxy +debver: 1.0 +src_path: nova-api-proxy +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true