Roles/server: add copyparty
This commit is contained in:
parent
fb41beb270
commit
90028fb7fe
2 changed files with 35 additions and 0 deletions
34
roles/server/copyparty.nix
Normal file
34
roles/server/copyparty.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{flakeSelf, ...}: {
|
||||
nixpkgs.overlays = [flakeSelf.inputs.copyparty.overlays.default];
|
||||
services.copyparty = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
i = ["unix:770:caddy:/dev/shm/copyparty.socket"];
|
||||
};
|
||||
|
||||
volumes = {
|
||||
"/Files" = {
|
||||
path = "/srv/dl";
|
||||
access.r = "*";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
users.users.copyparty.extraGroups = ["caddy"];
|
||||
|
||||
services.headscale.settings.dns.extra_records = [
|
||||
{
|
||||
name = "files.everest.tailscale";
|
||||
type = "A";
|
||||
value = "100.100.0.1";
|
||||
}
|
||||
];
|
||||
services.caddy.virtualHosts.copyparty = {
|
||||
hostName = "files.everest.tailscale";
|
||||
extraConfig = ''
|
||||
import tailscale
|
||||
reverse_proxy unix//dev/shm/copyparty.socket
|
||||
'';
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue