From 7b4f653379f1e2faaa5bc0d68565fd3719d263c2 Mon Sep 17 00:00:00 2001 From: erabii Date: Thu, 31 Aug 2023 15:48:37 +0300 Subject: [PATCH] test (#1429) --- .../download-docker-images/action.yaml | 17 ------------ .../composites/echo-saved-images/action.yaml | 10 ------- .../composites/load-docker-images/action.yaml | 27 ------------------- .../composites/pre-test-actions/action.yaml | 10 +++---- .github/workflows/maven.yaml | 24 ----------------- 5 files changed, 4 insertions(+), 84 deletions(-) delete mode 100644 .github/workflows/composites/download-docker-images/action.yaml delete mode 100644 .github/workflows/composites/echo-saved-images/action.yaml delete mode 100644 .github/workflows/composites/load-docker-images/action.yaml diff --git a/.github/workflows/composites/download-docker-images/action.yaml b/.github/workflows/composites/download-docker-images/action.yaml deleted file mode 100644 index a66933d7..00000000 --- a/.github/workflows/composites/download-docker-images/action.yaml +++ /dev/null @@ -1,17 +0,0 @@ -# we are not going to use upload/download actions, since it is slower than cache usage -# as key to the cache we are going to use DOCKER_IMAGES_KEY, which is the same as GITHUB_RUN_ID - -name: download docker images -description: download docker images -runs: - using: "composite" - steps: - - - uses: Wandalen/wretry.action@master - with: - attempt_limit: 3 - action: buildjet/cache@v3 - with: | - path: /tmp/docker/images - key: docker-images-cache-${{ env.DOCKER_IMAGES_KEY }} - restore-keys: docker-images-cache-${{ env.DOCKER_IMAGES_KEY }} diff --git a/.github/workflows/composites/echo-saved-images/action.yaml b/.github/workflows/composites/echo-saved-images/action.yaml deleted file mode 100644 index 7b5ff3fb..00000000 --- a/.github/workflows/composites/echo-saved-images/action.yaml +++ /dev/null @@ -1,10 +0,0 @@ -name: echo saved images -description: echo saved images -runs: - using: "composite" - steps: - - name: echo saved images - shell: bash - run: | - VIEW=$(ls -l /tmp/docker/images) - echo "${VIEW}" diff --git a/.github/workflows/composites/load-docker-images/action.yaml b/.github/workflows/composites/load-docker-images/action.yaml deleted file mode 100644 index f31a4d24..00000000 --- a/.github/workflows/composites/load-docker-images/action.yaml +++ /dev/null @@ -1,27 +0,0 @@ -name: install docker images -description: load docker images from tar -runs: - using: "composite" - steps: - - name: load docker images - shell: bash - run: | - - # get the name of the images to load from children of spring-cloud-kubernetes-controllers - cd spring-cloud-kubernetes-controllers - while read controller_image; do - docker load -i /tmp/docker/images/${controller_image}.tar - done < <(mvn -Dexec.executable='echo' -Dexec.args='${project.artifactId}' exec:exec -q | grep -v 'spring-cloud-kubernetes-controllers') - cd .. - - # get the name of the images to load from children of spring-cloud-kubernetes-integration-tests - cd spring-cloud-kubernetes-integration-tests - while read integration_test_image; do - docker load -i /tmp/docker/images/${integration_test_image}.tar - done < <(mvn -Dexec.executable='echo' -Dexec.args='${project.artifactId}' exec:exec -q \ - | grep -v 'spring-cloud-kubernetes-integration-tests' \ - | grep -v 'spring-cloud-kubernetes-client-configmap-event-reload-multiple-apps' \ - | grep -v 'spring-cloud-kubernetes-client-configuration-watcher-configmap-test-app' \ - | grep -v 'spring-cloud-kubernetes-client-secrets-event-reload-multiple-apps' \ - | grep -v 'spring-cloud-kubernetes-client-configuration-watcher-secrets-test-app' ) - cd .. diff --git a/.github/workflows/composites/pre-test-actions/action.yaml b/.github/workflows/composites/pre-test-actions/action.yaml index f6fd058b..d2bb6b96 100644 --- a/.github/workflows/composites/pre-test-actions/action.yaml +++ b/.github/workflows/composites/pre-test-actions/action.yaml @@ -22,13 +22,11 @@ runs: - name: cache local maven repository uses: ./.github/workflows/composites/cache - - name: download docker images - uses: ./.github/workflows/composites/download-docker-images - if: env.BASE_BRANCH != '2.1.x' + - name: build controllers project + uses: ./.github/workflows/composites/build-controllers-project - - name: load docker images into local repo - uses: ./.github/workflows/composites/load-docker-images - if: env.BASE_BRANCH != '2.1.x' + - name: build integration tests project + uses: ./.github/workflows/composites/build-integration-tests-project - name: download tests uses: actions/download-artifact@v3 diff --git a/.github/workflows/maven.yaml b/.github/workflows/maven.yaml index 11dd61fe..84f4dc35 100644 --- a/.github/workflows/maven.yaml +++ b/.github/workflows/maven.yaml @@ -92,30 +92,6 @@ jobs: echo "number_of_matrix_instances=${{ env.NUMBER_OF_MATRIX_INSTANCES }}" >> $GITHUB_OUTPUT echo "matrix_array=${{ env.MATRIX_ARRAY }}" >> $GITHUB_OUTPUT - - name: build controllers project - uses: ./.github/workflows/composites/build-controllers-project - if: env.BASE_BRANCH != '2.1.x' - - - name: build integration tests project - uses: ./.github/workflows/composites/build-integration-tests-project - if: env.BASE_BRANCH != '2.1.x' - - - name: save controller docker images - uses: ./.github/workflows/composites/save-controller-images - if: env.BASE_BRANCH != '2.1.x' - - - name: save integration tests docker images - uses: ./.github/workflows/composites/save-integration-tests-images - if: env.BASE_BRANCH != '2.1.x' - - - name: echo saved images - uses: ./.github/workflows/composites/echo-saved-images - if: env.BASE_BRANCH != '2.1.x' - - - name: upload docker images - uses: ./.github/workflows/composites/upload-docker-images - if: env.BASE_BRANCH != '2.1.x' - test_when_cache_present: needs: [ build ] runs-on: ubuntu-latest