Skip to content

Commit

Permalink
WIP: adapting to new percona release scheme
Browse files Browse the repository at this point in the history
pulls in nixpkgs PR to run tests

still needs docs
  • Loading branch information
osnyx committed May 7, 2024
1 parent 6fda86d commit 29e769f
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 5 deletions.
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions nixos/roles/mysql.nix
Original file line number Diff line number Diff line change
Expand Up @@ -57,28 +57,33 @@ in
mysql57 = mkRole "5.7";
percona80 = mkRole "8.0";
percona81 = mkRole "8.1";
percona83 = mkRole "8.3";
};

};

config =
let
# TODO: with the impending explosion of percona releases, we might want to streamline this
mysqlRoles = with config.flyingcircus.roles; {
"5.7" = mysql57.enable;
"8.0" = percona80.enable;
"8.1" = percona81.enable;
"8.3" = percona83.enable;
};

mysqlPackages = with pkgs; {
"5.7" = percona57;
"8.0" = percona80;
"8.1" = percona81;
"8.3" = percona83;
};

xtrabackupPackages = with pkgs; {
"5.7" = percona-xtrabackup_2_4;
"8.0" = percona-xtrabackup_8_0;
"8.1" = percona-xtrabackup_8_1;
"8.3" = percona-xtrabackup_8_3;
};

cfg = config.flyingcircus.roles.mysql;
Expand Down
7 changes: 7 additions & 0 deletions pkgs/overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,7 @@ builtins.mapAttrs (_: patchPhps phpLogPermissionPatch) {

percona80 = super.percona-server_8_0;

# FIXME: this is EOL, do we still need it?
percona81 = super.callPackage ./percona/8.1.nix {
boost = self.boost177;
icu = self.icu69;
Expand All @@ -347,16 +348,22 @@ builtins.mapAttrs (_: patchPhps phpLogPermissionPatch) {
inherit (self.darwin.apple_sdk.frameworks) CoreServices;
};

# assertion notifies us about the need to vendor the old innovation releases
percona83 = assert self.percona-server_innovation.mysqlVersion == "8.3"; self.percona-server_innovation;

percona-xtrabackup_2_4 = super.callPackage ./percona-xtrabackup/2_4.nix {
boost = self.boost159;
openssl = self.openssl_1_1;
};

# FIXME: this is EOL, do we still need it?
percona-xtrabackup_8_1 = super.callPackage ./percona-xtrabackup/8_1.nix {
boost = self.boost177;
protobuf = self.protobuf_21;
};

percona-xtrabackup_8_3 = assert self.percona-xtrabackup_innovation.mysqlVersion == "8.3"; self.percona-xtrabackup_innovation;

# Has been renamed upstream, backy-extract still wants to use it.
pkgconfig = super.pkg-config;

Expand Down
4 changes: 2 additions & 2 deletions release/versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
"url": "https://gitlab.flyingcircus.io/flyingcircus/nixos-mailserver.git/"
},
"nixpkgs": {
"hash": "sha256-TxArUwWgpFz8NZ3UFal97fT0c2klCIIqfZKHaQcFu30=",
"hash": "sha256-KDKRKJW3qGm4QBhjKqV2G+NPd9OsZPCar6R9VyFcO3Q=",
"owner": "flyingcircusio",
"repo": "nixpkgs",
"rev": "f5b0f08d5f02d320901ed6991eabaf012c01c0d6"
"rev": "b4509fefd60027505124a781a32dc7f8e6dca108"
}
}
1 change: 1 addition & 0 deletions tests/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ in {
openvpn = callTest ./openvpn.nix {};
percona80 = callTest ./mysql.nix { rolename = "percona80"; };
percona81 = callTest ./mysql.nix { rolename = "percona81"; };
percona83 = callTest ./mysql.nix { rolename = "percona83"; };
physical-installer = callTest ./physical-installer.nix { inherit nixpkgs; };
postgresql12 = callTest ./postgresql { version = "12"; };
postgresql13 = callTest ./postgresql { version = "13"; };
Expand Down

0 comments on commit 29e769f

Please sign in to comment.