diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2023-10-13 13:56:21 +0200 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2023-10-27 00:13:24 +0200 |
commit | 670d287ee1dc24437ecdd030ccacd2cb5d55109a (patch) | |
tree | aab5d2f776b1e7c2b29644271921732a2337cce5 | |
parent | c4511c38a49c60394b91ec9d4499cdbf41f4e60c (diff) | |
download | Nix-670d287ee1dc24437ecdd030ccacd2cb5d55109a.tar.gz Nix-670d287ee1dc24437ecdd030ccacd2cb5d55109a.tar.zst Nix-670d287ee1dc24437ecdd030ccacd2cb5d55109a.zip |
Bump MariaDB to latest stable version
-rw-r--r-- | flakes/private/system/flake.nix | 2 | ||||
-rw-r--r-- | systems/backup-2/databases/mariadb_replication.nix | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/flakes/private/system/flake.nix b/flakes/private/system/flake.nix index 3e48358..4a83e36 100644 --- a/flakes/private/system/flake.nix +++ b/flakes/private/system/flake.nix | |||
@@ -38,7 +38,7 @@ | |||
38 | [ | 38 | [ |
39 | (self: super: { | 39 | (self: super: { |
40 | postgresql = self.postgresql_pam; | 40 | postgresql = self.postgresql_pam; |
41 | mariadb = self.mariadb_106.overrideAttrs(old: { | 41 | mariadb = self.mariadb_1011.overrideAttrs(old: { |
42 | passthru = old.passthru // { mysqlVersion = "5.7"; }; | 42 | passthru = old.passthru // { mysqlVersion = "5.7"; }; |
43 | }); | 43 | }); |
44 | }) # don’t put them as generic overlay because of home-manager | 44 | }) # don’t put them as generic overlay because of home-manager |
diff --git a/systems/backup-2/databases/mariadb_replication.nix b/systems/backup-2/databases/mariadb_replication.nix index 8d2b457..6616de0 100644 --- a/systems/backup-2/databases/mariadb_replication.nix +++ b/systems/backup-2/databases/mariadb_replication.nix | |||
@@ -195,6 +195,14 @@ in | |||
195 | } | 195 | } |
196 | ) cfg.hosts; | 196 | ) cfg.hosts; |
197 | 197 | ||
198 | environment.systemPackages = lib.mapAttrsToList (name: hcfg: | ||
199 | pkgs.writeScriptBin "mysql_backup_${name}" '' | ||
200 | #!${pkgs.stdenv.shell} | ||
201 | |||
202 | exec ${hcfg.package}/bin/mysql -S /run/mysqld_${name}/mysqld.sock "$@" | ||
203 | '' | ||
204 | ) cfg.hosts; | ||
205 | |||
198 | systemd.services = lib.attrsets.mapAttrs' (name: hcfg: | 206 | systemd.services = lib.attrsets.mapAttrs' (name: hcfg: |
199 | let | 207 | let |
200 | dataDir = "${cfg.base}/${name}/mysql"; | 208 | dataDir = "${cfg.base}/${name}/mysql"; |