Make pid file optional for OS'es running systemd and MariaDB
Use Case
As of 10.1.8 MariaDB is systemd aware and therefore no longer requires a PID file. Indeed, when using this module, MariaDB from the mariadb-main repo won't start because /var/run/mariadb/ is no longer created on CentOS 7 and RHEL 8 (the two OS releases I've tested) and this module forces the pid-file option, with a value, into the configuration files.
Describe the Solution You Would Like
Move the pid-file variable from being set all the time to the class parameter level, and leave it out of the server.cnf file if it's not defined, or automatically not include it when deploying the service via systemd.
This issue has been marked as stale because it has been open for a while and has had no recent activity. If this issue is still important to you please drop a comment below and we will add this to our backlog to complete. Otherwise, it will be closed in 7 days.
This is an issue when using the official MariaDB-10.8 packages on Rocky Linux 8 as well.