2024-03-23 06:06:28 +01:00
|
|
|
[Unit]
|
|
|
|
Description=MariaDB database server
|
|
|
|
After=syslog.target
|
|
|
|
After=network.target
|
|
|
|
|
|
|
|
[Service]
|
2024-04-06 06:48:58 +02:00
|
|
|
#allow our expand-templates
|
|
|
|
PermissionsStartOnly=true
|
2024-03-23 06:06:28 +01:00
|
|
|
|
|
|
|
#reset
|
|
|
|
ExecStartPre=
|
|
|
|
#ours : we need root user as + and ! are not yet supported
|
2024-04-06 06:48:58 +02:00
|
|
|
ExecStartPre=/usr/libexec/mysql-check-socket
|
2024-03-23 06:06:28 +01:00
|
|
|
ExecStartPre=-/sbin/e-smith/service-status mariadb
|
2024-04-06 06:48:58 +02:00
|
|
|
ExecStartPre=-/sbin/e-smith/expand-template /var/lib/mysql.private/set.password
|
2024-03-23 06:06:28 +01:00
|
|
|
ExecStartPre=-/sbin/e-smith/expand-template /root/.my.cnf
|
|
|
|
ExecStartPre=-/sbin/e-smith/expand-template /etc/my.cnf
|
|
|
|
ExecStartPre=/sbin/e-smith/systemd/mariadb-initialize
|
|
|
|
|
|
|
|
#reset
|
|
|
|
ExecStart=
|
|
|
|
#ours
|
|
|
|
ExecStart=/usr/libexec/mysqld \
|
|
|
|
--defaults-file=/etc/my.cnf \
|
|
|
|
--basedir=/usr \
|
|
|
|
--datadir=/var/lib/mysql \
|
|
|
|
--user=mysql \
|
|
|
|
--pid-file=/var/run/mariadb/mariadb.pid
|
|
|
|
|
2024-04-06 06:48:58 +02:00
|
|
|
ExecStartPost=-/sbin/e-smith/systemd/mariadb-post
|
2024-03-23 06:06:28 +01:00
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=sme-server.target
|
|
|
|
|