depot/cluster/services/storage/garage-external.nix

16 lines
428 B
Nix
Raw Permalink Normal View History

2023-08-28 03:32:08 +03:00
{ config, ... }:
{
services.external-storage = {
underlays.garage = {
subUser = "sub1";
credentialsFile = ./secrets/storage-box-credentials.age;
path = "/garage/${config.networking.hostName}";
inherit (config.users.users.garage) uid;
inherit (config.users.groups.garage) gid;
};
};
services.garage.settings.data_dir = config.services.external-storage.underlays.garage.mountpoint;
}