The mariadb database container already supports load data infile:
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 5
Server version: 11.7.2-MariaDB-ubu2404 mariadb.org binary distribution
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> SHOW VARIABLES LIKE 'local_infile';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| local_infile | ON |
+---------------+-------+
1 row in set (0.002 sec)
MariaDB [(none)]> SHOW VARIABLES LIKE 'secure_file_priv';
+------------------+-------+
| Variable_name | Value |
+------------------+-------+
| secure_file_priv | |
+------------------+-------+
1 row in set (0.005 sec)
MariaDB [(none)]> exit
Nevertheless I get the matomo warning in the system check:
Datenbankfähigkeiten:
UTF8mb4 charset Connection collation Warning: LOAD DATA INFILE Tipp: Wenn Sie LOAD DATA INFILE verwenden, indem Sie Ihre PHP- und MySQL-Software aktualisieren und sicherstellen, dass Ihr Datenbankbenutzer das FILE-Recht hat, wird der Archivierungsprozess von Matomo erheblich beschleunigt. Sie sollten dieses Problem beheben, wenn Ihr Matomo-Server Webseiten mit hohem Traffic (z.B. über 100.000 Seitenansichten pro Monat) verarbeiten muss. CREATE TEMPORARY TABLES Changing transaction isolation level
If I go a step further and grant the matomo user access manually, it still doesn’t work:
ariaDB [(none)]> GRANT FILE ON *.* TO 'testuser'@'%';
Query OK, 0 rows affected (0.004 sec)
MariaDB [(none)]> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.001 sec)
MariaDB [(none)]> SHOW GRANTS FOR 'testuser'@'%';
+------------------------------------------------------------------------------------------------------+
| Grants for testuser@% |
+------------------------------------------------------------------------------------------------------+
| GRANT FILE ON *.* TO `testuser`@`%` IDENTIFIED BY PASSWORD '*REMOVED_VALUES' |
| GRANT ALL PRIVILEGES ON `matomo`.* TO `testuser`@`%` |
+------------------------------------------------------------------------------------------------------+
2 rows in set (0.001 sec)