From 53e547b732624e2a8d2f1a6f66f4b3e367ebfb97 Mon Sep 17 00:00:00 2001 From: Matthew Wallace Date: Sat, 6 Jan 2024 20:12:48 -0700 Subject: [PATCH] Try another workaround to launch the proper database service --- .github/workflows/integration.yml | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index a67217e..89e99f8 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -144,8 +144,25 @@ jobs: DBT_INVOCATION_ENV: github-actions services: - database: - image: ${{ fromJson( "{'mysql5': 'mysql:5.7', 'mysql': 'mysql:8.0', 'mariadb': 'mariadb:10.5'}" )[matrix.adapter] }} + mysql: + # Conditional workaround https://github.com/actions/runner/issues/822#issuecomment-1524826092 + image: ${{ ( matrix.adapter == 'mysql' ) && 'mysql:8.0' || '' }} + env: + MYSQL_ROOT_PASSWORD: dbt + ports: + - 3306:3306 + options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 + + mysql5: + image: ${{ ( matrix.adapter == 'mysql5' ) && 'mysql:5.7' || '' }} + env: + MYSQL_ROOT_PASSWORD: dbt + ports: + - 3306:3306 + options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 + + mariadb: + image: ${{ ( matrix.adapter == 'mariadb' ) && 'mariadb:10.5' || '' }} env: MYSQL_ROOT_PASSWORD: dbt ports: