From b2eddd020a8bd5ff0ab23e2b6085d4f29f2fa5cc Mon Sep 17 00:00:00 2001 From: Miro Stauder Date: Wed, 18 Sep 2024 18:11:55 +0200 Subject: [PATCH] refactor, use connector in matrix --- .github/workflows/ci-3p-django-framework.yml | 29 ++++++++---------- .github/workflows/ci-3p-laravel-framework.yml | 13 ++------ .../ci-3p-laravel-framework_mariadb.yml | 19 +++++------- .../ci-3p-laravel-framework_mysql.yml | 20 +++++-------- .../workflows/ci-3p-mariadb-connector-c.yml | 30 +++++++++---------- .github/workflows/ci-3p-mysql-connector-j.yml | 17 ++++------- .github/workflows/ci-3p-php-pdo-mysql.yml | 30 +++++++++---------- .github/workflows/ci-3p-sqlalchemy.yml | 14 ++++----- .../workflows/ci-3p-sqlalchemy_mariadb.yml | 24 ++++++--------- .github/workflows/ci-3p-sqlalchemy_mysql.yml | 23 ++++++-------- .github/workflows/ci-basictests.yml | 4 +-- .github/workflows/ci-builds.yml | 12 ++++---- .github/workflows/ci-codeql.yml | 10 +++---- .github/workflows/ci-package-build.yml | 6 ++-- .github/workflows/ci-repltests.yml | 4 +-- .github/workflows/ci-selftests.yml | 4 +-- .github/workflows/ci-shuntest.yml | 4 +-- .github/workflows/ci-taptests-asan.yml | 4 +-- .github/workflows/ci-taptests-groups.yml | 4 +-- .github/workflows/ci-taptests-ssl.yml | 4 +-- .github/workflows/ci-taptests.yml | 4 +-- 21 files changed, 117 insertions(+), 162 deletions(-) diff --git a/.github/workflows/ci-3p-django-framework.yml b/.github/workflows/ci-3p-django-framework.yml index 4bcd939ce..947292425 100644 --- a/.github/workflows/ci-3p-django-framework.yml +++ b/.github/workflows/ci-3p-django-framework.yml @@ -6,9 +6,7 @@ on: env: TESTNAME: django-framework -# TESTDIST: debian11 -# INFRADB: mysql80 -# BASELINE: ${{ vars.BASELINE_3P_DJANGO_FRAMEWORK }} + TESTDIST: debian12 jobs: test: @@ -16,14 +14,13 @@ jobs: strategy: fail-fast: false matrix: - testdist: [ 'debian11' ] +# infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90', 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] infradb: [ 'mysql80', 'mysql81', 'mysql82', 'mariadb10', 'mariadb11' ] + connector: [ 'pymysql' ] env: - TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin - BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin - BASELINE: ${{ vars[format('BASELINE_3P_DJANGO_FRAMEWORK_{0}', matrix.infradb)] }} + CONNECTOR: ${{ matrix.connector }} + BLDCACHE: ${{ github.sha }}_debian12_bin steps: @@ -34,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_django-framework # proxysql @@ -43,14 +40,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -102,7 +98,7 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_django-framework - BASELINE=$(gh variable -R sysown/proxysql list | grep -i BASELINE_3P_DJANGO_FRAMEWORK_${{ matrix.infradb }} | awk '{ print $2 }') + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_DJANGO_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') FAILS=$(cat logs/*run-tests.log | grep -oP 'FAILED \(failures=\d+' | tr '=' ' ' | awk '{ print $3 }') if [[ -z ${FAILS} ]]; then @@ -120,8 +116,9 @@ jobs: exit 1 else echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" - if [[ ${{ github.ref_name }} == v2.x ]]; then - gh variable -R sysown/proxysql set BASELINE_3P_DJANGO_FRAMEWORK_${{ matrix.infradb }} -b "${FAILS}" + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + if [[ ${MAIN} == ${{ github.ref_name }} ]]; then + gh variable -R ${{ github.repository }} set BASELINE_3P_DJANGO_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi @@ -129,7 +126,7 @@ jobs: if: ${{ failure() && !cancelled() }} uses: actions/upload-artifact@v4 with: - name: ${{ github.workflow }}-${{ github.sha }}-${{ matrix.infradb }}-logs-run#${{ github.run_number }} + name: ${{ github.workflow }}-${{ github.sha }}-${{ matrix.infradb }}-${{ matrix.connector }}-logs-run#${{ github.run_number }} path: | proxysql_3p_testing/test_django-framework/logs diff --git a/.github/workflows/ci-3p-laravel-framework.yml b/.github/workflows/ci-3p-laravel-framework.yml index 9fb470ba4..4211d7a36 100644 --- a/.github/workflows/ci-3p-laravel-framework.yml +++ b/.github/workflows/ci-3p-laravel-framework.yml @@ -14,19 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian11' ] # infradb: [ 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] -# connector: [ 'pymysql', 'mysqldb', 'asyncmy', 'mariadbconnector' ] infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90' ] connector: [ 'mysql', 'mariadb' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_LARAVEL_FRAMEWORK_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -37,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_laravel-framework # proxysql @@ -46,7 +40,6 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" @@ -104,7 +97,7 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_laravel-framework - #BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} | awk '{ print $2 }') + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') FAILS=$(cat logs/*run-tests.log | grep -oP '^There were \d+ failures:' | awk '{ print $3 }') if [[ -z ${FAILS} ]]; then @@ -124,7 +117,7 @@ jobs: echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) if [[ ${MAIN} == ${{ github.ref_name }} ]]; then - gh variable -R ${{ github.repository }} set BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + gh variable -R ${{ github.repository }} set BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-3p-laravel-framework_mariadb.yml b/.github/workflows/ci-3p-laravel-framework_mariadb.yml index 75ff7d10f..3752aa0a3 100644 --- a/.github/workflows/ci-3p-laravel-framework_mariadb.yml +++ b/.github/workflows/ci-3p-laravel-framework_mariadb.yml @@ -14,18 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian11' ] infradb: [ 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] # infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90' ] connector: [ 'mysql', 'mariadb' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_LARAVEL_FRAMEWORK_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -36,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_laravel-framework # proxysql @@ -45,14 +40,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -94,7 +88,7 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_laravel-framework - #BASELINE=$(gh variable -R sysown/proxysql list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} | awk '{ print $2 }') + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') FAILS=$(cat logs/*run-tests.log | grep -oP '^There were \d+ failures:' | awk '{ print $3 }') if [[ -z ${FAILS} ]]; then @@ -112,8 +106,9 @@ jobs: exit 1 else echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" - if [[ ${{ github.ref_name }} == v2.x ]]; then - gh variable -R sysown/proxysql set BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + if [[ ${MAIN} == ${{ github.ref_name }} ]]; then + gh variable -R ${{ github.repository }} set BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-3p-laravel-framework_mysql.yml b/.github/workflows/ci-3p-laravel-framework_mysql.yml index 70befcec6..4211d7a36 100644 --- a/.github/workflows/ci-3p-laravel-framework_mysql.yml +++ b/.github/workflows/ci-3p-laravel-framework_mysql.yml @@ -14,19 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian11' ] # infradb: [ 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] -# connector: [ 'pymysql', 'mysqldb', 'asyncmy', 'mariadbconnector' ] infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90' ] connector: [ 'mysql', 'mariadb' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_LARAVEL_FRAMEWORK_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -37,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_laravel-framework # proxysql @@ -46,14 +40,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -104,7 +97,7 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_laravel-framework - #BASELINE=$(gh variable -R sysown/proxysql list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} | awk '{ print $2 }') + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') FAILS=$(cat logs/*run-tests.log | grep -oP '^There were \d+ failures:' | awk '{ print $3 }') if [[ -z ${FAILS} ]]; then @@ -122,8 +115,9 @@ jobs: exit 1 else echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" - if [[ ${{ github.ref_name }} == v2.x ]]; then - gh variable -R sysown/proxysql set BASELINE_3P_LARAVEL_FRAMEWORK_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + if [[ ${MAIN} == ${{ github.ref_name }} ]]; then + gh variable -R ${{ github.repository }} set BASELINE_3P_LARAVEL_FRAMEWORK_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-3p-mariadb-connector-c.yml b/.github/workflows/ci-3p-mariadb-connector-c.yml index 91ce7beb3..1fcb0ecc4 100644 --- a/.github/workflows/ci-3p-mariadb-connector-c.yml +++ b/.github/workflows/ci-3p-mariadb-connector-c.yml @@ -6,9 +6,7 @@ on: env: TESTNAME: mariadb-connector-c -# TESTDIST: debian11 -# INFRADB: mysql57 -# BASELINE: ${{ vars.BASELINE_3P_MARIADB_CONNECTOR_C }} + TESTDIST: debian12 jobs: test: @@ -16,14 +14,13 @@ jobs: strategy: fail-fast: false matrix: - testdist: [ 'debian11' ] +# infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90', 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] infradb: [ 'mysql57', 'mysql80', 'mysql81', 'mysql82', 'mariadb10', 'mariadb11' ] + connector: [ 8.0 ] env: - TESTDIST: ${{ matrix.testdist }} - INFRADB: ${{ matrix.infradb }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin - BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin - BASELINE: ${{ vars[format('BASELINE_3P_MARIADB_CONNECTOR_C_{0}', matrix.infradb)] }} + INFRADB: ${{ matrix.infradb }} + CONNECTOR: ${{ matrix.connector }} + BLDCACHE: ${{ github.sha }}_debian12_bin steps: @@ -34,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_mariadb-connector-c proxysql @@ -43,14 +40,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -98,6 +94,7 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_mariadb-connector-c + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_MARIADB_CONNECTOR_C_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') FAILS=$(cat logs/*run-tests.log | grep 'FAIL' | grep ' / ' | awk '{ print $2 }') if [[ -z ${FAILS} ]]; then @@ -110,8 +107,9 @@ jobs: exit 1 else echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" - if [[ ${{ github.ref_name }} == v2.x ]]; then - gh variable -R sysown/proxysql set BASELINE_3P_MARIADB_CONNECTOR_C_${{ matrix.infradb }} -b "${FAILS}" + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + if [[ ${MAIN} == ${{ github.ref_name }} ]]; then + gh variable -R ${{ github.repository }} set BASELINE_3P_MARIADB_CONNECTOR_C_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi @@ -119,7 +117,7 @@ jobs: if: ${{ failure() && !cancelled() }} uses: actions/upload-artifact@v4 with: - name: ${{ github.workflow }}-${{ github.sha }}-${{ matrix.infradb }}-logs-run#${{ github.run_number }} + name: ${{ github.workflow }}-${{ github.sha }}-${{ matrix.infradb }}-${{ matrix.connector }}-logs-run#${{ github.run_number }} path: | proxysql_3p_testing/test_mariadb-connector-c/logs diff --git a/.github/workflows/ci-3p-mysql-connector-j.yml b/.github/workflows/ci-3p-mysql-connector-j.yml index 787bfcd3a..06f0322bb 100644 --- a/.github/workflows/ci-3p-mysql-connector-j.yml +++ b/.github/workflows/ci-3p-mysql-connector-j.yml @@ -7,8 +7,6 @@ on: env: TESTNAME: mysql-connector-j TESTDIST: debian12 -# INFRADB: mysql57 -# BASELINE: ${{ vars.BASELINE_3P_MYSQL_CONNECTOR_J }} jobs: test: @@ -16,17 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian11' ] - infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90', 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] +# infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90', 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] + infradb: [ 'mysql57', 'mysql80', 'mysql81', 'mysql82', 'mariadb10', 'mariadb11' ] connector: [ '8.0.33' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_MYSQL_CONNECTOR_J_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -37,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_mysql-connector-j proxysql @@ -46,7 +40,6 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" @@ -93,6 +86,8 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_mysql-connector-j + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_MYSQL_CONNECTOR_J_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') + FAILS=$(cat logs/*run-tests.log | grep 'FAIL' | grep ' / ' | awk '{ print $2 }') if [[ -z ${FAILS} ]]; then echo "Baseline '${BASELINE:-10000}' WARN: no results found" @@ -105,7 +100,7 @@ jobs: echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) if [[ ${MAIN} == ${{ github.ref_name }} ]]; then - gh variable -R ${{ github.repository }} set BASELINE_3P_MYSQL_CONNECTOR_J_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + gh variable -R ${{ github.repository }} set BASELINE_3P_MYSQL_CONNECTOR_J_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-3p-php-pdo-mysql.yml b/.github/workflows/ci-3p-php-pdo-mysql.yml index 0eda0b78f..e6399a46e 100644 --- a/.github/workflows/ci-3p-php-pdo-mysql.yml +++ b/.github/workflows/ci-3p-php-pdo-mysql.yml @@ -6,9 +6,7 @@ on: env: TESTNAME: php-pdo-mysql -# TESTDIST: debian11 -# INFRADB: mysql57 -# BASELINE: ${{ vars.BASELINE_3P_PHP_PDO_MYSQL }} + TESTDIST: debian12 jobs: test: @@ -16,15 +14,13 @@ jobs: strategy: fail-fast: false matrix: - testdist: [ 'debian11' ] -# infradb: [ 'mysql57', 'mysql80', 'mysql81', 'mysql82', 'mariadb10', 'mariadb11' ] +# infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90', 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] infradb: [ 'mysql57' ] + connector: [ 'mysql', 'mariadb' ] env: - TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} -# BLDCACHE: CI-builds_${{ github.sha }}_${{ matrix.testdist }}_bin - BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin - BASELINE: ${{ vars[format('BASELINE_3P_PHP_PDO_MYSQL_{0}', matrix.infradb)] }} + CONNECTOR: ${{ matrix.connector }} + BLDCACHE: ${{ github.sha }}_debian12_bin steps: @@ -35,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | test_php-pdo-mysql proxysql @@ -44,14 +40,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -91,6 +86,8 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_php-pdo-mysql + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_PHP_PDO_MYSQL_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') + FAILS=$(cat logs/*run-tests.log | grep 'Tests failed :' | awk '{ print $4 }') if [[ -z ${FAILS} ]]; then echo "Baseline '${BASELINE:-10000}' WARN: no results found" @@ -101,8 +98,9 @@ jobs: exit 1 else echo "Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" - if [[ ${{ github.ref_name }} == v2.x ]]; then - gh variable -R sysown/proxysql set BASELINE_3P_PHP_PDO_MYSQL_${{ matrix.infradb }} -b "${FAILS}" + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + if [[ ${MAIN} == ${{ github.ref_name }} ]]; then + gh variable -R ${{ github.repository }} set BASELINE_3P_PHP_PDO_MYSQL_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi @@ -110,7 +108,7 @@ jobs: if: ${{ failure() && !cancelled() }} uses: actions/upload-artifact@v4 with: - name: ${{ github.workflow }}-${{ github.sha }}-logs-run#${{ github.run_number }} + name: ${{ github.workflow }}-${{ github.sha }}-${{ matrix.infradb }}-${{ matrix.connector }}logs-run#${{ github.run_number }} path: | proxysql_3p_testing/test_php-pdo-mysql/logs diff --git a/.github/workflows/ci-3p-sqlalchemy.yml b/.github/workflows/ci-3p-sqlalchemy.yml index 351463b06..f5d7c0fc3 100644 --- a/.github/workflows/ci-3p-sqlalchemy.yml +++ b/.github/workflows/ci-3p-sqlalchemy.yml @@ -6,7 +6,7 @@ on: env: TESTNAME: sqlalchemy - TESTDIST: 'debian12' + TESTDIST: debian12 jobs: test: @@ -14,18 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian12' ] # infradb: [ 'mysql57', 'mysql80', 'mysql81', 'mysql82', 'mysql83', 'mysql84', 'mysql90', 'mariadb10', 'mariadb11' ] infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90' ] connector: [ 'pymysql', 'mysqldb', 'asyncmy', 'mariadbconnector' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ env.TESTDIST }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_SQLALCHEMY_{0}_{1}', matrix.infradb, matrix.connector)] }} outputs: summary: ${{ steps.check_baseline.outputs.summary }} @@ -38,7 +33,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | infra-docker-hoster test_sqlalchemy @@ -48,7 +43,6 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" @@ -95,6 +89,8 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_sqlalchemy + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') + GHUSER="$(id -u):$(id -g)" sudo chown -R ${GHUSER} ./logs FAILS=$(cat logs/*run-tests.log | grep -oP '^=+ \d+ failed, ' | awk '{ print $2 }') @@ -113,7 +109,7 @@ jobs: #MAIN=$(gh repo view ${{ github.repository }} --json defaultBranchRef --jq .defaultBranchRef.name) if [[ ${MAIN} == ${{ github.ref_name }} ]]; then echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Setting new BASELINE: ${FAILS} for '${MAIN}'" - gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi SUM="{'STATUS':'${STATUS}','INFRADB':'${INFRADB}','CONNECTOR':'${CONNECTOR}','BASELINE':${BASELINE:-10000},'FAILS':${FAILS:-1}}" diff --git a/.github/workflows/ci-3p-sqlalchemy_mariadb.yml b/.github/workflows/ci-3p-sqlalchemy_mariadb.yml index 12b456678..146ccebbd 100644 --- a/.github/workflows/ci-3p-sqlalchemy_mariadb.yml +++ b/.github/workflows/ci-3p-sqlalchemy_mariadb.yml @@ -6,7 +6,7 @@ on: env: TESTNAME: sqlalchemy - TESTDIST: 'debian12' + TESTDIST: debian12 jobs: test: @@ -14,19 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian12' ] -# # https://mariadb.com/kb/en/mariadb-server-release-dates/ infradb: [ 'mariadb10.5', 'mariadb10.6', 'mariadb10.11', 'mariadb11.2', 'mariadb11.4', 'mariadb11.5' ] # infradb: [ 'mariadb10', 'mariadb11' ] connector: [ 'pymysql', 'mysqldb', 'asyncmy', 'mariadbconnector' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ env.TESTDIST }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_SQLALCHEMY_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -37,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | infra-docker-hoster test_sqlalchemy @@ -47,14 +41,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -97,7 +90,8 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_sqlalchemy - cat logs/*run-tests.log | grep -oP '^=+ \d+ failed, ' + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') + FAILS=$(cat logs/*run-tests.log | grep -oP '^=+ \d+ failed, ' | awk '{ print $2 }') if [[ -z ${FAILS} ]]; then echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE}' WARN: no results found" @@ -112,11 +106,11 @@ jobs: echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" >> $GITHUB_STEP_SUMMARY #MAIN=$(git -C ./proxysql remote show origin | grep -Po '(?<=HEAD branch: ).*') - #MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) - MAIN=$(gh repo view ${{ github.repository }} --json defaultBranchRef --jq .defaultBranchRef.name) + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + #MAIN=$(gh repo view ${{ github.repository }} --json defaultBranchRef --jq .defaultBranchRef.name) if [[ ${MAIN} == ${{ github.ref_name }} ]]; then echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Setting new BASELINE: ${FAILS} for '${MAIN}'" - gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-3p-sqlalchemy_mysql.yml b/.github/workflows/ci-3p-sqlalchemy_mysql.yml index bca57a647..e80345dc8 100644 --- a/.github/workflows/ci-3p-sqlalchemy_mysql.yml +++ b/.github/workflows/ci-3p-sqlalchemy_mysql.yml @@ -6,7 +6,7 @@ on: env: TESTNAME: sqlalchemy - TESTDIST: 'debian12' + TESTDIST: debian12 jobs: test: @@ -14,18 +14,13 @@ jobs: strategy: fail-fast: false matrix: -# testdist: [ 'debian12' ] # infradb: [ 'mysql57', 'mysql80', 'mysql81', 'mysql82', 'mysql83', 'mysql84', 'mysql90', 'mariadb10', 'mariadb11' ] infradb: [ 'mysql57', 'mysql80', 'mysql84', 'mysql90' ] connector: [ 'pymysql', 'mysqldb', 'asyncmy', 'mariadbconnector' ] env: -# TESTDIST: ${{ matrix.testdist }} INFRADB: ${{ matrix.infradb }} CONNECTOR: ${{ matrix.connector }} -# BLDCACHE: ${{ github.sha }}_${{ matrix.testdist }}_bin -# BLDCACHE: ${{ github.sha }}_${{ env.TESTDIST }}_bin BLDCACHE: ${{ github.sha }}_debian12_bin - BASELINE: ${{ vars[format('BASELINE_3P_SQLALCHEMY_{0}_{1}', matrix.infradb, matrix.connector)] }} steps: @@ -36,7 +31,7 @@ jobs: ref: 'main' fetch-depth: 1 path: 'proxysql_3p_testing' - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.gh_token }} sparse-checkout: | infra-docker-hoster test_sqlalchemy @@ -46,14 +41,13 @@ jobs: env: GH_TOKEN: ${{ secrets.gh_token }} run: | - echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -92,7 +86,8 @@ jobs: GH_TOKEN: ${{ secrets.gh_token }} run: | cd proxysql_3p_testing/test_sqlalchemy - cat logs/*run-tests.log | grep -oP '^=+ \d+ failed, ' + BASELINE=$(gh variable -R ${{ github.repository }} list | grep -i BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} | awk '{ print $2 }') + FAILS=$(cat logs/*run-tests.log | grep -oP '^=+ \d+ failed, ' | awk '{ print $2 }') if [[ -z ${FAILS} ]]; then echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE}' WARN: no results found" @@ -107,11 +102,11 @@ jobs: echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Baseline '${BASELINE:-10000}' PASS: FAILS = ${FAILS}" >> $GITHUB_STEP_SUMMARY #MAIN=$(git -C ./proxysql remote show origin | grep -Po '(?<=HEAD branch: ).*') - #MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) - MAIN=$(gh repo view ${{ github.repository }} --json defaultBranchRef --jq .defaultBranchRef.name) + MAIN=$(curl -s https://api.github.com/repos/${{ github.repository }} | jq --raw-output .default_branch) + #MAIN=$(gh repo view ${{ github.repository }} --json defaultBranchRef --jq .defaultBranchRef.name) if [[ ${MAIN} == ${{ github.ref_name }} ]]; then echo "INFRADB: '${INFRADB}' CONNECTOR: '${CONNECTOR}' Setting new BASELINE: ${FAILS} for '${MAIN}'" - gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${{ matrix.infradb }}_${{ matrix.connector }} -b "${FAILS}" + gh variable -R ${{ github.repository }} set BASELINE_3P_SQLALCHEMY_${INFRADB/./}_${CONNECTOR/./} -b "${FAILS}" fi fi diff --git a/.github/workflows/ci-basictests.yml b/.github/workflows/ci-basictests.yml index efe050c2c..fda6f8352 100644 --- a/.github/workflows/ci-basictests.yml +++ b/.github/workflows/ci-basictests.yml @@ -52,11 +52,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-builds.yml b/.github/workflows/ci-builds.yml index ddd7c9319..404033335 100644 --- a/.github/workflows/ci-builds.yml +++ b/.github/workflows/ci-builds.yml @@ -22,16 +22,16 @@ jobs: # run: | # # lock fast # echo "Setting lock '${LOCK^^}' to '${{ github.workflow }}'" -# gh variable -R sysown/proxysql list | grep -i ${LOCK} >/dev/null || gh variable -R sysown/proxysql set ${LOCK} -b '${{ github.workflow }}' >/dev/null +# gh variable -R ${{ github.repository }} list | grep -i ${LOCK} >/dev/null || gh variable -R ${{ github.repository }} set ${LOCK} -b '${{ github.workflow }}' >/dev/null # # # wait for unlock # sleep 5 -# PROBE="$(gh variable -R sysown/proxysql list | grep -i ${LOCK} || echo '')" +# PROBE="$(gh variable -R ${{ github.repository }} list | grep -i ${LOCK} || echo '')" # if [[ ! ${PROBE} =~ ${{ github.workflow }} ]]; then # while [[ ! -z ${PROBE} ]]; do # echo "Wating for unlock '${LOCK^^}' by '$(echo ${PROBE} | awk '{ print $2 }')' ..." # sleep 15 -# PROBE="$(gh variable -R sysown/proxysql list | grep -i ${LOCK} || echo '')" +# PROBE="$(gh variable -R ${{ github.repository }} list | grep -i ${LOCK} || echo '')" # done # else # echo "Aquired lock '${LOCK^^}' by '${{ github.workflow }}'" @@ -89,7 +89,7 @@ jobs: if: ${{ steps.cache-check.outputs.cache-hit != 'true' }} uses: actions/checkout@v4 with: -# repository: 'sysown/proxysql' +# repository: '${{ github.repository }}' # ref: 'v2.x' fetch-depth: 0 path: 'proxysql' @@ -217,10 +217,10 @@ jobs: # - name: Concurency unlock # run: | # # delete lock -# PROBE="$(gh variable -R sysown/proxysql list | grep -i ${LOCK} || echo '')" +# PROBE="$(gh variable -R ${{ github.repository }} list | grep -i ${LOCK} || echo '')" # if [[ ${PROBE} =~ ${{ github.workflow }} ]]; then # echo "Releasing lock '${LOCK^^}' by '$(echo ${PROBE} | awk '{ print $2 }')'" -# gh variable -R sysown/proxysql delete ${LOCK} || true +# gh variable -R ${{ github.repository }} delete ${LOCK} || true # elif [[ ! -z ${PROBE} ]]; then # echo "Lock raced '${LOCK^^}' by '$(echo ${PROBE} | awk '{ print $2 }')'" # # exit -1 diff --git a/.github/workflows/ci-codeql.yml b/.github/workflows/ci-codeql.yml index 4d0f3570f..686774ad0 100644 --- a/.github/workflows/ci-codeql.yml +++ b/.github/workflows/ci-codeql.yml @@ -48,11 +48,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" @@ -81,9 +81,9 @@ jobs: # env: # GH_TOKEN: ${{ github.token }} # run: | -# export VERS=$(git ls-remote https://github.com/sysown/proxysql.git "refs/tags/*" | grep -v 'refs/tags/v' | sed -e 's|.*/||g' | tail -2 | head -1) -# export HASH=$(gh api repos/sysown/proxysql/git/refs/heads/v2.x | jq '.object.sha' | cut -c2-8) -# export CMTS=$(gh api repos/sysown/proxysql/compare/${VERS}...v2.x | jq '.ahead_by') +# export VERS=$(git ls-remote https://github.com/${{ github.repository }}.git "refs/tags/*" | grep -v 'refs/tags/v' | sed -e 's|.*/||g' | tail -2 | head -1) +# export HASH=$(gh api repos/${{ github.repository }}/git/refs/heads/v2.x | jq '.object.sha' | cut -c2-8) +# export CMTS=$(gh api repos/${{ github.repository }}/compare/${VERS}...v2.x | jq '.ahead_by') # echo "git descibe : ${VERS}-${CMTS}-g${HASH}" # echo "GIT_VERSION=${VERS}-${CMTS}-g${HASH}" >> $GITHUB_ENV diff --git a/.github/workflows/ci-package-build.yml b/.github/workflows/ci-package-build.yml index 377a16a0f..64c68e53d 100644 --- a/.github/workflows/ci-package-build.yml +++ b/.github/workflows/ci-package-build.yml @@ -25,7 +25,7 @@ jobs: Status : **Build in progress** - [![CI-Package-Build](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml) + [![CI-Package-Build](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml) EOF @@ -88,7 +88,7 @@ jobs: Status : **Build in progress** - [![CI-Package-Build](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml) + [![CI-Package-Build](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml) EOF fi @@ -148,7 +148,7 @@ jobs: Status : **Build is finished** - [![CI-Package-Build](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/sysown/proxysql/actions/workflows/CI-package-build.yml) + [![CI-Package-Build](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml/badge.svg)](https://github.com/${{ github.repository }}/actions/workflows/CI-package-build.yml) EOF diff --git a/.github/workflows/ci-repltests.yml b/.github/workflows/ci-repltests.yml index 41fe16779..07406d86a 100644 --- a/.github/workflows/ci-repltests.yml +++ b/.github/workflows/ci-repltests.yml @@ -33,11 +33,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-selftests.yml b/.github/workflows/ci-selftests.yml index 836d7ff39..adb274b1d 100644 --- a/.github/workflows/ci-selftests.yml +++ b/.github/workflows/ci-selftests.yml @@ -28,11 +28,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-shuntest.yml b/.github/workflows/ci-shuntest.yml index 1b1e204f9..a80ae6085 100644 --- a/.github/workflows/ci-shuntest.yml +++ b/.github/workflows/ci-shuntest.yml @@ -33,11 +33,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-taptests-asan.yml b/.github/workflows/ci-taptests-asan.yml index baf4c3824..7e19d100e 100644 --- a/.github/workflows/ci-taptests-asan.yml +++ b/.github/workflows/ci-taptests-asan.yml @@ -33,11 +33,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-taptests-groups.yml b/.github/workflows/ci-taptests-groups.yml index 99a49248d..57a2f95f8 100644 --- a/.github/workflows/ci-taptests-groups.yml +++ b/.github/workflows/ci-taptests-groups.yml @@ -30,11 +30,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-taptests-ssl.yml b/.github/workflows/ci-taptests-ssl.yml index 6870ea707..63722a48f 100644 --- a/.github/workflows/ci-taptests-ssl.yml +++ b/.github/workflows/ci-taptests-ssl.yml @@ -33,11 +33,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'" diff --git a/.github/workflows/ci-taptests.yml b/.github/workflows/ci-taptests.yml index d674cc5a0..23d2a7d75 100644 --- a/.github/workflows/ci-taptests.yml +++ b/.github/workflows/ci-taptests.yml @@ -33,11 +33,11 @@ jobs: echo "BASELINE: '${BASELINE}'" echo "Wating for cache '${BLDCACHE}' ..." sleep $(( $RANDOM / 1024 )) - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" while [[ -z ${PROBE} ]]; do echo "Wating for cache '${BLDCACHE}' ..." sleep 30 - PROBE="$(gh cache list --limit 300 --repo sysown/proxysql | grep -i ${BLDCACHE} || echo '')" + PROBE="$(gh cache list --limit 300 --repo ${{ github.repository }} | grep -i ${BLDCACHE} || echo '')" done echo "Cache available '${BLDCACHE}'"