2024-04-13 14:26:07 +02:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
mkSecret,
|
|
|
|
...
|
|
|
|
}: {
|
|
|
|
age.secrets = mkSecret "atticEnv" {};
|
2024-04-02 20:53:12 +02:00
|
|
|
cfTunnels."attic.uku3lig.net" = "http://localhost:6000";
|
|
|
|
|
|
|
|
services.atticd = {
|
2024-04-04 21:59:47 +02:00
|
|
|
enable = true;
|
|
|
|
credentialsFile = config.age.secrets.atticEnv.path;
|
2024-04-02 20:53:12 +02:00
|
|
|
|
2024-04-04 21:59:47 +02:00
|
|
|
settings = {
|
|
|
|
listen = "[::]:6000";
|
|
|
|
api-endpoint = "https://attic.uku3lig.net/";
|
2024-04-02 20:53:12 +02:00
|
|
|
|
2024-04-04 21:59:47 +02:00
|
|
|
storage = {
|
|
|
|
type = "local";
|
|
|
|
path = "/data/attic";
|
|
|
|
};
|
2024-04-02 20:53:12 +02:00
|
|
|
|
2024-04-04 21:59:47 +02:00
|
|
|
chunking = {
|
|
|
|
nar-size-threshold = 65536; # 64 KiB
|
|
|
|
min-size = 16384; # 16 KiB
|
|
|
|
avg-size = 65536; # 64 KiB
|
|
|
|
max-size = 262144; # 256 KiB
|
|
|
|
};
|
2024-04-02 20:53:12 +02:00
|
|
|
|
2024-04-04 21:59:47 +02:00
|
|
|
compression.type = "zstd";
|
2024-04-02 20:53:12 +02:00
|
|
|
|
2024-04-04 21:59:47 +02:00
|
|
|
garbage-collection = {
|
|
|
|
interval = "1 day";
|
|
|
|
default-retention-period = "6 weeks";
|
2024-04-02 20:53:12 +02:00
|
|
|
};
|
|
|
|
};
|
2024-04-04 21:59:47 +02:00
|
|
|
};
|
|
|
|
}
|