Skip to content

Commit

Permalink
Merge pull request #778 from flyingcircusio/PL-131646-extract-osds-in…
Browse files Browse the repository at this point in the history
…to-separate-units

[21.05] extract osds into separate units
  • Loading branch information
ctheune authored Sep 25, 2023
2 parents 83c2641 + f7c0f31 commit 70a69ab
Show file tree
Hide file tree
Showing 19 changed files with 183 additions and 1,024 deletions.
33 changes: 31 additions & 2 deletions nixos/roles/ceph/osd.nix
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ in

flyingcircus.services.ceph.cluster_network = head fclib.network.stb.v4.networks;

systemd.services.fc-ceph-osds = rec {
description = "Start/stop local Ceph OSDs (via fc-ceph)";
systemd.services.fc-ceph-osds-all = rec {
description = "All locally known Ceph OSDs (via fc-ceph managed units)";
wantedBy = [ "multi-user.target" ];
# Ceph requires the IPs to be properly attached to interfaces so it
# knows where to bind to the public and cluster networks.
Expand Down Expand Up @@ -216,6 +216,35 @@ in
};
};

systemd.services."fc-ceph-osd@" = rec {
description = "Ceph OSD %i";
# Ceph requires the IPs to be properly attached to interfaces so it
# knows where to bind to the public and cluster networks.
wants = [ "network.target" ];
requires = [ "fc-blockdev.service" ];
after = wants ++ requires;

environment = {
PYTHONUNBUFFERED = "1";
};

restartIfChanged = false;

serviceConfig = {
Type = "forking";
Restart = "always";
PIDFile = "/run/ceph/osd.%i.pid";
ExecStart = ''
${fc-ceph}/bin/fc-ceph osd activate --as-systemd-unit %i
'';
ExecStop = ''
${fc-ceph}/bin/fc-ceph osd deactivate --as-systemd-unit %i
'';
};

};


})
(lib.mkIf (role.enable && role.config == "") {
flyingcircus.services.ceph.extraSettingsSections.osd = lib.recursiveUpdate
Expand Down
11 changes: 0 additions & 11 deletions pkgs/ceph/jewel/default.nix

This file was deleted.

95 changes: 0 additions & 95 deletions pkgs/ceph/jewel/dont-use-virtualenvs.patch

This file was deleted.

16 changes: 0 additions & 16 deletions pkgs/ceph/jewel/fc-jewel-glibc2-32.patch

This file was deleted.

13 changes: 0 additions & 13 deletions pkgs/ceph/jewel/fc-jewel-hdparm-naive-path.patch

This file was deleted.

123 changes: 0 additions & 123 deletions pkgs/ceph/jewel/fc-jewel-rewatch.patch

This file was deleted.

Loading

0 comments on commit 70a69ab

Please sign in to comment.