Switched to binds, volume management, new API

This commit is contained in:
inexcode
2022-08-26 14:21:05 +04:00
parent 52b896da45
commit 53c9655b7b
11 changed files with 150 additions and 8 deletions

View File

@@ -1,8 +1,18 @@
{ pkgs, config, ... }:
{ pkgs, lib, config, ... }:
let
cfg = config.services.userdata;
in
{
fileSystems = lib.mkIf cfg.useBinds {
"/var/lib/pleroma" = {
device = "/volumes/${cfg.pleroma.location}/pleroma";
options = [ "bind" ];
};
"/var/lib/postgresql" = {
device = "/volumes/${cfg.pleroma.location}/postgresql";
options = [ "bind" ];
};
};
services = {
pleroma = {
enable = cfg.pleroma.enable;