Mariadb service can no longer be resolved

We use the “services” feature (Services | GitLab) to provide a mariadb service for running wordpress integration tests inside the ci pipeline:

.test:
  stage: test
  image: registry.gitlab.com/360vier/docker-images/php-test:latest
  before_script:
    - composer install

.Test integration:
  extends: .test
  variables:
    MARIADB_ROOT_PASSWORD: password
  services:
    - mariadb
  script:
    - ./bin/install-wp-tests.sh test-integration root password mariadb:3306
    - composer test:integration

The “test integration” job worked for some time, but without any changes to our code base stopped working around a month and a half ago.

The logs say the service is started:

Starting service mariadb:latest ...
Pulling docker image mariadb:latest ...
Using docker image sha256:daf0f023c28d0a811ba382b5645b71cc771c49fd15d53b8075018fb15e677d05 for mariadb:latest with digest mariadb@sha256:07e06f2e7ae9dfc63707a83130a62e00167c827f08fcac7a9aa33f4b6dc34e0e ...
Waiting for services to be up and running...

but later creating the test database fails like this:

+ mysqladmin create test-integration --user=root --password=password --host=mariadb --port=3306 --protocol=tcp
amysqladmin: connect to server at 'mariadb' failed
error: 'Unknown server host 'mariadb' (-2)'
Check that mariadbd is running on mariadb and that the port is 3306.
You can check this by doing 'telnet mariadb 3306'

We even have 2 pipelines for the same commit:
one that passed and one that i triggered later on that fails like this.

I don’t understand what has changed with gitlab pipelines in the last 2 months that could have caused this.

We also see this Problem in other Projects based on the same boilerplate.

Any help is greatly appreciated!