bicep: set up mysql/mariadb

This commit is contained in:
Oystein Kristoffer Tveit 2023-05-18 15:40:13 +02:00
parent 45ada78304
commit c11a804097
Signed by untrusted user: oysteikt
GPG Key ID: 9F2F7D8250F35146
2 changed files with 20 additions and 0 deletions

View File

@ -6,6 +6,7 @@
../../base.nix
./services/nginx
./services/mysql.nix
./services/postgres.nix
./services/matrix

View File

@ -0,0 +1,19 @@
{ pkgs, config, ... }:
{
services.mysql = {
enable = true;
dataDir = "/data/mysql";
package = pkgs.mariadb;
settings = {
mysqld = {
# PVV allows a lot of connections at the same time
max_connect_errors = 10000;
};
};
};
services.mysqlBackup = {
enable = true;
location = "/var/lib/mysql/backups";
};
}