Search code examples
drupaldocker-composemariadbddev

Drupal 9 Default install MariaDB out of date


Hello I was following this tutorial here: https://drupalize.me/tutorial/set-demo-site-theming-practice?p=3290

then I realized since drupal 9 is out, by default drupal9 instead of drupa8.x is installed when running:

composer create-project drupal/recommended-project $SITE_NAME

So I continued along and was fine until I came to the install local drupal site webpage on localhost. I got the error:

The database server version 10.2.31-MariaDB-1:10.2.31+maria~bionic-log is less
than the minimum required version 10.3.7.

Since I'm using ddev and docker, does this mean I need to upgrade my MariaDB version used inside of my image? if so, how do I do that?

I'm not very familiar with dev, docker, or images so if there are any technical concepts needed to understand how to solve this problem, an explanation would help a lot.

A step by step solution explaining each step would be really helpful. Thanks!


Solution

  • If you want Drupal 9, please use the quickstart at https://ddev.readthedocs.io/en/latest/users/cli-usage/#drupal-9-quickstart

    Drupal 9 requires MariaDB 10.3, which you get automatically when you use current ddev (v1.14+)

    mkdir my-drupal9-site
    cd my-drupal9-site
    ddev config --project-type=drupal9 --docroot=web --create-docroot
    ddev start
    ddev composer create "drupal/recommended-project"
    ddev composer require drush/drush
    ddev launch
    

    If you want Drupal 8, please use the Drupal 8 quickstart, https://ddev.readthedocs.io/en/latest/users/cli-usage/#drupal-8-quickstart

    mkdir my-drupal8-site
    cd my-drupal8-site
    ddev config --project-type=drupal8 --docroot=web --create-docroot
    ddev start
    ddev composer create "drupal/recommended-project:^8"
    ddev composer require drush/drush
    ddev launch