- project:
    templates:
      - openstack-python3-jobs-neutron
      - publish-openstack-docs-pti
      - release-notes-jobs-python3
      - check-requirements
    check:
      jobs:
        - openstack-tox-pep8:
            required-projects:
              - openstack/horizon
              - openstack/networking-bgpvpn
              - openstack/networking-sfc
        - openstack-tox-docs:
            required-projects:
              - openstack/horizon
              - openstack/networking-bgpvpn
              - openstack/networking-sfc
        - openstack-tox-py38:
            required-projects: &bagpipe_required_projects
              - openstack/neutron
              - openstack/horizon
              - openstack/networking-bgpvpn
              - openstack/networking-sfc
        - openstack-tox-py39:
            required-projects: *bagpipe_required_projects
        - openstack-tox-py310:
            required-projects: *bagpipe_required_projects
        - openstack-tox-cover:
            required-projects: *bagpipe_required_projects
        - neutron-tempest-plugin-bgpvpn-bagpipe:
            irrelevant-files:
              - ^(test-|)requirements.txt$
              - ^setup.cfg$
            voting: false
        - networking-bagpipe-dsvm-fullstack:
            voting: false
        - networking-bagpipe-tempest
    gate:
      jobs:
        - openstack-tox-pep8:
            required-projects:
              - openstack/horizon
              - openstack/networking-bgpvpn
              - openstack/networking-sfc
        - openstack-tox-docs:
            required-projects:
              - openstack/horizon
              - openstack/networking-bgpvpn
              - openstack/networking-sfc
        - openstack-tox-py38:
            required-projects: *bagpipe_required_projects
        - openstack-tox-py39:
            required-projects: *bagpipe_required_projects
        - openstack-tox-py310:
            required-projects: *bagpipe_required_projects
        # NOTE(elod.illes): this job is failing in this branch and
        # needs to be set as non-voting in check queue until it is not
        # fixed, thus no need to run it on gate for now.
        # - neutron-tempest-plugin-bgpvpn-bagpipe:
        #     irrelevant-files:
        #       - ^(test-|)requirements.txt$
        #       - ^setup.cfg$
        - networking-bagpipe-tempest
    periodic-weekly:
      jobs:
        - openstack-tox-py39:
            required-projects: *bagpipe_required_projects
        - openstack-tox-py39-with-oslo-master:
            required-projects: *bagpipe_required_projects
        - neutron-tempest-plugin-bgpvpn-bagpipe
        - networking-bagpipe-tempest

- job:
    name: networking-bagpipe-tempest
    parent: tempest-full-py3
    nodeset: openstack-single-node-focal
    timeout: 10800
    required-projects:
      - openstack/tempest
      - openstack/neutron
      - openstack/networking-bagpipe
    vars:
      devstack_services:
        # Disable OVN services
        ovn-controller: false
        ovn-northd: false
        ovs-vswitchd: false
        ovsdb-server: false
        q-ovn-metadata-agent: false
        # Enable Neutron services that are not used by OVN
        br-ex-tcpdump: true
        br-int-flows: true
        q-agt: true
        q-dhcp: true
        q-l3: true
        q-meta: true
        q-metering: true
      devstack_localrc:
        Q_AGENT: openvswitch
        Q_ML2_PLUGIN_MECHANISM_DRIVERS: openvswitch
        Q_ML2_TENANT_NETWORK_TYPE: vxlan
      devstack_local_conf:
        post-config:
          /$NEUTRON_CORE_PLUGIN_CONF:
            ml2:
              tenant_network_types: vxlan,vlan
      tempest_concurrency: 4
      # TODO(lajoskatona): On Ubuntu Focal some volume attach tests are
      # failing. When https://bugs.launchpad.net/nova/+bug/1882521 is solved
      # this list can be removed.
      tempest_exclude_regex: "\
          (^tempest.api.compute.servers.test_server_rescue.ServerStableDeviceRescueTest)|\
          (^tempest.api.compute.servers.test_server_rescue.ServerRescueNegativeTestJSON)|\
          (^tempest.api.compute.volumes.test_attach_volume.AttachVolumeMultiAttachTest)|\
          (^tempest.api.compute.servers.test_server_rescue.ServerStableDeviceRescueTest.test_stable_device_rescue_disk_virtio_with_volume_attached)|\
          (^tempest.api.compute.servers.test_server_rescue_negative.ServerRescueNegativeTestJSON.test_rescued_vm_detach_volume)|\
          (^tempest.api.compute.volumes.test_attach_volume.AttachVolumeMultiAttachTest.test_resize_server_with_multiattached_volume)"
    irrelevant-files:
      - ^(test-|)requirements.txt$
      - ^setup.cfg$

- job:
    name: networking-bagpipe-dsvm-fullstack
    parent: neutron-fullstack
    timeout: 7800
    required-projects:
      - openstack/neutron
      - openstack/networking-bgpvpn
      - openstack/networking-sfc
    vars:
      tox_envlist: dsvm-fullstack
      project_name: networking-bagpipe
