Update debian package source from Debian and Ubuntu. debian/ovn-common.logrotate comes from the RHEL packaging in this tree, and author is credited below.
The debian/automake.mk tricks to generate the copyright file while building came from the work on the debian packaging in openvswitch and author is credited below. Signed-off-by: James Page <[email protected]> Co-Authored-by: James Page <[email protected]> Signed-off-by: Christian Ehrhardt <[email protected]> Co-Authored-by: Christian Ehrhardt <[email protected]> Signed-off-by: Numan Siddique <[email protected]> Co-Authored-by: Numan Siddique <[email protected]> Signed-off-by: Ilya Maximets <[email protected]> Co-Authored-by: Ilya Maximets <[email protected]> Signed-off-by: Frode Nordahl <[email protected]> --- build-aux/initial-tab-whitelist | 3 +- debian/.gitignore | 17 ++ debian/automake.mk | 85 ++++++++- debian/control | 176 ++++++++++++++++++ debian/copyright.in | 146 +++++++++++++++ debian/flaky-tests-amd64.txt | 6 + debian/flaky-tests-arm64.txt | 5 + debian/flaky-tests-armel.txt | 7 + debian/flaky-tests-armhf.txt | 9 + debian/flaky-tests-i386.txt | 8 + debian/flaky-tests-mips64el.txt | 5 + debian/flaky-tests-mipsel.txt | 21 +++ debian/flaky-tests-ppc64el.txt | 6 + debian/flaky-tests-riscv64.txt | 6 + debian/flaky-tests-s390x.txt | 5 + debian/gbp.conf | 13 ++ debian/not-installed | 5 + debian/ovn-central.default | 5 + debian/ovn-central.install | 3 + debian/ovn-central.ovn-northd.service | 15 ++ .../ovn-central.ovn-ovsdb-server-nb.service | 18 ++ .../ovn-central.ovn-ovsdb-server-sb.service | 18 ++ debian/ovn-central.postrm | 47 +++++ debian/ovn-central.service | 16 ++ debian/ovn-common.docs | 1 + debian/ovn-common.install | 32 ++++ debian/ovn-common.logrotate | 22 +++ debian/ovn-common.postinst | 24 +++ debian/ovn-common.postrm | 23 +++ debian/ovn-controller-vtep.install | 1 + debian/ovn-controller-vtep.service | 16 ++ debian/ovn-doc.doc-base | 9 + debian/ovn-doc.install | 1 + debian/ovn-docker.install | 2 + debian/ovn-host.default | 5 + debian/ovn-host.install | 1 + debian/ovn-host.ovn-controller.service | 15 ++ debian/ovn-host.postrm | 43 +++++ debian/ovn-host.service | 14 ++ debian/ovn-ic-db.install | 2 + .../ovn-ic-db.ovn-ovsdb-server-ic-nb.service | 15 ++ .../ovn-ic-db.ovn-ovsdb-server-ic-sb.service | 15 ++ debian/ovn-ic-db.service | 15 ++ debian/ovn-ic.install | 1 + debian/ovn-ic.service | 16 ++ debian/rules | 104 +++++++++++ debian/source/format | 1 + debian/source/include-binaries | 1 + debian/testlist.py | 72 +++++++ debian/watch | 5 + 50 files changed, 1098 insertions(+), 3 deletions(-) create mode 100644 debian/.gitignore create mode 100644 debian/control create mode 100644 debian/copyright.in create mode 100644 debian/flaky-tests-amd64.txt create mode 100644 debian/flaky-tests-arm64.txt create mode 100644 debian/flaky-tests-armel.txt create mode 100644 debian/flaky-tests-armhf.txt create mode 100644 debian/flaky-tests-i386.txt create mode 100644 debian/flaky-tests-mips64el.txt create mode 100644 debian/flaky-tests-mipsel.txt create mode 100644 debian/flaky-tests-ppc64el.txt create mode 100644 debian/flaky-tests-riscv64.txt create mode 100644 debian/flaky-tests-s390x.txt create mode 100644 debian/gbp.conf create mode 100644 debian/not-installed create mode 100644 debian/ovn-central.default create mode 100644 debian/ovn-central.install create mode 100644 debian/ovn-central.ovn-northd.service create mode 100644 debian/ovn-central.ovn-ovsdb-server-nb.service create mode 100644 debian/ovn-central.ovn-ovsdb-server-sb.service create mode 100644 debian/ovn-central.postrm create mode 100644 debian/ovn-central.service create mode 100644 debian/ovn-common.docs create mode 100644 debian/ovn-common.install create mode 100644 debian/ovn-common.logrotate create mode 100644 debian/ovn-common.postinst create mode 100644 debian/ovn-common.postrm create mode 100644 debian/ovn-controller-vtep.install create mode 100644 debian/ovn-controller-vtep.service create mode 100644 debian/ovn-doc.doc-base create mode 100644 debian/ovn-doc.install create mode 100644 debian/ovn-docker.install create mode 100644 debian/ovn-host.default create mode 100644 debian/ovn-host.install create mode 100644 debian/ovn-host.ovn-controller.service create mode 100644 debian/ovn-host.postrm create mode 100644 debian/ovn-host.service create mode 100644 debian/ovn-ic-db.install create mode 100644 debian/ovn-ic-db.ovn-ovsdb-server-ic-nb.service create mode 100644 debian/ovn-ic-db.ovn-ovsdb-server-ic-sb.service create mode 100644 debian/ovn-ic-db.service create mode 100644 debian/ovn-ic.install create mode 100644 debian/ovn-ic.service create mode 100755 debian/rules create mode 100644 debian/source/format create mode 100644 debian/source/include-binaries create mode 100755 debian/testlist.py create mode 100644 debian/watch diff --git a/build-aux/initial-tab-whitelist b/build-aux/initial-tab-whitelist index b2f5a0791..71d4f007d 100644 --- a/build-aux/initial-tab-whitelist +++ b/build-aux/initial-tab-whitelist @@ -6,6 +6,5 @@ ^ovs/ ^third-party/ ^xenserver/ -^debian/rules.modules$ -^debian/rules$ +^debian/ ^\.gitmodules$ diff --git a/debian/.gitignore b/debian/.gitignore new file mode 100644 index 000000000..d2393b3fd --- /dev/null +++ b/debian/.gitignore @@ -0,0 +1,17 @@ +*.debhelper +*.debhelper.log +*.substvars +/autoreconf.after +/autoreconf.before +/copyright +/files +/ovn-common +/ovn-controller-vtep +/ovn-host +/ovn-central +/ovn-docker +/debhelper-build-stamp +/ovn-doc/ +/ovn-ic-db/ +/ovn-ic/ +/tmp diff --git a/debian/automake.mk b/debian/automake.mk index ce11fd040..d199c925d 100644 --- a/debian/automake.mk +++ b/debian/automake.mk @@ -1,2 +1,85 @@ EXTRA_DIST += \ - debian/changelog + debian/changelog \ + debian/control \ + debian/copyright.in \ + debian/flaky-tests-amd64.txt \ + debian/flaky-tests-arm64.txt \ + debian/flaky-tests-armel.txt \ + debian/flaky-tests-armhf.txt \ + debian/flaky-tests-i386.txt \ + debian/flaky-tests-mips64el.txt \ + debian/flaky-tests-mipsel.txt \ + debian/flaky-tests-ppc64el.txt \ + debian/flaky-tests-riscv64.txt \ + debian/flaky-tests-s390x.txt \ + debian/gbp.conf \ + debian/not-installed \ + debian/ovn-central.default \ + debian/ovn-central.install \ + debian/ovn-central.ovn-northd.service \ + debian/ovn-central.postrm \ + debian/ovn-central.service \ + debian/ovn-common.docs \ + debian/ovn-common.install \ + debian/ovn-common.logrotate \ + debian/ovn-common.postinst \ + debian/ovn-common.postrm \ + debian/ovn-controller-vtep.install \ + debian/ovn-controller-vtep.service \ + debian/ovn-doc.doc-base \ + debian/ovn-doc.install \ + debian/ovn-docker.install \ + debian/ovn-host.default \ + debian/ovn-host.install \ + debian/ovn-host.ovn-controller.service \ + debian/ovn-host.postrm \ + debian/ovn-host.service \ + debian/ovn-ic-db.install \ + debian/ovn-ic-db.service \ + debian/ovn-ic.install \ + debian/ovn-ic.service \ + debian/rules \ + debian/source/format \ + debian/source/include-binaries \ + debian/testlist.py \ + debian/watch + +check-debian-changelog-version: + @DEB_VERSION=`echo '$(VERSION)' | sed 's/pre/~pre/'`; \ + if $(FGREP) '($(DEB_VERSION)' $(srcdir)/debian/changelog >/dev/null; \ + then \ + :; \ + else \ + echo "Update debian/changelog to mention version $(VERSION)"; \ + exit 1; \ + fi +ALL_LOCAL += check-debian-changelog-version +DIST_HOOKS += check-debian-changelog-version + +update_deb_copyright = \ + $(AM_V_GEN) \ + { sed -n -e '/%AUTHORS%/q' -e p < $(srcdir)/debian/copyright.in; \ + tail -n +28 $(srcdir)/AUTHORS.rst | sed '1,/^$$/d' | \ + sed -n -e '/^$$/q' -e 's/^/ /p'; \ + sed -e '1,/%AUTHORS%/d' $(srcdir)/debian/copyright.in; \ + } > debian/copyright + +debian/copyright: AUTHORS.rst debian/copyright.in + $(update_deb_copyright) + +CLEANFILES += debian/copyright + +debian: debian/copyright +.PHONY: debian + +debian-deb: debian + @if test X"$(srcdir)" != X"$(top_builddir)"; then \ + echo "Debian packages should be built from $(abs_srcdir)/"; \ + exit 1; \ + fi + $(MAKE) distclean + $(update_deb_copyright) + $(update_deb_control) + $(AM_V_GEN) fakeroot debian/rules clean + $(AM_V_GEN) DEB_BUILD_OPTIONS="nocheck parallel=`nproc`" \ + fakeroot debian/rules binary diff --git a/debian/control b/debian/control new file mode 100644 index 000000000..a6f395842 --- /dev/null +++ b/debian/control @@ -0,0 +1,176 @@ +Source: ovn +Section: net +Priority: optional +Maintainer: OVN developers <[email protected]> +Build-Depends: + autoconf, + automake, + bzip2, + debhelper-compat (= 10), + dh-python, + graphviz, + libcap-ng-dev, + libnuma-dev [amd64 i386 ppc64el arm64], + libpcap-dev [amd64 i386 ppc64el arm64], + libssl-dev, + libtool, + libudev-dev, + libunbound-dev, + openssl, + openstack-pkg-tools, + openvswitch-source (>= 2.17.2-3~), + pkg-config, + procps, + python3-all-dev, + python3-setuptools, + python3-sortedcontainers, + python3-sphinx, + tcpdump, +Standards-Version: 4.6.1 +Homepage: https://www.ovn.org/ + +Package: ovn-central +Architecture: linux-any +Pre-Depends: ${misc:Pre-Depends}, +Depends: + lsb-base, + lsb-release, + openvswitch-common (>= 2.17.0~), + ovn-common (= ${binary:Version}), + ${misc:Depends}, + ${shlibs:Depends}, +Description: OVN central components + OVN, the Open Virtual Network, is a system to support virtual network + abstraction. OVN complements the existing capabilities of OVS to add native + support for virtual network abstractions, such as virtual L2 and L3 overlays + and security groups. + . + ovn-central provides the userspace daemons, utilities and + databases for OVN that is run at a central location. + +Package: ovn-common +Architecture: linux-any +Depends: + ${misc:Depends}, + ${python3:Depends}, + ${shlibs:Depends}, +Breaks: + ovn-ic-db (<< 22.03~), +Replaces: + ovn-ic-db (<< 22.03~), +Description: OVN common components + OVN, the Open Virtual Network, is a system to support virtual network + abstraction. OVN complements the existing capabilities of OVS to add native + support for virtual network abstractions, such as virtual L2 and L3 overlays + and security groups. + . + ovn-common provides components required by other OVN packages. + +Package: ovn-controller-vtep +Architecture: linux-any +Pre-Depends: ${misc:Pre-Depends}, +Depends: + lsb-base, + ovn-common (= ${binary:Version}), + ${misc:Depends}, + ${shlibs:Depends}, +Description: OVN vtep controller + ovn-controller-vtep is the local controller daemon in OVN, the Open Virtual + Network, for VTEP enabled physical switches. It connects up to the OVN + Southbound database over the OVSDB protocol, and down to the VTEP database + over the OVSDB protocol. + . + ovn-controller-vtep provides the ovn-controller-vtep binary for controlling + vtep gateways. + +Package: ovn-doc +Section: doc +Architecture: all +Depends: + ${misc:Depends}, + ${sphinxdoc:Depends}, +Description: OVN documentation + OVN, the Open Virtual Network, is a system to support virtual network + abstraction. OVN complements the existing capabilities of OVS to add + native support for virtual network abstractions, such as virtual L2 and L3 + overlays and security groups. + . + This package provides documentation for configuration and use + of OVN. + +Package: ovn-docker +Architecture: linux-any +Depends: + openvswitch-common (>= 2.17.0~), + ovn-common (= ${binary:Version}), + python3-openvswitch (>= 2.17.0~), + ${misc:Depends}, + ${python3:Depends}, + ${shlibs:Depends}, +Description: OVN Docker drivers + OVN, the Open Virtual Network, is a system to support virtual network + abstraction. OVN complements the existing capabilities of OVS to add + native support for virtual network abstractions, such as virtual L2 and L3 + overlays and security groups. + . + ovn-docker provides the docker drivers for OVN. + +Package: ovn-host +Architecture: linux-any +Pre-Depends: ${misc:Pre-Depends}, +Depends: + lsb-base, + lsb-release, + openvswitch-switch (>= 2.17.0~), + ovn-common (= ${binary:Version}), + ${misc:Depends}, + ${shlibs:Depends}, +Description: OVN host components + OVN, the Open Virtual Network, is a system to support virtual network + abstraction. OVN complements the existing capabilities of OVS to add + native support for virtual network abstractions, such as virtual L2 and L3 + overlays and security groups. + . + ovn-host provides the userspace components and utilities for + OVN that can be run on every host/hypervisor. + +Package: ovn-ic +Architecture: linux-any +Pre-Depends: ${misc:Pre-Depends}, +Depends: + lsb-base, + lsb-release, + ovn-common (= ${binary:Version}), + ${misc:Depends}, + ${shlibs:Depends}, +Enhances: + ovn-central, +Suggests: + ovn-ic-db, +Description: Open Virtual Network interconnection controller + OVN IC, the Open Virtual Network interconnection controller, is a + centralized daemon which communicates with global interconnection + databases to configure and exchange data with local OVN databases for + interconnection with other OVN deployments. + . + This package provides the ovn-ic daemon which should be run alongside + ovn-central services in each OVN deployment zone. + +Package: ovn-ic-db +Architecture: linux-any +Pre-Depends: ${misc:Pre-Depends}, +Depends: + lsb-base, + lsb-release, + openvswitch-common (>= 2.17.0~), + ovn-common (= ${binary:Version}), + ${misc:Depends}, + ${shlibs:Depends}, +Description: Open Virtual Network interconnection controller databases + OVN IC, the Open Virtual Network interconnection controller, is a + centralized daemon which communicates with global interconnection + databases to configure and exchange data with local OVN databases for + interconnection with other OVN deployments. + . + This package provides the global OVN IC southbound and northbound + OVSDB databases. diff --git a/debian/copyright.in b/debian/copyright.in new file mode 100644 index 000000000..911704ae0 --- /dev/null +++ b/debian/copyright.in @@ -0,0 +1,146 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: Open Virtual Network (OVN) +Source: https://github.com/ovn-org/ovn +Files-Excluded: debian +Upstream-Authors: +%AUTHORS% + +Files: * +Copyright: 2007-2017 Nicira, Inc. + 2010 Jean Tourrilhes - HP-Labs. + 2008,2009,2010 Citrix Systems, Inc. + 2011 Gaetano Catalli + 2000-2003 Geoffrey Wossum <[email protected]> + 2000 The NetBSD Foundation, Inc. + 1995, 1996, 1997, and 1998 WIDE Project. + 1982, 1986, 1990, 1993 The Regents of the University of California. + 2008, 2012 Vincent Bernat <[email protected]> + 2014 Michael Chapman + 2014 WindRiver, Inc. + 2014 Avaya, Inc. + 2001 Daniel Hartmeier + 2002 - 2008 Henning Brauer + 2012 Gleb Smirnoff <[email protected]> + 2015-2019 Red Hat, Inc. + 2017 DtDream Technology Co., Ltd. + 2018 eBay Inc. +License: Apache-2.0 +Comment: + This package contains code from other projects and authors not + mentioned elsewhere. + . + Open vSwitch + Copyright (c) 2007, 2008, 2009, 2010, 2011, 2013 Nicira, Inc. + . + Open vSwitch BSD port + Copyright (c) 2011 Gaetano Catalli + . + Apache Portable Runtime + Copyright 2008 The Apache Software Foundation. + . + This product includes software developed by + The Apache Software Foundation (http://www.apache.org/). + . + Portions of this software were developed at the National Center + for Supercomputing Applications (NCSA) at the University of + Illinois at Urbana-Champaign. + . + lib/ovs.tmac includes troff macros written by Eric S. Raymond + and Werner Lemberg. + . + m4/include_next.m4 and m4/absolute-header.m4 + Copyright (C) 2006-2013 Free Software Foundation, Inc. + . + Rapid Spanning Tree Protocol (RSTP) implementation + Copyright (c) 2011-2014 M3S, Srl - Italy + . + LLDP implementation + Copyright (c) 2008, 2012 Vincent Bernat <[email protected]> + . + LLDP includes code used from the Net::CDP project based on the ISC license + Copyright (c) 2014 Michael Chapman + . + LLDP includes code used from the ladvd project based on the ISC license + Copyright (c) 2008, 2009, 2010 Sten Spans <[email protected]> + . + Auto Attach implementation + Copyright (c) 2014, 2015 WindRiver, Inc + Copyright (c) 2014, 2015 Avaya, Inc + . + TCP connection tracker from FreeBSD pf, BSD licensed + Copyright (c) 2001 Daniel Hartmeier + Copyright (c) 2002 - 2008 Henning Brauer + Copyright (c) 2012 Gleb Smirnoff <[email protected]> + +Files: build-aux/cccl +Copyright: 2000-2003 Geoffrey Wossum <[email protected]> +License: GPL-2 + +Files: utilities/bugtool/ovn-bugtool-* + utilities/bugtool/plugins/network-status/ovn.xml +Copyright: 2016 Nicira, Inc. +License: LGPL-2.1 + +Files: m4/absolute-header.m4 + m4/include_next.m4 +Copyright: Derek Price + Paul Eggert + 2006-2013 Free Software Foundation, Inc. +License: file-is-free-software + This file is free software; the Free Software Foundation + gives unlimited permission to copy and/or distribute it, + with or without modifications, as long as this notice is preserved. + +Files: ovn-vif/* +Copyright: 2021 Canonical +License: Apache-2.0 + +License: GPL-2 + This program is free software; you can redistribute it and/or modify it under + the terms of the GNU General Public License as published by the Free Software + Foundation; either version 2 of the License, or (at your option) any later + version. + . + This program is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. + . + You should have received a copy of the GNU General Public License along with + this program; if not, write to the Free Software Foundation, Inc., 51 Franklin + St, Fifth Floor, Boston, MA 02110-1301 USA + . + On Debian systems, the complete text of the GNU General Public License v2 + (GPL) can be found in /usr/share/common-licenses/GPL-2. + +License: LGPL-2.1 + This library is free software; you can redistribute it and/or modify it under + the terms of the GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License. + . + This library is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + details. + . + You should have received a copy of the GNU Lesser General Public License along + with this library; if not, write to the Free Software Foundation, Inc., 51 + Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + . + On Debian systems, the complete text of the GNU Lesser General Public License + (LGPL) may be found in /usr/share/common-licenses/LGPL-2. + +License: Apache-2.0 + 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 + . + http://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/debian/flaky-tests-amd64.txt b/debian/flaky-tests-amd64.txt new file mode 100644 index 000000000..cfe5d8c66 --- /dev/null +++ b/debian/flaky-tests-amd64.txt @@ -0,0 +1,6 @@ +send gratuitous arp on localnet +policy-based routing IPv6: 1 HVs, 3 LSs, 1 lport/LS, 1 LR +ACLs on Port Groups +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +northd ssl file change diff --git a/debian/flaky-tests-arm64.txt b/debian/flaky-tests-arm64.txt new file mode 100644 index 000000000..996d0537e --- /dev/null +++ b/debian/flaky-tests-arm64.txt @@ -0,0 +1,5 @@ +ovn-controller incremental processing +nb_cfg timestamp +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ipsec -- basic configuration diff --git a/debian/flaky-tests-armel.txt b/debian/flaky-tests-armel.txt new file mode 100644 index 000000000..6ce03bb10 --- /dev/null +++ b/debian/flaky-tests-armel.txt @@ -0,0 +1,7 @@ +policy-based routing IPv6: 1 HVs, 3 LSs, 1 lport/LS, 1 LR +1 LR with distributed router gateway port +ACL conjunction +IP packet buffering +test transport zones +lflow cache for conjunctions +nb_cfg timestamp diff --git a/debian/flaky-tests-armhf.txt b/debian/flaky-tests-armhf.txt new file mode 100644 index 000000000..43654f3ae --- /dev/null +++ b/debian/flaky-tests-armhf.txt @@ -0,0 +1,9 @@ +policy-based routing IPv6: 1 HVs, 3 LSs, 1 lport/LS, 1 LR +ovn-controller incremental processing +ACL conjunction +neighbor update on same HV +nb_cfg timestamp +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ovn-ic -- gateway sync +ipsec -- basic configuration diff --git a/debian/flaky-tests-i386.txt b/debian/flaky-tests-i386.txt new file mode 100644 index 000000000..b82300de9 --- /dev/null +++ b/debian/flaky-tests-i386.txt @@ -0,0 +1,8 @@ +policy-based routing: 1 HVs, 2 LSs, 1 lport/LS, 1 LR +nb_cfg timestamp +ARP replies for SNAT external ips +conflict ACLs with address set +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ovn-ic -- gateway sync +ipsec -- basic configuration diff --git a/debian/flaky-tests-mips64el.txt b/debian/flaky-tests-mips64el.txt new file mode 100644 index 000000000..e67e2c4ca --- /dev/null +++ b/debian/flaky-tests-mips64el.txt @@ -0,0 +1,5 @@ +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ovn-ic -- gateway sync +ipsec -- basic configuration +nb_cfg timestamp diff --git a/debian/flaky-tests-mipsel.txt b/debian/flaky-tests-mipsel.txt new file mode 100644 index 000000000..00d383572 --- /dev/null +++ b/debian/flaky-tests-mipsel.txt @@ -0,0 +1,21 @@ +vtep: 3 HVs, 1 VIFs/HV, 1 GW, 1 LS +policy-based routing: 1 HVs, 2 LSs, 1 lport/LS, 1 LR +policy-based routing IPv6: 1 HVs, 3 LSs, 1 lport/LS, 1 LR +send gratuitous arp for nat ips in localnet +send gratuitous arp for NAT rules on distributed router +vlan traffic for external network with distributed router gateway port +send gratuitous ARP for NAT rules on HA distributed router +ACL conjunction +router - check packet length - icmp defrag +router - check packet length - icmp defrag +IP packet buffering +test transport zones +Load balancer health checks +interconnection +nb_cfg timestamp +conflict ACLs with address set +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +northd ssl file change +ovn-ic -- gateway sync +ipsec -- basic configuration diff --git a/debian/flaky-tests-ppc64el.txt b/debian/flaky-tests-ppc64el.txt new file mode 100644 index 000000000..6e089b6cb --- /dev/null +++ b/debian/flaky-tests-ppc64el.txt @@ -0,0 +1,6 @@ +options:requested-chassis for logical port +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +northd ssl file change +ovn-ic -- gateway sync +ipsec -- basic configuration diff --git a/debian/flaky-tests-riscv64.txt b/debian/flaky-tests-riscv64.txt new file mode 100644 index 000000000..50570ab80 --- /dev/null +++ b/debian/flaky-tests-riscv64.txt @@ -0,0 +1,6 @@ +send gratuitous arp on localnet +1 LR with distributed router gateway port +router - check packet length - icmp defrag +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ipsec -- basic configuration diff --git a/debian/flaky-tests-s390x.txt b/debian/flaky-tests-s390x.txt new file mode 100644 index 000000000..a642063d9 --- /dev/null +++ b/debian/flaky-tests-s390x.txt @@ -0,0 +1,5 @@ +options:requested-chassis for logical port +ACLs on Port Groups +multi-vtep SB Chassis encap updates +ACL with Port Group conjunction flow efficiency +ipsec -- basic configuration diff --git a/debian/gbp.conf b/debian/gbp.conf new file mode 100644 index 000000000..438b3fa8d --- /dev/null +++ b/debian/gbp.conf @@ -0,0 +1,13 @@ +[DEFAULT] +debian-branch = main +upstream-branch = upstream +pristine-tar = True +components = ['ovn-vif'] + +[import-orig] +upstream-vcs-tag = v%(version)s + +[dch] +multimaint-merge = True +customizations=/usr/share/doc/git-buildpackage/examples/wrap_cl.py +git-log=--first-parent diff --git a/debian/not-installed b/debian/not-installed new file mode 100644 index 000000000..e213b139d --- /dev/null +++ b/debian/not-installed @@ -0,0 +1,5 @@ +# The OVN library and headers are currently not considered ABI/API stable. +# If the need arises to build sibling projects we should probably provide an +# ovn-source package. +usr/include/* +usr/lib/* diff --git a/debian/ovn-central.default b/debian/ovn-central.default new file mode 100644 index 000000000..7cea13e50 --- /dev/null +++ b/debian/ovn-central.default @@ -0,0 +1,5 @@ +# This is a POSIX shell fragment -*- sh -*- + +# OVN_CTL_OPTS: Extra options to pass to ovs-ctl. This is, for example, +# a suitable place to specify --ovn-northd-wrapper=valgrind. +# OVN_CTL_OPTS= diff --git a/debian/ovn-central.install b/debian/ovn-central.install new file mode 100644 index 000000000..095ca7cfa --- /dev/null +++ b/debian/ovn-central.install @@ -0,0 +1,3 @@ +usr/bin/ovn-northd +usr/share/ovn/ovn-nb.ovsschema +usr/share/ovn/ovn-sb.ovsschema diff --git a/debian/ovn-central.ovn-northd.service b/debian/ovn-central.ovn-northd.service new file mode 100644 index 000000000..09c600016 --- /dev/null +++ b/debian/ovn-central.ovn-northd.service @@ -0,0 +1,15 @@ +[Unit] +Description=Open Virtual Network central control daemon +After=network.target ovn-nb-ovsdb.service ovn-sb-ovsdb.service +PartOf=ovn-central.service +DefaultDependencies=no + +[Service] +Type=forking +EnvironmentFile=-/etc/default/ovn-central +PIDFile=%t/ovn/ovn-northd.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl start_northd --ovn-manage-ovsdb=no --no-monitor $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_northd --no-monitor +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 diff --git a/debian/ovn-central.ovn-ovsdb-server-nb.service b/debian/ovn-central.ovn-ovsdb-server-nb.service new file mode 100644 index 000000000..81f6c75a3 --- /dev/null +++ b/debian/ovn-central.ovn-ovsdb-server-nb.service @@ -0,0 +1,18 @@ +[Unit] +Description=Open vSwitch database server for OVN Northbound database +After=network.target +PartOf=ovn-central.service +DefaultDependencies=no + +[Service] +Type=simple +EnvironmentFile=-/etc/default/ovn-central +PIDFile=%t/ovn/ovnnb_db.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl run_nb_ovsdb $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_nb_ovsdb +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 + +[Install] +Alias=ovn-nb-ovsdb.service diff --git a/debian/ovn-central.ovn-ovsdb-server-sb.service b/debian/ovn-central.ovn-ovsdb-server-sb.service new file mode 100644 index 000000000..3aa840d2f --- /dev/null +++ b/debian/ovn-central.ovn-ovsdb-server-sb.service @@ -0,0 +1,18 @@ +[Unit] +Description=Open vSwitch database server for OVN Southbound database +After=network.target +PartOf=ovn-central.service +DefaultDependencies=no + +[Service] +Type=simple +EnvironmentFile=-/etc/default/ovn-central +PIDFile=%t/run/ovn/ovnsb_db.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl run_sb_ovsdb $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_sb_ovsdb +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 + +[Install] +Alias=ovn-sb-ovsdb.service diff --git a/debian/ovn-central.postrm b/debian/ovn-central.postrm new file mode 100644 index 000000000..3b3483fc3 --- /dev/null +++ b/debian/ovn-central.postrm @@ -0,0 +1,47 @@ +#!/bin/sh +# postrm script for ovn-central +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <postrm> `remove' +# * <postrm> `purge' +# * <old-postrm> `upgrade' <new-version> +# * <new-postrm> `failed-upgrade' <old-version> +# * <new-postrm> `abort-install' +# * <new-postrm> `abort-install' <old-version> +# * <new-postrm> `abort-upgrade' <old-version> +# * <disappearer's-postrm> `disappear' <overwriter> +# <overwriter-version> +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + purge) + rm -f /etc/openvswitch/ovnnb.db* + rm -f /etc/openvswitch/.ovnnb.db.~lock~ + rm -f /etc/openvswitch/ovnsb.db* + rm -f /etc/openvswitch/.ovnsb.db.~lock~ + rm -f /var/log/openvswitch/ovn-northd.log* || true + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/ovn-central.service b/debian/ovn-central.service new file mode 100644 index 000000000..aead7eae6 --- /dev/null +++ b/debian/ovn-central.service @@ -0,0 +1,16 @@ +[Unit] +Description=Open Virtual Network central components +After=network.target +Requires=network.target +Wants=ovn-northd.service +Wants=ovn-ovsdb-server-sb.service +Wants=ovn-ovsdb-server-nb.service + +[Service] +Type=oneshot +ExecStart=/bin/true +ExecStop=/bin/true +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/debian/ovn-common.docs b/debian/ovn-common.docs new file mode 100644 index 000000000..6d5ee1d05 --- /dev/null +++ b/debian/ovn-common.docs @@ -0,0 +1 @@ +NOTICE diff --git a/debian/ovn-common.install b/debian/ovn-common.install new file mode 100644 index 000000000..52e9e0050 --- /dev/null +++ b/debian/ovn-common.install @@ -0,0 +1,32 @@ +usr/bin/ovn-appctl +usr/bin/ovn_detrace.py +usr/bin/ovn-detrace +usr/bin/ovn-nbctl +usr/bin/ovn-sbctl +/usr/bin/ovn-ic-nbctl +/usr/bin/ovn-ic-sbctl +usr/bin/ovn-trace +usr/share/ovn/bugtool-plugins/network-status/ovn.xml +usr/share/ovn/scripts/ovn-ctl +usr/share/ovn/scripts/ovn-lib +usr/share/ovn/scripts/ovndb-servers.ocf +usr/share/ovn/scripts/ovn-bugtool-nbctl-show +usr/share/ovn/scripts/ovn-bugtool-sbctl-lflow-list +usr/share/ovn/scripts/ovn-bugtool-sbctl-show +usr/share/man/man1/ovn-detrace.1 +usr/share/man/man5/ovn-ic-nb.5 +usr/share/man/man5/ovn-ic-sb.5 +usr/share/man/man5/ovn-nb.5 +usr/share/man/man5/ovn-sb.5 +usr/share/man/man7/ovn-architecture.7 +usr/share/man/man8/ovn-appctl.8 +usr/share/man/man8/ovn-controller-vtep.8 +usr/share/man/man8/ovn-controller.8 +usr/share/man/man8/ovn-ctl.8 +usr/share/man/man8/ovn-ic-nbctl.8 +usr/share/man/man8/ovn-ic-sbctl.8 +usr/share/man/man8/ovn-ic.8 +usr/share/man/man8/ovn-nbctl.8 +usr/share/man/man8/ovn-northd.8 +usr/share/man/man8/ovn-sbctl.8 +usr/share/man/man8/ovn-trace.8 diff --git a/debian/ovn-common.logrotate b/debian/ovn-common.logrotate new file mode 100644 index 000000000..a351ec303 --- /dev/null +++ b/debian/ovn-common.logrotate @@ -0,0 +1,22 @@ +# Copyright (C) 2019 Red Hat, Inc. +# +# Copying and distribution of this file, with or without modification, +# are permitted in any medium without royalty provided the copyright +# notice and this notice are preserved. This file is offered as-is, +# without warranty of any kind. + +/var/log/ovn/*.log { + su root root + daily + compress + sharedscripts + missingok + postrotate + # Tell OVN daemons to reopen their log files + if [ -d /var/run/ovn ]; then + for ctl in /var/run/ovn/*.ctl; do + ovs-appctl -t "$ctl" vlog/reopen 2>/dev/null || : + done + fi + endscript +} diff --git a/debian/ovn-common.postinst b/debian/ovn-common.postinst new file mode 100644 index 000000000..588044fbc --- /dev/null +++ b/debian/ovn-common.postinst @@ -0,0 +1,24 @@ +#!/bin/sh +# postinst script for ovn-common +# +# see: dh_installdeb(1) + +set -e + +case "$1" in + configure) + mkdir -p /usr/lib/ocf/resource.d/ovn + ln -sf /usr/share/openvswitch/scripts/ovndb-servers.ocf /usr/lib/ocf/resource.d/ovn/ovndb-servers + ;; + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 diff --git a/debian/ovn-common.postrm b/debian/ovn-common.postrm new file mode 100644 index 000000000..9face726b --- /dev/null +++ b/debian/ovn-common.postrm @@ -0,0 +1,23 @@ +#!/bin/sh +# postrm script for openvswitch-testcontroller +# +# see: dh_installdeb(1) + +set -e + +case "$1" in + purge|remove) + rm -rf /usr/lib/ocf/resource.d/ovn + ;; + upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 diff --git a/debian/ovn-controller-vtep.install b/debian/ovn-controller-vtep.install new file mode 100644 index 000000000..1d208f37e --- /dev/null +++ b/debian/ovn-controller-vtep.install @@ -0,0 +1 @@ +usr/bin/ovn-controller-vtep diff --git a/debian/ovn-controller-vtep.service b/debian/ovn-controller-vtep.service new file mode 100644 index 000000000..d51e75277 --- /dev/null +++ b/debian/ovn-controller-vtep.service @@ -0,0 +1,16 @@ +[Unit] +Description=Open Virtual Network VTEP gateway controller daemon +After=openvswitch-switch.service +Requires=openvswitch-switch.service + +[Service] +Type=forking +PIDFile=%t/ovn/ovn-controller-vtep.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl start_controller_vtep --no-monitor $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_controller_vtep --no-monitor +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 + +[Install] +WantedBy=multi-user.target diff --git a/debian/ovn-doc.doc-base b/debian/ovn-doc.doc-base new file mode 100644 index 000000000..c7192ebdb --- /dev/null +++ b/debian/ovn-doc.doc-base @@ -0,0 +1,9 @@ +Document: ovn-doc +Title: Open Virtual Network Documentation +Author: N/A +Abstract: Sphinx documentation for Open Virtual Network +Section: Network/Communication + +Format: HTML +Index: /usr/share/doc/ovn-doc/html/index.html +Files: /usr/share/doc/ovn-doc/html/* diff --git a/debian/ovn-doc.install b/debian/ovn-doc.install new file mode 100644 index 000000000..4cfd153cf --- /dev/null +++ b/debian/ovn-doc.install @@ -0,0 +1 @@ +Documentation/_build/html/* /usr/share/doc/ovn-doc/html/ diff --git a/debian/ovn-docker.install b/debian/ovn-docker.install new file mode 100644 index 000000000..583306732 --- /dev/null +++ b/debian/ovn-docker.install @@ -0,0 +1,2 @@ +usr/bin/ovn-docker-overlay-driver +usr/bin/ovn-docker-underlay-driver diff --git a/debian/ovn-host.default b/debian/ovn-host.default new file mode 100644 index 000000000..7fd54efda --- /dev/null +++ b/debian/ovn-host.default @@ -0,0 +1,5 @@ +# This is a POSIX shell fragment -*- sh -*- + +# OVN_CTL_OPTS: Extra options to pass to ovs-ctl. This is, for example, +# a suitable place to specify --ovn-controller-wrapper=valgrind. +# OVN_CTL_OPTS= diff --git a/debian/ovn-host.install b/debian/ovn-host.install new file mode 100644 index 000000000..d2de82fd9 --- /dev/null +++ b/debian/ovn-host.install @@ -0,0 +1 @@ +usr/bin/ovn-controller diff --git a/debian/ovn-host.ovn-controller.service b/debian/ovn-host.ovn-controller.service new file mode 100644 index 000000000..a41e77d75 --- /dev/null +++ b/debian/ovn-host.ovn-controller.service @@ -0,0 +1,15 @@ +[Unit] +Description=Open Virtual Network host control daemon +After=network.target openvswitch-switch.service +PartOf=ovn-host.service +DefaultDependencies=no + +[Service] +Type=forking +EnvironmentFile=-/etc/default/ovn-host +PIDFile=%t/ovn/ovn-controller.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl start_controller --ovn-manage-ovsdb=no --no-monitor $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_controller --no-monitor +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 diff --git a/debian/ovn-host.postrm b/debian/ovn-host.postrm new file mode 100644 index 000000000..9d17ef966 --- /dev/null +++ b/debian/ovn-host.postrm @@ -0,0 +1,43 @@ +#!/bin/sh +# postrm script for ovn-host +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <postrm> `remove' +# * <postrm> `purge' +# * <old-postrm> `upgrade' <new-version> +# * <new-postrm> `failed-upgrade' <old-version> +# * <new-postrm> `abort-install' +# * <new-postrm> `abort-install' <old-version> +# * <new-postrm> `abort-upgrade' <old-version> +# * <disappearer's-postrm> `disappear' <overwriter> +# <overwriter-version> +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + purge) + rm -f /var/log/openvswitch/ovn-controller.log* || true + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/ovn-host.service b/debian/ovn-host.service new file mode 100644 index 000000000..b524888fd --- /dev/null +++ b/debian/ovn-host.service @@ -0,0 +1,14 @@ +[Unit] +Description=Open Virtual Network host components +After=network.target +Requires=network.target +Wants=ovn-controller.service + +[Service] +Type=oneshot +ExecStart=/bin/true +ExecStop=/bin/true +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/debian/ovn-ic-db.install b/debian/ovn-ic-db.install new file mode 100644 index 000000000..a4d50002e --- /dev/null +++ b/debian/ovn-ic-db.install @@ -0,0 +1,2 @@ +/usr/share/ovn/ovn-ic-nb.ovsschema +/usr/share/ovn/ovn-ic-sb.ovsschema diff --git a/debian/ovn-ic-db.ovn-ovsdb-server-ic-nb.service b/debian/ovn-ic-db.ovn-ovsdb-server-ic-nb.service new file mode 100644 index 000000000..193024daf --- /dev/null +++ b/debian/ovn-ic-db.ovn-ovsdb-server-ic-nb.service @@ -0,0 +1,15 @@ +[Unit] +Description=Open vSwitch database server for OVN IC Northbound database +After=network.target +PartOf=ovn-ic-db.service +DefaultDependencies=no + +[Service] +Type=simple +EnvironmentFile=-/etc/default/ovn-ic +PIDFile=%t/ovn/ovn_ic_nb_db.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl run_ic_nb_ovsdb $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_ic_nb_ovsdb +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 diff --git a/debian/ovn-ic-db.ovn-ovsdb-server-ic-sb.service b/debian/ovn-ic-db.ovn-ovsdb-server-ic-sb.service new file mode 100644 index 000000000..714748325 --- /dev/null +++ b/debian/ovn-ic-db.ovn-ovsdb-server-ic-sb.service @@ -0,0 +1,15 @@ +[Unit] +Description=Open vSwitch database server for OVN IC Southbound database +After=network.target +PartOf=ovn-ic-db.service +DefaultDependencies=no + +[Service] +Type=simple +EnvironmentFile=-/etc/default/ovn-ic +PIDFile=%t/ovn/ovn_ic_sb_db.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl run_ic_sb_ovsdb $OVN_CTL_OPTS +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_ic_sb_ovsdb +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 diff --git a/debian/ovn-ic-db.service b/debian/ovn-ic-db.service new file mode 100644 index 000000000..b116bc79d --- /dev/null +++ b/debian/ovn-ic-db.service @@ -0,0 +1,15 @@ +[Unit] +Description=Open Virtual Network interconnection databases +After=network.target +Requires=network.target +Wants=ovn-ovsdb-server-ic-sb.service +Wants=ovn-ovsdb-server-ic-nb.service + +[Service] +Type=oneshot +ExecStart=/bin/true +ExecStop=/bin/true +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/debian/ovn-ic.install b/debian/ovn-ic.install new file mode 100644 index 000000000..b15508259 --- /dev/null +++ b/debian/ovn-ic.install @@ -0,0 +1 @@ +/usr/bin/ovn-ic diff --git a/debian/ovn-ic.service b/debian/ovn-ic.service new file mode 100644 index 000000000..07974285f --- /dev/null +++ b/debian/ovn-ic.service @@ -0,0 +1,16 @@ +[Unit] +Description=Open Virtual Network interconnection controller +After=network.target +Requires=network.target + +[Service] +Type=forking +PIDFile=%t/ovn/ovn-ic.pid +ExecStart=/usr/share/ovn/scripts/ovn-ctl start_ic --no-monitor +ExecStop=/usr/share/ovn/scripts/ovn-ctl stop_ic +Restart=on-failure +LimitNOFILE=65535 +TimeoutStopSec=15 + +[Install] +WantedBy=multi-user.target diff --git a/debian/rules b/debian/rules new file mode 100755 index 000000000..4596afb49 --- /dev/null +++ b/debian/rules @@ -0,0 +1,104 @@ +#!/usr/bin/make -f +# -*- makefile -*- +#export DH_VERBOSE=1 +export DEB_BUILD_MAINT_OPTIONS = hardening=+all + +%: + dh $@ --with autoreconf,python3,sphinxdoc + +ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) +PARALLEL = -j$(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) +else +PARALLEL = +endif + +override_dh_auto_configure: + # Configure OVS before OVN + test -d $(CURDIR)/ovs || mkdir ovs + cd ovs && tar -xzf /usr/src/openvswitch/openvswitch.tar.gz --strip-components=1 + cd ovs && ./configure --enable-ssl --localstatedir=/var --sysconfdir=/etc --prefix=/usr && make $(PARALLEL) + # Configure OVN to allow building OVN VIF + ./boot.sh && ./configure \ + --prefix=/usr \ + --localstatedir=/var \ + --sysconfdir=/etc \ + --with-dbdir=/var/lib/ovn \ + --with-ovs-source=$(CURDIR)/ovs \ + --enable-ssl + # Configure and build OVN VIF + cd ovn-vif && \ + ./boot.sh && \ + ./configure \ + --with-ovs-source=$(CURDIR)/ovs \ + --with-ovn-source=$(CURDIR) \ + --enable-plug-representor && \ + make $(PARALLEL) + # Use dh_auto_configure to build OVN + dh_auto_configure -- \ + --prefix=/usr \ + --localstatedir=/var \ + --sysconfdir=/etc \ + --with-dbdir=/var/lib/ovn \ + --with-ovs-source=$(CURDIR)/ovs \ + --enable-ssl \ + --with-vif-plug-provider=$(CURDIR)/ovn-vif + $(MAKE) debian/copyright + +TEST_LIST = $(shell \ + $(CURDIR)/debian/testlist.py \ + $(CURDIR)/debian/flaky-tests-$(DEB_HOST_ARCH).txt \ + $(CURDIR)/tests/testsuite) + +override_dh_auto_test: +ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) + if $(MAKE) check TESTSUITEFLAGS='$(PARALLEL) $(TEST_LIST)' || \ + $(MAKE) check TESTSUITEFLAGS='--recheck'; then :; \ + else \ + cat tests/testsuite.log; \ + exit 1; \ + fi +endif # nocheck + +override_dh_auto_build: + cd ovs && $(MAKE) $(PARALLEL) + $(MAKE) $(PARALLEL) + +override_dh_auto_clean: + dh_auto_clean + cd ovn-vif && make distclean | : + rm -rf ovs + +override_dh_installinit: + # Package does not ship any init.d files + dh_installinit --no-scripts + +override_dh_installsystemd: + dh_installsystemd --restart-after-upgrade -povn-central --name=ovn-northd + dh_installsystemd --restart-after-upgrade -povn-central --name=ovn-ovsdb-server-sb + dh_installsystemd --restart-after-upgrade -povn-central --name=ovn-ovsdb-server-nb + dh_installsystemd --restart-after-upgrade -povn-ic-db --name=ovn-ovsdb-server-ic-sb + dh_installsystemd --restart-after-upgrade -povn-ic-db --name=ovn-ovsdb-server-ic-nb + dh_installsystemd --restart-after-upgrade -povn-host --name=ovn-controller + dh_installsystemd --restart-after-upgrade + +override_dh_python3: + dh_python3 --shebang=/usr/bin/python3 + +# Helper target for creating snapshots from upstream git +DATE=$(shell date +%Y%m%d) +# Upstream branch to track +BRANCH=main +VERSION=22.09.0 + +get-orig-snapshot: + rm -Rf ovn-upstream ovn-vif-upstream + git clone --branch $(BRANCH) --depth 1 https://github.com/ovn-org/ovn ovn-upstream + git clone --branch $(BRANCH) --depth 1 https://github.com/ovn-org/ovn-vif ovn-vif-upstream + cd ovn-upstream && \ + export COMMIT=`git rev-parse --short HEAD` && \ + git archive --format tgz --prefix=ovn-$(VERSION)~git$(DATE).$$COMMIT/ \ + -o ../../ovn_$(VERSION)~git$(DATE).$$COMMIT.orig.tar.gz $(BRANCH) && \ + cd ../ovn-vif-upstream && \ + git archive --format tgz --prefix=ovn-vif-$(VERSION)~git$(DATE).$$COMMIT/ \ + -o ../../ovn_$(VERSION)~git$(DATE).$$COMMIT.orig-ovn-vif.tar.gz $(BRANCH) + rm -Rf ovn-upstream ovn-vif-upstream diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 000000000..163aaf8d8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/source/include-binaries b/debian/source/include-binaries new file mode 100644 index 000000000..2dfb2fe55 --- /dev/null +++ b/debian/source/include-binaries @@ -0,0 +1 @@ +ovn-vif/Documentation/_static/logo.png diff --git a/debian/testlist.py b/debian/testlist.py new file mode 100755 index 000000000..24d2ae9c5 --- /dev/null +++ b/debian/testlist.py @@ -0,0 +1,72 @@ +#!/usr/bin/env python3 +import enum +import itertools +import os +import sys + + +if len(sys.argv) < 3: + print( + "usage: {} skipdescriptionlist testsuite\n" + "\n" + "This program reads two files, a skiplist containing the \n" + "description of tests to skip separated by newline, and a \n" + "generated testsuite script.\n" + "\n" + "From this it produces string with range of tests to execute \n" + "which can be provided to the testsuite script.\n".format(sys.argv[0]), + file=sys.stderr, + ) + sys.exit(os.EX_USAGE) + + +SKIP_TEST_STRINGS = [] +with open(sys.argv[1]) as fin: + SKIP_TEST_STRINGS = [line.rstrip() for line in fin.readlines()] + + [email protected] +class State(enum.Enum): + INIT = enum.auto() + AT_HELP_ALL = enum.auto() + + +SKIP_TESTS = set() +TESTS = set() +with open(sys.argv[2]) as fin: + state = State.INIT + last_test = 0 + for line in fin.readlines(): + if state == State.INIT: + if not line.startswith('at_help_all="'): + continue + else: + state = State.AT_HELP_ALL + data = line.split('"')[1].rstrip().split(";") + elif state == State.AT_HELP_ALL: + if line.startswith('"'): + break + data = line.rstrip().split(";") + test_nr = int(data[0]) + if last_test < test_nr: + last_test = test_nr + for skip_string in SKIP_TEST_STRINGS: + if skip_string in data[2]: + SKIP_TESTS.add(test_nr) + else: + TESTS.add(test_nr) + + +def ranges(testlist): + for a, b in itertools.groupby( + enumerate(list(testlist)), lambda pair: pair[1] - pair[0] + ): + b = list(b) + yield b[0][1], b[-1][1] + + +testranges = [ + "{}-{}".format(testrange[0], testrange[1]) + for testrange in ranges(TESTS - SKIP_TESTS) +] +print(" ".join(testranges)) diff --git a/debian/watch b/debian/watch new file mode 100644 index 000000000..4831f3456 --- /dev/null +++ b/debian/watch @@ -0,0 +1,5 @@ +version=4 +opts=filenamemangle=s/.+\/v?(\d\S+)\.tar\.gz/ovn-$1\.tar\.gz/ \ + https://github.com/ovn-org/ovn/tags .*/v?(\d\S+)\.tar\.gz +opts="filenamemangle=s/.+\/v?(\d\S+)\.tar\.gz/ovn-vif-$1\.tar\.gz/, component=ovn-vif" \ + https://github.com/ovn-org/ovn-vif/tags .*/v?(\d\S+)\.tar\.gz -- 2.36.1 _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
