use all mon servers for connecting. use preStart

This commit is contained in:
Daniel Poelzleithner 2020-08-19 00:47:25 +02:00
parent 3913c09782
commit bf568e9de3
1 changed files with 3 additions and 6 deletions

View File

@ -34,7 +34,7 @@ in {
fileSystems."/srv/ceph" = {
#device = "172.22.99.13:6789:/";
device = "172.20.72.53:6789:/";
device = "172.20.72.55:6789,172.20.72.56:6789,172.20.72.53:6789:/";
fsType = "ceph";
options = [
"name=storage2"
@ -131,11 +131,8 @@ in {
volumes =
[ "/dev:/dev" "/etc/ceph:/etc/ceph" "/var/lib/ceph/:/var/lib/ceph" ];
};
systemd.services.docker-ceph-osd-7.serviceConfig = {
ExecStartPre = [
"-${pkgs.docker}/bin/docker run --rm --net=host --ipc=host --privileged=true -v /dev:/dev -v /etc/ceph:/etc/ceph -v /var/lib/ceph/:/var/lib/ceph -e OSD_DEVICE=/dev/sdb -it ceph/ceph:v14.2.9 ceph-volume lvm activate --all --no-systemd"
];
};
systemd.services.docker-ceph-osd-7.preStart =
"-${pkgs.docker}/bin/docker run --rm --net=host --ipc=host --privileged=true -v /dev:/dev -v /etc/ceph:/etc/ceph -v /var/lib/ceph/:/var/lib/ceph -e OSD_DEVICE=/dev/sdb -it ceph/ceph:v14.2.9 ceph-volume lvm activate --all --no-systemd";
networking = {
firewall.enable = false;