Separete container and proxy config
This commit is contained in:
parent
84d2323250
commit
782b3ef4bf
9 changed files with 579 additions and 543 deletions
30
hosts/nixos/hs/proxy.nix
Normal file
30
hosts/nixos/hs/proxy.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ config, ... }:
|
||||
|
||||
{
|
||||
# Traefik dynamic configuration for hs host
|
||||
services.traefik.dynamicConfigOptions = {
|
||||
http = {
|
||||
routers = {
|
||||
syncthing = {
|
||||
rule = "Host(`syncthing.${config.networking.hostName}.yanlincs.com`)";
|
||||
service = "syncthing";
|
||||
tls = {
|
||||
certResolver = "cloudflare";
|
||||
domains = [{
|
||||
main = "*.${config.networking.hostName}.yanlincs.com";
|
||||
}];
|
||||
};
|
||||
};
|
||||
};
|
||||
services = {
|
||||
syncthing = {
|
||||
loadBalancer = {
|
||||
servers = [{
|
||||
url = "http://localhost:8384";
|
||||
}];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue