From e0ba82b4acd3e53f849c8355a338c7fb40ad3c30 Mon Sep 17 00:00:00 2001 From: jaspreetsachdev Date: Sat, 29 May 2021 10:27:08 -0400 Subject: [PATCH 1/6] Moving controller to 1.1.1-rc3 --- .github/workflows/cloud-controller-build.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/cloud-controller-build.yaml b/.github/workflows/cloud-controller-build.yaml index 4d97b296b..682f742f0 100644 --- a/.github/workflows/cloud-controller-build.yaml +++ b/.github/workflows/cloud-controller-build.yaml @@ -19,23 +19,23 @@ env: testbeds: '[ { "number": "ext-01", - "version": "1.1.0-rc2" + "version": "1.1.0-rc3" }, { "number": "ext-02", - "version": "1.1.0-rc2" + "version": "1.1.0-rc3" }, { "number": "ext-03", - "version": "1.0.0" + "version": "1.1.0-rc3" }, { "number": "ext-04", - "version": "1.1.0-rc2" + "version": "1.1.0-rc3" }, { "number": "01", - "version": "1.1.0-rc2" + "version": "1.1.0-rc3" } ]' From 322119d656899022757bd8f8797fbeb8e215682a Mon Sep 17 00:00:00 2001 From: jaspreetsachdev Date: Tue, 1 Jun 2021 18:08:45 -0400 Subject: [PATCH 2/6] Moved to 1.1.0 GA --- .github/workflows/cloud-controller-build.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/cloud-controller-build.yaml b/.github/workflows/cloud-controller-build.yaml index 682f742f0..b0aac6da2 100644 --- a/.github/workflows/cloud-controller-build.yaml +++ b/.github/workflows/cloud-controller-build.yaml @@ -19,23 +19,23 @@ env: testbeds: '[ { "number": "ext-01", - "version": "1.1.0-rc3" + "version": "1.1.0" }, { "number": "ext-02", - "version": "1.1.0-rc3" + "version": "1.1.0" }, { "number": "ext-03", - "version": "1.1.0-rc3" + "version": "1.1.0" }, { "number": "ext-04", - "version": "1.1.0-rc3" + "version": "1.1.0" }, { "number": "01", - "version": "1.1.0-rc3" + "version": "1.1.0" } ]' From 41395bc43fb0cfea741085082915c0d323b8527e Mon Sep 17 00:00:00 2001 From: jaspreetsachdev Date: Wed, 2 Jun 2021 18:45:03 -0400 Subject: [PATCH 3/6] Create interop.yml --- .github/workflows/interop.yml | 157 ++++++++++++++++++++++++++++++++++ 1 file changed, 157 insertions(+) create mode 100644 .github/workflows/interop.yml diff --git a/.github/workflows/interop.yml b/.github/workflows/interop.yml new file mode 100644 index 000000000..fcdc7a44b --- /dev/null +++ b/.github/workflows/interop.yml @@ -0,0 +1,157 @@ +name: interop testing + +env: + # thirdparties + DOCKER_SERVER: tip-tip-wlan-cloud-docker-repo.jfrog.io + DOCKER_USER_NAME: wlan-testing-cicd + DOCKER_USER_PASSWORD: ${{ secrets.DOCKER_USER_PASSWORD }} + # AWS credentials + AWS_EKS_NAME: tip-wlan-main + AWS_DEFAULT_OUTPUT: json + AWS_DEFAULT_REGION: us-east-2 + AWS_ACCOUNT_ID: ${{ secrets.AWS_ACCOUNT_ID }} + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_CLIENT_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_CLIENT_KEY }} + # Cloud SDK certs + CACERT: ${{ secrets.CACERT }} + CAKEY: ${{ secrets.CAKEY }} + ALLURE_CLI_VERSION: 2.14.0 + +on: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + build: + runs-on: ubuntu-latest + steps: + # checkout needed repositories + - name: Checkout Testing repo + uses: actions/checkout@v2 + with: + path: wlan-testing + + - name: Checkout LANforge scripts + uses: actions/checkout@v2 + with: + path: wlan-lanforge-scripts + repository: Telecominfraproject/wlan-lanforge-scripts + + - name: import LANforge scripts + working-directory: wlan-testing + run: ./sync_repos.bash + + # build and push docker image + - name: docker login + run: docker login ${{ env.DOCKER_SERVER }} -u ${{ env.DOCKER_USER_NAME }} -p ${{ env.DOCKER_USER_PASSWORD }} + - name: build docker image + working-directory: wlan-testing + run: docker build -t ${{ env.DOCKER_SERVER }}/cloud-sdk-nightly:pytest-${{ github.run_number }} -f docker/Dockerfile . + - name: push docker image + run: docker push ${{ env.DOCKER_SERVER }}/cloud-sdk-nightly:pytest-${{ github.run_number }} + + + test: + runs-on: ubuntu-latest + needs: [ build ] + steps: + - name: get EKS access credentials + run: aws eks update-kubeconfig --name ${{ env.AWS_EKS_NAME }} + + - name: install Allure CLI tool + run: | + wget https://repo.maven.apache.org/maven2/io/qameta/allure/allure-commandline/${{ env.ALLURE_CLI_VERSION }}/allure-commandline-${{ env.ALLURE_CLI_VERSION }}.tgz + tar -xzf allure-commandline-${{ env.ALLURE_CLI_VERSION }}.tgz + - name: set job name + id: job + run: echo "::set-output name=name::nightly-ci-${{ github.run_number }}" + + - name: create configuration.py secret + run: | + cat << EOF > configuration.py + ${{ secrets.LAB_CONFIGURATION }} + EOF + kubectl create secret generic configuration --from-file=configuration=./configuration.py + - name: run sanity tests + run: | + cat </dev/null 2>&1 + done + echo "tests completed" + echo "downloading allure results..." + kubectl cp $podname:/tmp/allure-results allure-results >/dev/null 2>&1 + echo "waiting for pod to exit" + kubectl logs -f $podname >/dev/null 2>&1 + exit $(kubectl get pod $podname --output="jsonpath={.status.containerStatuses[].state.terminated.exitCode}") + - name: print logs + if: ${{ always() }} + run: | + podname=$(kubectl get pods --no-headers -o custom-columns=":metadata.name" -l job-name="${{ steps.job.outputs.name }}" | sed "s/pod\///") + kubectl logs $podname + - name: upload Allure results as artifact + if: ${{ always() }} + uses: actions/upload-artifact@v2 + with: + name: allure-results + path: allure-results + + - name: generate Allure report + if: ${{ always() }} + run: allure-${{ env.ALLURE_CLI_VERSION }}/bin/allure generate + + - name: upload Allure report as artifact + if: ${{ always() }} + uses: actions/upload-artifact@v2 + with: + name: allure-report + path: allure-report + + - name: cleanup + if: ${{ always() }} + run: | + kubectl delete job "${{ steps.job.outputs.name }}" --wait=true --ignore-not-found=true + kubectl delete secret configuration --wait=true --ignore-not-found=true From bc6eab511e0852d523254dde8f48b0f4bdbc676c Mon Sep 17 00:00:00 2001 From: jaspreetsachdev Date: Wed, 2 Jun 2021 19:00:12 -0400 Subject: [PATCH 4/6] Update interop.yml --- .github/workflows/interop.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/interop.yml b/.github/workflows/interop.yml index fcdc7a44b..bcfb22a80 100644 --- a/.github/workflows/interop.yml +++ b/.github/workflows/interop.yml @@ -67,7 +67,7 @@ jobs: tar -xzf allure-commandline-${{ env.ALLURE_CLI_VERSION }}.tgz - name: set job name id: job - run: echo "::set-output name=name::nightly-ci-${{ github.run_number }}" + run: echo "::set-output name=name::interop-ci-${{ github.run_number }}" - name: create configuration.py secret run: | From 4d6bf8b384c51273215222fff2ffaa1dc43b0fc8 Mon Sep 17 00:00:00 2001 From: jaspreetsachdev Date: Wed, 2 Jun 2021 19:32:02 -0400 Subject: [PATCH 5/6] Update interop.yml --- .github/workflows/interop.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/interop.yml b/.github/workflows/interop.yml index bcfb22a80..c61831724 100644 --- a/.github/workflows/interop.yml +++ b/.github/workflows/interop.yml @@ -65,17 +65,19 @@ jobs: run: | wget https://repo.maven.apache.org/maven2/io/qameta/allure/allure-commandline/${{ env.ALLURE_CLI_VERSION }}/allure-commandline-${{ env.ALLURE_CLI_VERSION }}.tgz tar -xzf allure-commandline-${{ env.ALLURE_CLI_VERSION }}.tgz + - name: set job name id: job run: echo "::set-output name=name::interop-ci-${{ github.run_number }}" - - name: create configuration.py secret - run: | - cat << EOF > configuration.py - ${{ secrets.LAB_CONFIGURATION }} - EOF - kubectl create secret generic configuration --from-file=configuration=./configuration.py - - name: run sanity tests +# - name: create configuration.py secret +# run: | +# cat << EOF > configuration.py +# ${{ secrets.LAB_CONFIGURATION }} +# EOF +# kubectl create secret generic configuration --from-file=configuration=./configuration.py + + - name: run interop tests run: | cat < Date: Thu, 3 Jun 2021 12:56:20 -0400 Subject: [PATCH 6/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 47076c543..ae70077ab 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,7 @@ http://pythontesting.net/framework/pytest/pytest-introduction/ ### Build status -[![Build Status](https://github.com/Telecominfraproject/wlan-testing/workflows/nightly%20build/badge.svg)] +[![nightly build](https://github.com/Telecominfraproject/wlan-testing/actions/workflows/nightly.yml/badge.svg)](https://github.com/Telecominfraproject/wlan-testing/actions/workflows/nightly.yml) ### Best Practice