X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=jjb%2Ffunctest%2Ffunctest.yaml;h=eb7d7b19d77599e550e006376d31a399b50de4b8;hb=30ce9c78e52dbc3e73bc483f37d791b5de9f0566;hp=30a90c5f5f674f6b768a7b5777eb6939571f4eb6;hpb=f1d3ee2cb725ea01be4a43cde7ab573de2e3d97c;p=releng.git diff --git a/jjb/functest/functest.yaml b/jjb/functest/functest.yaml index 30a90c5f5..eb7d7b19d 100644 --- a/jjb/functest/functest.yaml +++ b/jjb/functest/functest.yaml @@ -15,8 +15,15 @@ from: buildargs: branch: master - slave: lf-virtual9 - DASHBOARD_URL: http://172.30.13.94 + slave: lf-pod4-2 + DASHBOARD_URL: http://172.30.12.85 + dependency: 3.14 + - wallaby: + from: + buildargs: + branch: stable/wallaby + slave: lf-virtual6 + DASHBOARD_URL: http://172.30.13.91 dependency: 3.13 - leguer: from: @@ -39,20 +46,6 @@ slave: lf-pod4 DASHBOARD_URL: http://172.30.12.83 dependency: 3.10 - - iruya: - from: - buildargs: - branch: stable/iruya - slave: lf-virtual4 - DASHBOARD_URL: http://172.30.13.89 - dependency: 3.9 - - hunter: - from: - buildargs: - branch: stable/hunter - slave: lf-virtual6 - DASHBOARD_URL: http://172.30.13.91 - dependency: 3.9 - functest-jobs: &functest-jobs name: 'functest-jobs' @@ -77,12 +70,14 @@ - string: name: EXTERNAL_NETWORK default: public + - parameter: name: functest-VOLUME_DEVICE_NAME parameters: - string: name: VOLUME_DEVICE_NAME default: sdb + - parameter: name: functest-IMAGE_PROPERTIES parameters: @@ -95,6 +90,8 @@ <<: *functest-containers test: '{test}' privileged: '{privileged}' + volumes: '{volumes}' + env: '{env}' network: '{network}' DASHBOARD_URL: '{DASHBOARD_URL}' @@ -117,6 +114,14 @@ builders: - shell: | set +x + volumes=; + if [ "{volumes}" != "None" ]; then + for i in $(echo {volumes} | tr -d '[] ' |sed "s/,/ /g" ); do volumes="-v $i $volumes"; done + fi + env=; + if [ "{env}" != "None" ]; then + for i in $(eval echo {env} | tr -d '[] ' |sed "s/,/ /g" ); do env="-e $i $env"; done + fi [ ! -z "$WORKSPACE" ] && sudo rm -rf $WORKSPACE/results || true if [ "{repo}" = "_" ]; then image={container}:{tag} @@ -128,6 +133,8 @@ sudo docker run --rm \ --privileged={privileged} \ --network={network} \ + $volumes \ + $env \ -e S3_ENDPOINT_URL=https://storage.googleapis.com \ -e S3_DST_URL=s3://artifacts.opnfv.org/functest/$BUILD_TAG/$JOB_NAME-$BUILD_ID \ -e HTTP_DST_URL=http://artifacts.opnfv.org/functest/$BUILD_TAG/$JOB_NAME-$BUILD_ID \ @@ -137,12 +144,7 @@ -e NODE_NAME=$slave \ -e BUILD_TAG=$BUILD_TAG \ -v $WORKSPACE/../$JOB_NAME/results:/var/lib/xtesting/results \ - -e EXTERNAL_NETWORK=$EXTERNAL_NETWORK \ - -e VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME \ - -e IMAGE_PROPERTIES=$IMAGE_PROPERTIES \ -e DASHBOARD_URL={DASHBOARD_URL} \ - -v /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file \ - -v /home/opnfv/functest/images:/home/opnfv/functest/images \ $image run_tests -t {test} -p -r - builder: @@ -262,7 +264,7 @@ - 'functest-{repo}-{container}-{tag}-rmi' - job-template: - name: 'functest-{repo}-{container}-{tag}-{test}-run' + name: 'functest-opnfv-functest-healthcheck-{tag}-{test}-run' parameters: - functest-slave: slave: '{slave}' @@ -281,6 +283,13 @@ - project: name: 'functest-opnfv-functest-healthcheck' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-healthcheck' test: - connection_check @@ -299,11 +308,35 @@ privileged: 'false' network: bridge jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' + - 'functest-opnfv-functest-healthcheck-{tag}-{test}-run' + +- job-template: + name: 'functest-opnfv-functest-smoke-{tag}-{test}-run' + parameters: + - functest-slave: + slave: '{slave}' + - functest-build_tag: + build_tag: '' + - functest-EXTERNAL_NETWORK: + EXTERNAL_NETWORK: public + - functest-VOLUME_DEVICE_NAME: + VOLUME_DEVICE_NAME: sdb + - functest-IMAGE_PROPERTIES: + IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + builders: + - functest-run-containers: + <<: *functest-run-containers - project: name: 'functest-opnfv-functest-smoke' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-smoke' test: - tempest_neutron @@ -331,47 +364,86 @@ privileged: 'false' network: bridge exclude: - - {'tag': 'latest', 'test': 'refstack_defcore'} - - {'tag': 'latest', 'test': 'networking-bgpvpn'} - - {'tag': 'latest', 'test': 'networking-sfc'} - - {'tag': 'latest', 'test': 'patrole'} - - {'tag': 'leguer', 'test': 'refstack_defcore'} - - {'tag': 'leguer', 'test': 'networking-bgpvpn'} - - {'tag': 'leguer', 'test': 'networking-sfc'} - - {'tag': 'leguer', 'test': 'patrole'} - - {'tag': 'kali', 'test': 'refstack_defcore'} - - {'tag': 'kali', 'test': 'networking-bgpvpn'} - - {'tag': 'kali', 'test': 'networking-sfc'} - - {'tag': 'kali', 'test': 'patrole_admin'} - - {'tag': 'kali', 'test': 'patrole_member'} - - {'tag': 'kali', 'test': 'patrole_reader'} - - {'tag': 'jerma', 'test': 'refstack_defcore'} - - {'tag': 'jerma', 'test': 'networking-bgpvpn'} - - {'tag': 'jerma', 'test': 'networking-sfc'} - - {'tag': 'jerma', 'test': 'patrole_admin'} - - {'tag': 'jerma', 'test': 'patrole_member'} - - {'tag': 'jerma', 'test': 'patrole_reader'} - - {'tag': 'jerma', 'test': 'tempest_cyborg'} - - {'tag': 'iruya', 'test': 'refstack_defcore'} - - {'tag': 'iruya', 'test': 'patrole_admin'} - - {'tag': 'iruya', 'test': 'patrole_member'} - - {'tag': 'iruya', 'test': 'patrole_reader'} - - {'tag': 'iruya', 'test': 'tempest_cyborg'} - - {'tag': 'hunter', 'test': 'refstack_compute'} - - {'tag': 'hunter', 'test': 'refstack_object'} - - {'tag': 'hunter', 'test': 'refstack_platform'} - - {'tag': 'hunter', 'test': 'tempest_octavia'} - - {'tag': 'hunter', 'test': 'tempest_telemetry'} - - {'tag': 'hunter', 'test': 'patrole_admin'} - - {'tag': 'hunter', 'test': 'patrole_member'} - - {'tag': 'hunter', 'test': 'patrole_reader'} - - {'tag': 'hunter', 'test': 'tempest_cyborg'} + - tag: latest + test: refstack_defcore + - tag: latest + test: networking-bgpvpn + - tag: latest + test: networking-sfc + - tag: latest + test: patrole + - tag: wallaby + test: refstack_defcore + - tag: wallaby + test: networking-bgpvpn + - tag: wallaby + test: networking-sfc + - tag: wallaby + test: patrole + - tag: leguer + test: refstack_defcore + - tag: leguer + test: networking-bgpvpn + - tag: leguer + test: networking-sfc + - tag: leguer + test: patrole + - tag: kali + test: refstack_defcore + - tag: kali + test: networking-bgpvpn + - tag: kali + test: networking-sfc + - tag: kali + test: patrole_admin + - tag: kali + test: patrole_member + - tag: kali + test: patrole_reader + - tag: jerma + test: refstack_defcore + - tag: jerma + test: networking-bgpvpn + - tag: jerma + test: networking-sfc + - tag: jerma + test: patrole_admin + - tag: jerma + test: patrole_member + - tag: jerma + test: patrole_reader + - tag: jerma + test: tempest_cyborg jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' + - 'functest-opnfv-functest-smoke-{tag}-{test}-run' + +- job-template: + name: 'functest-opnfv-functest-smoke-cntt-{tag}-{test}-run' + parameters: + - functest-slave: + slave: '{slave}' + - functest-build_tag: + build_tag: '' + - functest-EXTERNAL_NETWORK: + EXTERNAL_NETWORK: public + - functest-VOLUME_DEVICE_NAME: + VOLUME_DEVICE_NAME: sdb + - functest-IMAGE_PROPERTIES: + IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + builders: + - functest-run-containers: + <<: *functest-run-containers - project: name: 'functest-opnfv-functest-smoke-cntt' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-smoke-cntt' test: - tempest_neutron_cntt @@ -385,11 +457,35 @@ privileged: 'false' network: bridge jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' + - 'functest-opnfv-functest-smoke-cntt-{tag}-{test}-run' + +- job-template: + name: 'functest-opnfv-functest-benchmarking-{tag}-{test}-run' + parameters: + - functest-slave: + slave: '{slave}' + - functest-build_tag: + build_tag: '' + - functest-EXTERNAL_NETWORK: + EXTERNAL_NETWORK: public + - functest-VOLUME_DEVICE_NAME: + VOLUME_DEVICE_NAME: sdb + - functest-IMAGE_PROPERTIES: + IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + builders: + - functest-run-containers: + <<: *functest-run-containers - project: name: 'functest-opnfv-functest-benchmarking' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-benchmarking' test: - rally_full @@ -399,11 +495,35 @@ privileged: 'false' network: bridge jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' + - 'functest-opnfv-functest-benchmarking-{tag}-{test}-run' + +- job-template: + name: 'functest-opnfv-functest-benchmarking-cntt-{tag}-{test}-run' + parameters: + - functest-slave: + slave: '{slave}' + - functest-build_tag: + build_tag: '' + - functest-EXTERNAL_NETWORK: + EXTERNAL_NETWORK: public + - functest-VOLUME_DEVICE_NAME: + VOLUME_DEVICE_NAME: sdb + - functest-IMAGE_PROPERTIES: + IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + builders: + - functest-run-containers: + <<: *functest-run-containers - project: name: 'functest-opnfv-functest-benchmarking-cntt' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-benchmarking-cntt' test: - rally_full_cntt @@ -411,11 +531,35 @@ privileged: 'false' network: bridge jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' + - 'functest-opnfv-functest-benchmarking-cntt-{tag}-{test}-run' + +- job-template: + name: 'functest-opnfv-functest-vnf-{tag}-{test}-run' + parameters: + - functest-slave: + slave: '{slave}' + - functest-build_tag: + build_tag: '' + - functest-EXTERNAL_NETWORK: + EXTERNAL_NETWORK: public + - functest-VOLUME_DEVICE_NAME: + VOLUME_DEVICE_NAME: sdb + - functest-IMAGE_PROPERTIES: + IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + builders: + - functest-run-containers: + <<: *functest-run-containers - project: name: 'functest-opnfv-functest-vnf' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-vnf' test: - cloudify @@ -426,14 +570,21 @@ privileged: 'false' network: bridge jobs: - - 'functest-{repo}-{container}-{tag}-{test}-run' - + - 'functest-opnfv-functest-vnf-{tag}-{test}-run' - builder: name: functest-zip builders: - shell: | set +x + volumes=; + if [ "{volumes}" != "None" ]; then + for i in $(echo {volumes} | tr -d '[] ' |sed "s/,/ /g" ); do volumes="-v $i $volumes"; done + fi + env=; + if [ "{env}" != "None" ]; then + for i in $(eval echo {env} | tr -d '[] ' |sed "s/,/ /g" ); do env="-e $i $env"; done + fi [ ! -z "$WORKSPACE" ] && sudo rm -rf $WORKSPACE/results || true if [ "{repo}" = "_" ]; then image={container}:{tag} @@ -443,6 +594,8 @@ image={repo}:{port}/{container}:{tag} fi sudo docker run --rm \ + $volumes \ + $env \ -e S3_ENDPOINT_URL=https://storage.googleapis.com \ -e S3_DST_URL=s3://artifacts.opnfv.org/functest \ -e HTTP_DST_URL=http://artifacts.opnfv.org/functest \ @@ -451,11 +604,6 @@ -e TEST_DB_EXT_URL=http://testresults.opnfv.org/test/api/v1/results \ -e BUILD_TAG=$BUILD_TAG \ -v $WORKSPACE/../$JOB_NAME/results:/var/lib/xtesting/results \ - -e EXTERNAL_NETWORK=$EXTERNAL_NETWORK \ - -e VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME \ - -e IMAGE_PROPERTIES=$IMAGE_PROPERTIES \ - -v /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file \ - -v /home/opnfv/functest/images:/home/opnfv/functest/images \ $image zip_campaign - job-template: @@ -474,10 +622,19 @@ builders: - functest-zip: <<: *functest-containers + volumes: '{volumes}' + env: '{env}' - project: name: 'functest-{tag}-zip' <<: *functest-params + volumes: + - /home/opnfv/functest/openstack.creds:/home/opnfv/functest/conf/env_file + - /home/opnfv/functest/images:/home/opnfv/functest/images + env: + - EXTERNAL_NETWORK=$EXTERNAL_NETWORK + - VOLUME_DEVICE_NAME=$VOLUME_DEVICE_NAME + - IMAGE_PROPERTIES=$IMAGE_PROPERTIES container: 'functest-healthcheck' jobs: - 'functest-{tag}-zip' @@ -498,12 +655,14 @@ VOLUME_DEVICE_NAME: sdb - functest-IMAGE_PROPERTIES: IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + # PyYAML and yamllint differ here + # see https://github.com/yaml/pyyaml/issues/234 + # yamllint disable rule:indentation properties: - build-blocker: - use-build-blocker: true - blocking-level: 'NODE' blocking-jobs: - - '^functest-{tag}-(daily|docker|review)$' + - ^functest-(pi-)*{tag}-(daily|docker|review)$ + # yamllint enable rule:indentation builders: - multijob: name: remove former images @@ -743,10 +902,10 @@ set +x if [ "_" = "_" ]; then image=alpine:{dependency} - elif [ "_" = "None" ]; then + elif [ "None" = "None" ]; then image=_/alpine:{dependency} else - image=_:/alpine{dependency} + image=_:/alpine:{dependency} fi sudo docker pull $image || true @@ -757,10 +916,10 @@ set +x if [ "_" = "_" ]; then image=alpine:{dependency} - elif [ "_" = "None" ]; then + elif [ "" = "None" ]; then image=_/alpine:{dependency} else - image=_:/alpine{dependency} + image=_:/alpine:{dependency} fi sudo docker rmi $image || true @@ -799,11 +958,13 @@ builders: - shell: | set +x - sudo apt-get update && sudo apt-get install \ - software-properties-common gpg -y + sudo apt-get update && sudo DEBIAN_FRONTEND=noninteractive \ + apt-get install software-properties-common gpg -y sudo add-apt-repository -y ppa:deadsnakes/ppa - sudo apt-get update && sudo apt-get install python3.8 python3.8-dev \ - python3.8-distutils \ + sudo apt-get update && sudo DEBIAN_FRONTEND=noninteractive \ + apt-get install \ + python3.9 python3.9-dev python3.9-distutils \ + python3.8 python3.8-dev python3.8-distutils \ python3.7 python3.7-dev python3.6 python3.6-dev \ python python-dev python3-pip enchant -y sudo pip3 install tox tox-pip-version @@ -861,6 +1022,7 @@ path: docker/tempest exclude: - {'tag': 'latest'} + - {'tag': 'wallaby'} - {'tag': 'leguer'} - {'tag': 'kali'} - {'tag': 'jerma'} @@ -921,7 +1083,6 @@ jobs: - 'functest-{repo}-{container}-{tag}-gate' - - trigger: name: functest-patchset-created triggers: @@ -956,12 +1117,14 @@ VOLUME_DEVICE_NAME: sdb - functest-IMAGE_PROPERTIES: IMAGE_PROPERTIES: hw_scsi_model:virtio-scsi,hw_disk_bus:scsi + # PyYAML and yamllint differ here + # see https://github.com/yaml/pyyaml/issues/234 + # yamllint disable rule:indentation properties: - build-blocker: - use-build-blocker: true - blocking-level: 'NODE' blocking-jobs: - - '^functest-{tag}-(daily|docker|review)$' + - ^functest-(pi-)*{tag}-(daily|docker|review)$ + # yamllint enable rule:indentation builders: - multijob: name: remove former images @@ -1227,6 +1390,7 @@ path: docker/tempest exclude: - {'tag': 'latest'} + - {'tag': 'wallaby'} - {'tag': 'leguer'} - {'tag': 'kali'} - {'tag': 'jerma'} @@ -1287,7 +1451,6 @@ jobs: - 'functest-{repo}-{container}-{tag}-build' - - job-template: name: 'functest-{tag}-docker' project-type: multijob @@ -1299,12 +1462,14 @@ parameters: - functest-slave: slave: '{slave}' + # PyYAML and yamllint differ here + # see https://github.com/yaml/pyyaml/issues/234 + # yamllint disable rule:indentation properties: - build-blocker: - use-build-blocker: true - blocking-level: 'NODE' blocking-jobs: - - '^functest-{tag}-(daily|docker|review)$' + - ^functest-(pi-)*{tag}-(daily|docker|review)$ + # yamllint enable rule:indentation builders: - multijob: name: remove dependency @@ -1349,7 +1514,8 @@ name: functest-trivy builders: - shell: | - sudo apt-get update && sudo apt-get install curl -y + sudo apt-get update && sudo DEBIAN_FRONTEND=noninteractive \ + apt-get install curl -y curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sudo sh -s -- -b . if [ "{repo}" = "_" ]; then