feat: setup attic binary cache server.
All checks were successful
default / build (push) Successful in 2m26s

This commit is contained in:
CronyAkatsuki 2026-01-22 19:56:50 +01:00
parent 5d342eafdb
commit 6a0072d081
4 changed files with 51 additions and 0 deletions

View file

@ -7,6 +7,9 @@
navidrome = {
file = ../../../../secrets/navidrome.age;
};
attic-env = {
file = ../../../../secrets/attic-env.age;
};
};
};
}

View file

@ -0,0 +1,47 @@
{config, ...}: {
# imports = [inputs.attic.nixosModules.atticd];
services.atticd = {
enable = true;
environmentFile = "${config.age.secrets.attic-env.path}";
settings = {
listen = "127.0.0.1:8484";
api-endpoint = "https://cache.cronyakatsuki.xyz/";
storage = {
type = "s3";
region = "us-east-005";
bucket = "76302220-b368-4328-b566-2a038235b314--attic";
endpoint = "s3.us-east-005.backblazeb2.com";
};
jwt = {};
chunking = {
nar-size-threshold = 64 * 1024; # 64 KiB
min-size = 16 * 1024; # 16 KiB
avg-size = 64 * 1024; # 64 KiB
max-size = 256 * 1024; # 256 KiB
};
};
};
services.traefik.dynamicConfigOptions.http = {
services.attic.loadBalancer.servers = [
{
url = "http://localhost:8484";
}
];
routers.attic = {
rule = "Host(`cache.cronyakatsuki.xyz`)";
tls = {
certResolver = "porkbun";
};
service = "attic";
entrypoints = "websecure";
};
};
}

BIN
secrets/attic-env.age Normal file

Binary file not shown.

View file

@ -47,4 +47,5 @@ in {
"linkwarden-db.age".publicKeys = systems ++ users;
"paperless-ngx.age".publicKeys = systems ++ users;
"forgejo-runner-token.age".publicKeys = systems ++ users;
"attic-env.age".publicKeys = systems ++ users;
}