From b7a1d36dceece2c8ebb42faf5bfa1e0994a878a0 Mon Sep 17 00:00:00 2001 From: gam6itko Date: Sun, 2 Jun 2024 11:28:02 +0300 Subject: [PATCH 1/4] tests docker-compose remove `restart: always` --- tests/docker-compose.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tests/docker-compose.yml b/tests/docker-compose.yml index 8cb062a9..5103e7b1 100644 --- a/tests/docker-compose.yml +++ b/tests/docker-compose.yml @@ -11,20 +11,18 @@ services: cycle-mysql_latest: image: mysql:8.0.37 - restart: always - command: --default-authentication-plugin=mysql_native_password + command: | + --default-authentication-plugin=mysql_native_password + --character-set-server=utf8mb4 ports: - "13306:3306" environment: MYSQL_DATABASE: "spiral" MYSQL_ROOT_PASSWORD: "root" MYSQL_ROOT_HOST: "%" - MYSQL_CHARSET: "utf8mb4" - MYSQL_COLLATION: "utf8mb4_unicode_ci" cycle-postgres: image: postgres:15.2 - restart: always ports: - "15432:5432" environment: From 0133cf84e86aee7d2396d4b0992cf3950d9174bf Mon Sep 17 00:00:00 2001 From: gam6itko Date: Sun, 2 Jun 2024 20:26:33 +0300 Subject: [PATCH 2/4] gh wf --- .github/workflows/ci-mysql.yml | 4 ++++ tests/docker-compose.yml | 3 +++ 2 files changed, 7 insertions(+) diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index 1b4e8ca4..39fcca6a 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -43,6 +43,10 @@ jobs: options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 steps: + - name: Set charset and collation + run: | + mysql -proot -e "ALTER DATABASE spiral CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;" + - name: Checkout uses: actions/checkout@v2 diff --git a/tests/docker-compose.yml b/tests/docker-compose.yml index 5103e7b1..a0ca57a3 100644 --- a/tests/docker-compose.yml +++ b/tests/docker-compose.yml @@ -11,9 +11,11 @@ services: cycle-mysql_latest: image: mysql:8.0.37 + restart: on-failure command: | --default-authentication-plugin=mysql_native_password --character-set-server=utf8mb4 + --collation-server=utf8mb4_unicode_ci ports: - "13306:3306" environment: @@ -23,6 +25,7 @@ services: cycle-postgres: image: postgres:15.2 + restart: on-failure ports: - "15432:5432" environment: From 874af9ef62e441f2d0657b8716a04735efe31fc0 Mon Sep 17 00:00:00 2001 From: gam6itko Date: Sun, 2 Jun 2024 20:31:11 +0300 Subject: [PATCH 3/4] gh wf --- .github/workflows/ci-mysql.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index 39fcca6a..d9dc4d34 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -43,9 +43,8 @@ jobs: options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 steps: - - name: Set charset and collation - run: | - mysql -proot -e "ALTER DATABASE spiral CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;" + - name: Show databases for root user + run: mysql --protocol=tcp -h localhost -P 3306 -u root -proot -e "ALTER DATABASE spiral CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;" - name: Checkout uses: actions/checkout@v2 From b8becb85a660ccb92e34231374ea9be87db49443 Mon Sep 17 00:00:00 2001 From: gam6itko Date: Sun, 2 Jun 2024 20:34:54 +0300 Subject: [PATCH 4/4] gh wf --- .github/workflows/ci-mysql.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index d9dc4d34..b88e39ac 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -44,7 +44,7 @@ jobs: steps: - name: Show databases for root user - run: mysql --protocol=tcp -h localhost -P 3306 -u root -proot -e "ALTER DATABASE spiral CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;" + run: mysql --protocol=tcp -h localhost -P 13306 -u root -proot -e "ALTER DATABASE spiral CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;" - name: Checkout uses: actions/checkout@v2