diff --git a/.github/workflows/system-tests.yml b/.github/workflows/system-tests.yml index f67b78cb0b6..3d4343f2975 100644 --- a/.github/workflows/system-tests.yml +++ b/.github/workflows/system-tests.yml @@ -128,6 +128,7 @@ jobs: - name: docker load if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' + id: docker_load run: | docker load < ${{ matrix.weblog-variant}}_${{ github.sha }}.tar.gz/${{ matrix.weblog-variant}}_weblog_${{ github.sha }}.tar.gz docker load < ${{ matrix.weblog-variant}}_${{ github.sha }}.tar.gz/${{ matrix.weblog-variant}}_agent_${{ github.sha }}.tar.gz @@ -139,98 +140,98 @@ jobs: chmod -R +x venv/bin/* - name: Run DEFAULT - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' run: ./run.sh DEFAULT - name: Run SAMPLING - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' run: ./run.sh SAMPLING - name: Run INTEGRATIONS - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' run: ./run.sh INTEGRATIONS - name: Run CROSSED_TRACING_LIBRARIES - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'other' run: ./run.sh CROSSED_TRACING_LIBRARIES - name: Run REMOTE_CONFIG_MOCKED_BACKEND_ASM_FEATURES - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' run: ./run.sh REMOTE_CONFIG_MOCKED_BACKEND_ASM_FEATURES - name: Run REMOTE_CONFIG_MOCKED_BACKEND_LIVE_DEBUGGING - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' run: ./run.sh REMOTE_CONFIG_MOCKED_BACKEND_LIVE_DEBUGGING - name: Run REMOTE_CONFIG_MOCKED_BACKEND_ASM_DD - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'remote-config' run: ./run.sh REMOTE_CONFIG_MOCKED_BACKEND_ASM_DD - name: Run APPSEC_MISSING_RULES - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_MISSING_RULES - name: Run APPSEC_CUSTOM_RULES - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_CUSTOM_RULES - name: Run APPSEC_CORRUPTED_RULES - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_CORRUPTED_RULES - name: Run APPSEC_RULES_MONITORING_WITH_ERRORS - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_RULES_MONITORING_WITH_ERRORS - name: Run APPSEC_LOW_WAF_TIMEOUT - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_LOW_WAF_TIMEOUT - name: Run APPSEC_CUSTOM_OBFUSCATION - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_CUSTOM_OBFUSCATION - name: Run APPSEC_RATE_LIMITER - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec' run: ./run.sh APPSEC_RATE_LIMITER - name: Run APPSEC_RUNTIME_ACTIVATION - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_RUNTIME_ACTIVATION - name: Run APPSEC_WAF_TELEMETRY - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_WAF_TELEMETRY - name: Run APPSEC_DISABLED - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_DISABLED - name: Run APPSEC_BLOCKING - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_BLOCKING - name: Run APPSEC_BLOCKING_FULL_DENYLIST - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_BLOCKING_FULL_DENYLIST - name: Run APPSEC_REQUEST_BLOCKING - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_REQUEST_BLOCKING - name: Run APPSEC_RASP - if: (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') && matrix.scenario == 'appsec-1' run: ./run.sh APPSEC_RASP # The compress step speed up a lot the upload artifact process - name: Compress artifact - if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' + if: always() && steps.docker_load.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') id: compress-artifact run: tar -czvf artifact.tar.gz $(ls | grep logs) - name: Upload artifact uses: actions/upload-artifact@v4 - if: steps.compress-artifact.outcome == 'success' || github.event_name == 'schedule' + if: always() && steps.docker_load.outcome == 'success' && (steps.compress-artifact.outcome == 'success' || github.event_name == 'schedule') with: name: logs_${{ matrix.weblog-variant }}_${{ matrix.scenario }} path: artifact.tar.gz @@ -259,22 +260,22 @@ jobs: with: python-version: '3.9' - - name: Build + - name: Build runner + id: build_runner if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' run: ./build.sh -i runner - name: Run - if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' + if: always() && steps.build_runner.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') run: ./run.sh PARAMETRIC - name: Compress artifact - if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' + if: always() && steps.build_runner.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') run: tar -czvf artifact.tar.gz $(ls | grep logs) - name: Upload artifact uses: actions/upload-artifact@v4 - if: needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule' + if: always() && steps.build_runner.outcome == 'success' && (needs.needs-run.outputs.outcome == 'success' || github.event_name == 'schedule') with: name: logs_parametric path: artifact.tar.gz -